flat assembler
Message board for the users of flat assembler.

Index > DOS > About open exist file, with parameters arugments

Author
Thread Post new topic Reply to topic
gumletis



Joined: 18 Dec 2004
Posts: 128
gumletis
Hi, im trying to make a simple program that opens the arguments file, and just type it on the screen, i got this, but it doesn't work, its look ccorreclty out to me


Code:
org 100h
mov dx,0x82
mov ah,0x3D
mov al,0x2
int 0x21
jc err
mov bx,ax
mov ah,3Fh
mov cx,500
int 21h
mov bx,ax
mov si,dx
mov byte[si+bx],'$'
mov dx,si
mov ah,09h
int 21h
RET

errmsg db 'Error In Opening/Reading "',82h,'"$',0
err:
mov dx,errmsg
mov ah,09h
int 21h
RET
    



thanks

_________________
LOOOL
Post 27 Feb 2005, 10:57
View user's profile Send private message Reply with quote
liteonish



Joined: 24 Feb 2005
Posts: 26
liteonish
I'm not too sure about the ints... What's bugging me is that you have 0x sometimes and sometimes h for hex. Can't make up your mind? Razz

_________________
I just own that much.
Post 27 Feb 2005, 14:12
View user's profile Send private message Visit poster's website Reply with quote
bubach



Joined: 17 Sep 2004
Posts: 340
Location: Trollhättan, Sweden
bubach
"What's bugging me is that you have 0x sometimes and sometimes h for hex." -> Sign of stoalen code? Wink
Post 27 Feb 2005, 16:23
View user's profile Send private message Reply with quote
gumletis



Joined: 18 Dec 2004
Posts: 128
gumletis
lol, first im not fucking skiddy, was becuase i could't get it to work, i know its a little fucked, but still doesn't say im a skiddy, ps that code does nothing do yet... I need to make my own compiler, but its caint of hard lol, i make my own asm compiler in asm... LOL but can't even get that code, and if you think im a script kiddy so you are loool,

0ah = 0xa
0bh = 0xb
21h = 0x21


easy to translate, but i think i have did something wrong, so i change it to that where i seen the interrupts(www.ctyme.com/rbrown.htm - best online interrupt list).... PS the code should just a file, and so read from it(500 bytes - lol think it will overflow need to do a reserved byte.... Embarassed ) and so set a '$' at the end of it, and so print it out..... easy huh? yes but it doesn't work

_________________
LOOOL
Post 27 Feb 2005, 19:23
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar.

Powered by rwasa.