PlanetSquires Forums

Support Forums => Other Software and Code => Topic started by: Roger Garstang on June 06, 2004, 04:43:10 AM

Title: MessageBox Editor
Post by: Roger Garstang on June 06, 2004, 04:43:10 AM
I had asked this back when I was in the PowerBASIC Forum, but it never got answered...The MessageBox editor is a great feature, but I noticed it uses MessageBox instead of PB's MSGBOX which protects NPX precision.  I think I saw the code somewhere that protects the precision I can add to my function, or I can just Copy the parts of it I want, or copy my existing messagebox functions...but you may want to implement something on this.
Title: MessageBox Editor
Post by: George Bleck on June 06, 2004, 12:22:58 PM
Got this from POFFS...

Function MesgBox(Mesg$, MesgStyle&, MesgTitle$) as Long
  MesgBox  = MSGBOX(Mesg$, MesgStyle&, MesgTitle$)
  CtrlWrd% = &B0001001100111111
  ASM  FLDCW CtrlWrd%   ; this guarantees extended precision npx calculation
End Function


Could easily be modified for MESSAGEBOX
Title: MessageBox Editor
Post by: Roger Garstang on June 06, 2004, 02:44:13 PM
yeah...I thought it was more than that though, it saves the registers then restores them after the messagebox command or something...PB's msgbox doesn't need it anymore though, even in the help now it says it keeps the NPX precision...just messagebox needs it.