Use StrPrintF to "print" the number to the string you will display.  For
example, to adapt from your code:
     gstrDisplayNumber = MemPtrNew(20);         // or whatever length you
need
     StrPrintF(gstrDisplayNumber, "%d", recordP->DisplayNumber);
     WinDrawChars(gstrDisplayDate,StrLen(gstrDisplayNumber),5,120);

Regards, Nick

-----Original Message-----
From: Brian O'Grady [mailto:[EMAIL PROTECTED]]
Sent: Friday, 21 January 2000 3:33
To: [EMAIL PROTECTED]
Subject: Draw int to screen

Warning: this is a newbie question.

I have a db of integers and I would like to Draw them to the screen so I
know that the app is retrieving the correct values. I have never tried
writing a numeric value to the screen before and every example I have uses
charptr's. Can someone please give a snippet on how to display numeric
values, it doesn't have to be of type int.You were warned. Thank You

This is what I have been doing
     gstrDisplayDate  = MemPtrNew(StrLen(recordP->DisplayDate)+1);
     StrCopy(gstrDisplayDate, recordP->DisplayDate);
     WinDrawChars(gstrDisplayDate,StrLen(gstrDisplayDate),5,120);
How is this done with none CharPtr types?

Reply via email to