TIP: Click on subject to list as thread! ANSI
echo: c_plusplus
to: VIKTOR OSADCHUK
from: KEVIN CAMPBELL
date: 1997-08-23 09:03:00
subject: Reset

 > ·¿þ
 > Ç´³, Rajesh !!!
 >  RD> int far *post=0x00000472;
 >  RD> post=0x1234; /* If you want the memory check on reboot */
 >  RD> geninterrupt(0x19);  /* Works with Borland C compilers like TC, BC,
 > ...*/
 > === Cut ===
 > #include 
 > #include 
 > void main()
 > {
 >  cout <<"\n" << "Reboot your computer ?"
 >       <<"\n";
 > char a=getch();
 > switch (a) {
 >  case 'Y':
 >  case 'y':
 >        asm    {
 >             mov ax,0
 >             mov es,ax
 >             mov ax,1234h
 >             mov di,0472h
 >             mov es:di,ax   /* Error: Memory reference expected */
 >             int 19h
 >               }
 >             break;
 >  default:
 >             break;
 >            }
 > }
 > === Cut ===
 > Borland C++ 3.01. Error : Memory reference expected !!! Why ?!
Put square brackets around the reference "mov [es:di],ax".
Have Fun - Kev
Kevin Campbell
Sysop of Deimos BBS
E-Mail: Sysop@Deimos.unmanned.co.uk
--- FMail/386 1.02
---------------
* Origin: Mail shipped from Deimos Spaceport (2:258/8)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.