Assembly Language Help (alang.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
GetCurPos
 Map                                       Up Contents Index Back
────────────────────────────────────────────────────────────────────────────
 
;* GetCurPos - Gets current cursor position.
;*
;* Uses:    vconfig - Video configuration structure (initialized
;*          by calling the GetVidConfig procedure)
;*
;* Params:  None
;*
;* Return:  Short integer with high byte = row, low byte = column
 
GetCurPos PROC USES bx dx
 
        mov     ah, 3                   ; Function 3
        mov     bh, vconfig.dpage
        int     10h                     ; Get cursor position
        mov     ax, dx
        ret
 
GetCurPos ENDP
                                    -♦-