>Therefore you are copying from a NULL pointer. Which probably means you are calling some function that returns NULL, and you aren't trapping the error. I am using a literal string ( ":") Its not a argument or veriable. If i change it to "-" it works fine.
>By the way, you are ensuring the SMS messages don't already contain colon >aren't you ? Yes, I edit the msg in to the DB if one is in the msg, and change it back when it is displayed. Here is the problem code segment... DmWrite(mp,count,sender,StrLen(sender)); DmWrite(mp,count+StrLen(sender),"-",1); DmWrite(mp,count+StrLen(sender)+1,msg,StrLen(msg)); DmWrite(mp,count+StrLen(sender)+StrLen(msg)+1,":",1); DmWrite(mp,count+StrLen(sender)+StrLen(msg)+2,"\0",1); MemPtrUnlock(mp); DmCloseDatabase(dbHandle); -- Scott Erickson Software Engineer, FB-4, Inc. [EMAIL PROTECTED] "Roger Stringer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Subject: DmWrite() is not writing the correct string??? From: "Scott Erickson" <[EMAIL PROTECTED]> Date: Thu, 14 Jul 2005 14:11:23 -0400 In my app, i have to save a list of SMS msgs. I am simply putting them in a DB with a ":" between each one. This way i can copy it to a string, replace the : with a NULL and have a string ready to send to a list. This ofcourse works fine in my app when the app is running. But there is a 2nd place I do the same thing, and its from a launch code that deals with a SMS msg coming into the device. The problem is that on the DmWrite() call that is putting the ":" in place, it puts some y with dots over it???? if i try a ";" same thing, but if i try anything thing else, like "-" it works fine. Im lost on why this is going on. Ofcourse I can simply change the char that I use to split up the SMS msgs, but Im still amazed at what its doing. If you look at the Palm OS character set you'll find the "y with umlaut" is 255 (or-1) and is also what is contained in the area of memory pointed to by NULL. Therefore you are copying from a NULL pointer. Which probably means you are calling some function that returns NULL, and you aren't trapping the error. By the way, you are ensuring the SMS messages don't already contain colon aren't you ? Roger Stringer Marietta Systems, Inc. (www.rf-tp.com) -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
