I made the changes you recommended me.
The code now is the following, but the error still appears.

Err OpenURL(char * url)
{
        Err err = 1;
        DmSearchStateType searchState;
        UInt cardNo;
        LocalID dbID;
        char * ptr;
         
        // Make sure Clipper is present
        err = DmGetNextDatabaseByTypeCreator(true, &searchState,
sysFileTApplication, sysFileCClipper, true, &cardNo, &dbID);
        
        if(err) 
                FrmAlert(NoWebClippingAlert);
        else {
                
                ptr = (char *)MemPtrNew(StrLen(url) + 1);
                ErrFatalDisplayIf(!ptr, "Out of memory");
                
                MemMove(ptr, url, StrLen(url) + 1);
                
                err = MemPtrSetOwner(ptr, 0);
                
                if(err) FrmAlert(NoWebClippingAlert);
                else    
                // Launch Web Clipping with the URL
                err = SysUIAppSwitch(cardNo, dbID,
sysAppLaunchCmdGoToURL, ptr);
        }
        return err;
}

I would appreciate if anyone can tell me where the damned error is.

Bye, 
        Gonzalo.


-----Original Message-----
From: Ben Combee [mailto:[EMAIL PROTECTED]] 
Sent: Jueves 17 de Enero de 2002 05:06 AM
To: Palm Developer Forum
Subject: Re: MemoryMgr.c: Error 3036 Chunk over-locked
Importance: High

> This is the code I use for opening a web page with Web Clipping. After
> navigating through various links, and trying to get back I get
> "MemoryMgr.c: Error 3036 Chunk over-locked", I think the error is in
the
> Memory Handle.

>You allocate memory for the URL using MemHandleNew.  Use MemPtrNew
>instead.

--
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