I'm using a Mplab IDE v8.92 compiler. I can assign a variable to a value:
movlw b'00000111'
movwf var1 ;initialize var1
the watch box shows that the memory position (in this case, 0x20) holds the correct value.
However, when I retrieve the value;
clrw
movlw var1
the work register shows the memory position, not the value contained.
If you show your whole code it will help. One of the "gottchas" of Assembly is the movlw instruction. It will return the register location, which BTW is very useful for setting up indirect addressing. Try, "movf register,w"