Creating a Resource Menu

A PocketC native palm library offering native forms and assorted utilities

Postby ComputerFan on Fri Aug 08, 2003 10:17 pm


I'm trying to create a menu but everytime I do, I Palm Emulator gives me the following error:

SysFatalAlert UIResource.C, Line 214, Menu rsrc not found

I created the Resource as follows:

MENU ID 3001
MENUITEM "About" ID 3003

Used PilRc as follows: pilrc -allowEditID simplemenu.rcp

It generated the required file (MBAR0bb9.bin) as expected.

I used par to place the resource in the .prc file

par a simplemenu.prc MBAR0bb9.bin

The code I'm using in the program is:



The error is generated when I click on the menu bar.

Am I doing something wrong or am I missing something.

Thanks for the help

Posts: 2
Joined: Fri Aug 08, 2003 9:50 pm

Postby jstadolnik on Fri Aug 08, 2003 11:53 pm

First use the RsrcEdit to make sure that your .prc file does indeed contain the menu.

Also, if simple_menu.prc is not your application .prc you should open it first with OpenRsrcDb() or resopen() so that the menu is accessible.

Finally, if you are installing other objects into the form make sure that you call the SETMENU after all the objects have been installed. There is an OS bug on pre-OS4.1 systems which can cause menu anomolies if SETMENU is called earlier.


The PToolboxLib guy.
Posts: 1741
Joined: Wed Dec 06, 2000 3:34 am
Location: USA

Postby ComputerFan on Sat Aug 09, 2003 1:37 am

:)Thanks Joe:

It appears to work now. I was using a batch file with par and I had typed mbar0bb9.bin and not MBAR0bb9.bin. When I used RsrcEdit I could see that the resource was not in the prc file when I didn't capitalize the MBAR. I also moved the SETMENU to the end. Problems are gone.

thanks for the help.

Posts: 2
Joined: Fri Aug 08, 2003 9:50 pm

Return to Pocket Toolbox

Who is online

Users browsing this forum: No registered users and 2 guests