KEY : Past progressive tense is used to express something happen in the past time when others occur. Past Progressive tense is commonly used together with Simple Past Tense.
I was watching TV when he knocked the door.
Study this follows!
(+) I was reading a novel.
(-) I wasnot reading a novel.
(?) Was I reading a novel?
So, place not behind the be-past to make a negative and place the be-past at the beginning of the sentence when you would like to make an interrogative sentence. Read more
Using WHILE and WHEN
While I was learning English, my father came.
When I went to BALI, Mita sent me a line.
Note : Sent me a a line = sent me a piece of letter.
From the sentence above, we can see that WHILE is used to make a sub clause of past progressive tense and WHEN is used to make a main clause of Past Simple.