cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Your Friends List is a way to easily have access to the community members that you interact with the most! X

JLink: Modal menubar menu button

cbell
1-Newbie

JLink: Modal menubar menu button

Example: The button for Manikin only appears when an assembly is opened. I'd like to do this for parts with JLink. Can anyone point me in the right direction? It seems like it should be a listener but none of the available ones I have found seem to serve the purpose.

This thread is inactive and closed by the PTC Community Management Team. If you would like to provide a reply and re-open this thread, please notify the moderator and reference the thread. You may also use "Start a topic" button to ask a new question. Please be sure to include what version of the PTC product you are using so another community member knowledgeable about your version may be able to assist.
3 REPLIES 3

Chris -

I'm sure other JLink users want this functionality - I know I do, but
I haven't found a way to do it.

> Example: The button for Manikin only appears when an assembly is opened.
> I'd like to do this for parts with JLink. Can anyone point me in the
> right direction? It seems like it should be a listener but none of the
> available ones I have found seem to serve the purpose.Example: The
button
> for Manikin only appears when an assembly is opened. I'd like to do
this
> for parts with JLink. Can anyone point me in the right direction? It
> seems like it should be a listener but none of the available ones I have
> found seem to serve the purpose.

The UICommandActionListener interface exposes only one event method,
OnCommand, which is executed after you select the menu. I don't know
why PTC didn't add another method called OnUIDisplay or something similar.

Pro/Toolkit users can define callback functions of type uiCmdAccessFn to
enable/disable menu entries, and they work quite well. I can't see the
point, though, of writing a Pro/Toolkit task DLL for this purpose alone.

Has anyone submitted an SPR or enhancement request for this?

|+| M a r k |+|

Mark Stallard
Engineering Information Management
Integrated Solutions & Development
Integrated Defense Systems
Raytheon Company



(business)
+1.978.436.6016
(cell)
+1.617.331.5443
(tie line)
239.6016
-

880 Technology Drive
Billerica, MA 01821
www.raytheon.com


This message contains information that may be confidential and privileged.
Unless you are the addressee (or authorized to receive mail for the
addressee), you should not use, copy or disclose to anyone this message or
any information contained in this message. If you have received this
message in error, please so advise the sender by reply e-mail and delete
this message. Thank you for your cooperation.





I asked PTC support about this some months ago.
This functionality was introduced in WildFire 4.
Unfortunately, I'm still at WilFire 3.

Gerry

jfelkins
12-Amethyst
(To:cbell)

Hello

In WF3 this is not supported as you know. My suggested is to determine the type of model that is active so if anyone selects on the menu button a message will appear informing the user that the button can not be used based on the model type.An example is below.

//Get model type
ModelType modelType =mdlObject.GetType();

if (!modelType.equals(ModelType.MDL_ASSEMBLY)){
currSession.UIShowMessageDialog("Please select an assembly.",null );
}

Hope this helps. If you have questions, please contact me at jfelkins@felcosolutions.com.

In Reply to Chris Bell:

Example: The button for Manikin only appears when an assembly is opened. I'd like to do this for parts with JLink. Can anyone point me in the right direction? It seems like it should be a listener but none of the available ones I have found seem to serve the purpose.
Top Tags