At 12:29 PM +0530 9/6/01, Saraswathy wrote:
>while using the debugger , it gives the error where i set my frmCustomAlert
>to notify the values..If i remove it generally there is no error. But then i
>am not able to find out the values being read and if they are correct.Is
>there any other way like a message box , or something other than that which
>i can use instead of an alert.

Yes...again, use a debugger.  Debuggers let you inspect values in 
variables and such.

In other comments:

* You wouldn't happen to be using an old version of Palm OS, are you. 
The documentation says to use " " instead of "" for Palm OS 2.0 and 
earlier.

* You don't say *which* call to FrmCustomAlert is failing.  All of 
them?  Or just one of them?

* Not all of your code is included.  For instance, in "test=s->id", 
you don't define "test" anywhere.

* You do hardly any error checking.  You don't check for NULL values 
or function results.

* Why is "id" a char*, while the other fields are arrays of chars? 
You initialize "id" with a pointer to a locked handle.  Why not make 
it an array of 10 chars?  And you store the pointer to the memory 
chunk, and then write the record containing that pointer to the 
database.  What are you doing with the pointer?  That points to data 
that's not stored in the database?  Any time your application quits, 
that data will be deleted, leaving your record with a pointer to 
now-invalid data.  When you next try to access that record, you'll be 
accessing invalid data when you use the pointer in the "id" field.

-- Keith

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to