What you are saying makes perfect sense,I am using LstSetListChoices(listP,
NULL, size), but I am not making any calls like LstGetSelectionText(),
there is no code in the event handler that would crash the application, I'm
assuming it has something to do with the list directly.
I got the same code working for a normal list populated with a char* field.
this time I'm populating this list with a CharPtr, who gets it's value from
StrITOA(ptr,myDWord) which I'm using to populate the list, could this have
anything to do with it ?
Michael S. Davis wrote in message <7906@palm-dev-forum>...
>
>On Tue, 11 Apr 2000, Nicholas Breau wrote:
>
>> I've got a popup trigger whose listbox is loaded with data from the
database
>> by using LstSetDrawFunction. When I run the app, the data is loaded into
>> the popup fine, but when I select an item, I get the error message:
>>
>> "AppName" has just read directly from low memory.
>>
>> and the device needs to be reset. Does anybody have any idea as to what
>> would cause this error ?
>
>Just a guess. You probably use something like:
>LstSetListChoices(listP, NULL, size), like what is shown in Palm
>Programming, then use the callback function to draw to the screen.
>
>Remember that your ListCallbackDrawFunction does not actually do
>anything to the list. It just uses the parameters to draw to the screen
>in the appropriate location.
>
>So, if you do something like LstGetSelectionText() you are getting a
>NULL pointer returned, because you did not actually provide anything
>that points to any test for this function to return.
>
>What you might need to do is get the selected list index of the selected
>item and get the data from the original source.
>
>----------------------------------------------------
>Shoot-to-Win
>
>Protect the 2nd Amendment
>----------------------------------------------------
>
>
>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palm.com/devzone/mailinglists.html