This may make your issue more obvious...
Quotient : Remainder = Dividend / Divisor
AL : AH = AX / (8-bit)
AX : DX = DX:AX / (16-bit)
EAX : EDX = EDX:EAX /(32-bit)
You needed to specfy a data type snce you're using a memory reference
MOV AH,DAY
CBW ; AX = Day
DIV DIVISOR ; Byte ptr Divisor
;;;; WRONG CMP Al,'0'
; It's a decimal response not an ASCII '0'
; Note: AH is day of week (0...6)
; AL is week # (0..N)
Last edited by wildgoose; Oct 19th, 2009 at 12:08 am.
Reputation Points: 546
Solved Threads: 99
Practically a Posting Shark
Offline 891 posts
since Jun 2009