Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations MintJulep on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Arguments in Ribbon Bar 1

Status
Not open for further replies.

NutAce

Mechanical
Apr 22, 2010
1,192
Hello all,

Has anybody ever tried to pass an argument to a dll started from a ribbon (or toolbar)?

I tried;

Code:
ACTION Start $SITE_PREF_PATH\ForEngineDocsCGM\ForEngineDocs_Plotcgm.dll Ai

And

Code:
ACTION "Start $SITE_PREF_PATH\ForEngineDocsCGM\ForEngineDocs_Plotcgm.dll Ai"

But I get the message from NX telling me; "Unknown Action Type"

To elaborate, when I run user fucntion from NX I can pass an argument as show below...can I do this directly on the Action line of the ribbon (toolbar)?
Arguments_mddvlq.png




Ronald van den Broek
Senior Application Engineer
Winterthur Gas & Diesel Ltd
NX9 / TC10.1.2

Building new PLM environment from Scratch using NX11 / TC11
 
Replies continue below

Recommended for you

Try

Code:
ACTION $SITE_PREF_PATH\ForEngineDocsCGM\ForEngineDocs_Plotcgm.dll("Ai")
 
Hi Petulf,

tried it but now I'm getting "None of the actions for specified button were registered"


Ronald van den Broek
Senior Application Engineer
Winterthur Gas & Diesel Ltd
NX9 / TC10.1.2

Building new PLM environment from Scratch using NX11 / TC11
 
It should be possible by making use of the BUTTON name

NX 9.0.3.4
NX 11.0.1.11 (Testing)
Windows 7 (Windows 8.1 Tablet)
 
NutAce, weird this is an excerpt from one of our .tbr files

BEGIN_GROUP BETA_MODELING
GROUP_STYLE DEFAULT
LABEL Modeling

BUTTON EDIT_THREAD
LABEL Edit M-Thread
MESSAGE Changes size of a reuse thread
BITMAP ${NX_CUSTOM_LIB}\ToolBars\bitmaps\edit_thread.bmp
ACTION ${NX_CUSTOM_LIB}\scripts\edit_thread.vb

BUTTON EDIT_G_THREAD
LABEL Edit GHT G-Thread
MESSAGE Changes size of a GHT reuse G-thread
BITMAP ${NX_CUSTOM_LIB}\ToolBars\bitmaps\edit_g_thread.bmp
ACTION ${NX_CUSTOM_LIB}\scripts\edit_thread.vb("bspp")

END_GROUP
 
I understood that is actually only possible using a Menu file...so I created one as below.

Code:
VERSION 120

EDIT UG_GATEWAY_MAIN_MENUBAR

TOP_MENU
	CASCADE_BUTTON DOCUMENTATION_PREPARATIONS
	LABEL Documentation Preparations
	
END_OF_TOP_MENU

MENU DOCUMENTATION_PREPARATIONS

	BUTTON ILLUSTRATOR_CGM
	LABEL  Illustrator CGM Export
	BITMAP $SITE_PREF_PATH\ForIllustratorCGM\Startup\Plotcgm4Illustrator.bmp
	ACTIONS Start $SITE_PREF_PATH\ForEngineDocsCGM\ForEngineDocs_Plotcgm.dll(Ai)

END_OF_MENU

Ronald van den Broek
Senior Application Engineer
Winterthur Gas & Diesel Ltd
NX9 / TC10.1.2

Building new PLM environment from Scratch using NX11 / TC11
 
petulf said:
NutAce, weird this is an excerpt from one of our .tbr files

Hi Petulf, it works...had to remove the start from the begining of the line... :)
Thanks!

Ronald van den Broek
Senior Application Engineer
Winterthur Gas & Diesel Ltd
NX9 / TC10.1.2

Building new PLM environment from Scratch using NX11 / TC11
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor