The community will undergo maintenance on October 16th at 10:00 PM PDT and will be unavailable for up to one hour.
Hi ,
I have created custom menu push buttons in creo3. how can i assign icon to the push button. I am able to assign it to cascade menu but not to push button.
Thanks in Advance,
Manoj
Solved! Go to Solution.
Thanks a lot Eike for you Quick response.
I will check it out.
//BR
Manoj
Hi in ProToolkit it should work like this :
create the PushButton
Toolkit |
---|
uiCmdCmdId pro_cmdId = NULL; ProMenubarmenuPushbuttonAdd("MDLPRCMenubarMenu", "pbVisitParameters", "MPU StartModelProcessorBtn", "MPU StartModelProcessorHlp", NULL, PRO_B_TRUE, pro_cmdId, g_translation_file); ProCmdDesignate(pro_cmdId, "MPU StartModelProcessorBtn", "MPU StartModelProcessorHlp", "MPU StartModelProcessorDesc", g_translation_file); ProCmdIconSet(pro_cmdId,"modproc.gif"); |
All lines return a ProError often this one shows you where the failure is.
Don't forget to put the image you want to set to your ressources. Creo only look inside the resources for pictures at :
<application_text_directory>/<language>/resource/
You should lay there 2 Images.
- First one is 16x16 and have naming convention name.png.
- Second one is 32x32 and have naming convention name_large.png
Creo selects automaticly the right size for display inside of Menu's.
alternativ in OTK
Objekt Toolkit |
---|
pfcUICommand_ptr cram_start_cmd = wSession->UICreateCommand("CRA_MATERIAL", new MycallbackClass(cram::cram_start)); cram_start_cmd->Designate ("cram_message.txt", "CRA Material selection", "CRA Material selection", "CRA Material selection"); cram_start_cmd->SetIcon("cram_icon.png"); |
Best regards,
Eike
Thanks a lot Eike for you Quick response.
I will check it out.
//BR
Manoj