Log in

View Full Version : A Win32 Asm Problem --> Need help !


Clandestiny
December 13th, 2000, 17:00
Hi guys,

I have been trying to learn win32 asm programming from Iczelions site...and I am having a couple of problems with something I'm trying to write.

Basically, I've made it to about the 9th tut which involves using child window controls (buttons and edit boxes and such). I am using an edit box to get a numerical string from the user which I am want to convert into a floating point number using the StrToFloat function. Then after some calculations are performed on the floating point number, the press of a button will output it again as a string in a message box. Here is my problem...

The floating point number output by the StrToFloat function is an 8 byte QWORD and I can't figure out how to add / subtract / multiply / divide with this size of value. I have looked at an assembly reference book and can find no instructions for dealing with this size (it is an old book so possibly it doesn't contain all of the instructions). Any help will be appreciated.

Thanks in advance...

Regards :-)
Clandestiny

Solomon
December 13th, 2000, 22:05
hi, you can use floating-point instructions like FADD, FMUL etc. All these instructions begin with a 'F'. Details of these instructions & the architecture of 80x87 can be found in the manuals of Intel processor or "the Art of Assembly Language".(try here: http://personales.com/eeuu/arizona/Aesculapius/files.html). Finally the result can be converted into a string with wsprintf( ) & displayed in the text box.

Clandestiny
December 14th, 2000, 12:23
Thanks a lot :-)

Regards,
Clandestiny