Cancel
Showing results for 
Search instead for 
Did you mean: 

Re: Vericut in NX

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor

Do you use the custom_dirs.dat file?

If so you could avoid changing UGII_VENDOR_DIR, which points to a folder structure used by other add-on software too.

The entry in custom_dirs.dat would be:

${CGTECH_PRODUCTS}\nx\NX11\english

Since custom_dirs.dat is version specific, you don't have to always change your batch file.

Stefan Pendl, Systemmanager CAx, HAIDLMAIR GmbH
Production: NX10.0.3, VERICUT 8.2, FBM, MRL 3.1.7 | TcUA 10.1 MP7 Patch 0 (10.1.7.0) | TcVis 11.4
Development: C (ITK), .NET, Tcl/Tk Testing: NX12.0 | AWC 3.4 Preparing: NX12.0

Employees of the customers, together we are strong Smiley Wink
How to Get the Most from Your Signature in the Community
NX Customization - Best Practice Guide

Re: Vericut in NX

PLM World Member Legend PLM World Member Legend
PLM World Member Legend
Good idea. However our batchfile to launch NX is NX version specific.
We use a VB program with an interface to let the user choose an NX version and company department to set the proper custom environment.
It's the Vericut version I have to update in the batch files. I've tried to use the system variable for this in the past, but that gave problems because when uninstalling an old vericut version, the system variable was deleted.
The way it works now is fine, as I can also decide when a new vericut version becomes active, and not automatically when the software is installed.
Patrick Delisse
KMWE - Aero Engine
NX 12.0, TC 11.2, CAMPOST V22, Vericut 8.2, TDM 4.8
C#, VB, .NET

Re: Vericut in NX

Creator
Creator

@paehv wrote:

Sometime in the last years I've changed these settings. Now a days I set the correct variables in the NX startup bat file, like it's done in the Vericut NX startup script. We don't use the vericut script to start NX as this will launch NX with the out-of-the-box settings, while I use a custom environment.

 

Im my NX launch script I have the following:

set CGTECH_INSTALL=C:\Program Files\CGTech\VERICUT 8.1.2
set CGTECH_PRODUCTS=%CGTECH_INSTALL%\windows64
call "%CGTECH_PRODUCTS%\commands\cgtenv" 
set CGTECH_CLASSES=%CGTECH_INSTALL%\classes
if "%CGTECH_LIBRARY%" == "" set CGTECH_LIBRARY=%CGTECH_INSTALL%\library\
if "%CGTECH_LICENSE%" == "" set CGTECH_LICENSE=%CGTECH_PRODUCTS%\license
if "%CGTECH_LOCALE%" == "" set CGTECH_LOCALE=english
set CGTECH_LANGUAGE=%CGTECH_CLASSES%\%CGTECH_LOCALE%
set CGTECH_HELP=%CGTECH_INSTALL%\hhelp
set CGTECH_SAMPLES=%CGTECH_INSTALL%\samples\
set CGTECH_TRAINING=%CGTECH_INSTALL%\training\
set CGTECH_DEFAULT_UNITS=MILLIMETER
set CGTECH_RGB_TXT=%CGTECH_PRODUCTS%\vericut\rgbhues.txt
if "%CGTECH_JRE%" == "" set CGTECH_JRE=%CGTECH_PRODUCTS%\jre
set path=%CGTECH_PRODUCTS%\vericut;%CGTECH_PRODUCTS%\license;%PATH%
set UGII_VENDOR_DIR=%CGTECH_PRODUCTS%\nx\NX11\english

These lines come from : C:\Program Files\CGTech\VERICUT 8.1.2\windows64\commands\nx11.bat

All the CGTECH_* variables are used by the interface.

The UGII_VENDOR_DIR variable tels NX where to find the interface and the mem file in this location tells NX to add the vericut button

 

Whenever Vericut is updated, you need to update the first line with the version.


Thank you @paehv

I beleive it already reads as you described. I'm wondering if maybe the issue is that my version of Vericut is not supported in NX11. Could this be the issue?

Here is a copy of my launch script.

 

@echo off

setlocal

set CGTECH_INSTALL=C:\Program Files\CGTech\VERICUT 7.4.1

rem          CGTech, Copyright, All Rights Reserved

rem CGTech environment
set CGTECH_PRODUCTS=%CGTECH_INSTALL%\windows64

rem Set license server host name (LSHOST)
call "%CGTECH_PRODUCTS%\commands\cgtenv"

rem set CGTECH_IGNORELAST=TRUE

set CGTECH_CLASSES=%CGTECH_INSTALL%\classes
if "%CGTECH_LIBRARY%" == "" set CGTECH_LIBRARY=%CGTECH_INSTALL%\library\
if "%CGTECH_LICENSE%" == "" set CGTECH_LICENSE=%CGTECH_PRODUCTS%\license
if "%TEMP%" == "" set TEMP=C:\TEMP
if "%TMP%" == "" set TMP=C:\TEMP
if "%CGTECH_LOCALE%" == "" set CGTECH_LOCALE=english
set CGTECH_LANGUAGE=%CGTECH_CLASSES%\%CGTECH_LOCALE%
set CGTECH_HELP=%CGTECH_INSTALL%\hhelp
set CGTECH_SAMPLES=%CGTECH_INSTALL%\samples\
set CGTECH_TRAINING=%CGTECH_INSTALL%\training\
set CGTECH_DEFAULT_UNITS=INCH
set CGTECH_RGB_TXT=%CGTECH_PRODUCTS%\vericut\rgbhues.txt
if "%CGTECH_JRE%" == "" set CGTECH_JRE=%CGTECH_PRODUCTS%\jre


set path=%CGTECH_PRODUCTS%\vericut;%PATH%

set ARG_SPLASH=-splash:"%CGTECH_CLASSES%\startup.png"

set WAITOPT=
set ARGSTR=
:cgtgetarg
if test%1==test goto cgtchkend
if /I %1==BATCH (
   set WAITOPT=/wait
   set ARG_SPLASH=
)
set ARGSTR=%ARGSTR% %1
shift
goto cgtgetarg
:cgtchkend

if "%OS%" == "Windows_NT" set start_cmd=start "VERICUT" %WAITOPT%
if "%OS%" == "" set start_cmd=start %WAITOPT%

rem "rem" can be removed from one of the following lines to
rem wishes to set the NXV Output Directory.
rem set CGTECH_NXV_OUTPUTDIR=C:\Temp\nxv\working\tmp

rem "rem" can be removed from one of the following lines to
rem wishes to specify the location of the NXV preferences file.
rem default is %HOMEDRIVE%%HOMEPATH%.
rem set CGTECH_NXV_PREFSDIR=C:\Temp\nxv\working\tmp

rem "rem" can be removed from one of the following lines to
rem wished to set the NXV Project Template.
rem set CGTECH_NXV_PROJTEMPLATE=C:\Temp\nxv\working\NXV_Template.vcproject

rem "rem" can be removed from one of the following lines to
rem wishes to set directory for 3D tool models
rem set UGII_CAM_LIBRARY_TOOL_GRAPHICS_PATH=C:\Temp\nxv\working\tmp

if exist "%CGTECH_PRODUCTS%\nx\nx11\%CGTECH_LOCALE%" (
  set UGII_VENDOR_DIR=%CGTECH_PRODUCTS%\nx\nx11\%CGTECH_LOCALE%
) else if exist "%CGTECH_PRODUCTS%\nx\nx11\english" (
  set UGII_VENDOR_DIR=%CGTECH_PRODUCTS%\nx\nx11\english
) else (
  set UGII_VENDOR_DIR=%CGTECH_PRODUCTS%\nx\nx11
)

"C:\Program Files\Siemens\NX 11.0\UGII\ugraf.exe"  %ARGSTR%

:end_cgtech

endlocal

Re: Vericut in NX

PLM World Member Legend PLM World Member Legend
PLM World Member Legend
For vericut 7.4.1 I don't believe there is a nx11 folder. Look in the installation folder of vericut.
You can use an older version. usually a nx9 script/dll will also run in nx11It doesn't have to match to the nx version your using
Patrick Delisse
KMWE - Aero Engine
NX 12.0, TC 11.2, CAMPOST V22, Vericut 8.2, TDM 4.8
C#, VB, .NET

Re: Vericut in NX

Creator
Creator

@paehv wrote:
For vericut 7.4.1 I don't believe there is a nx11 folder. Look in the installation folder of vericut.
You can use an older version. usually a nx9 script/dll will also run in nx11It doesn't have to match to the nx version your using

Thank you again @paehv

Really appreciate the help. You are correct, I overlooked that detail. I changed it back to NX10 for those folder locations as no NX11 folders exist for this version. Im sure im missing something simple here, but i am still unable to get vericut loaded into NX11.

 

here is the updated:

 

@echo off

setlocal

set CGTECH_INSTALL=C:\Program Files\CGTech\VERICUT 7.4.1

rem          CGTech, Copyright, All Rights Reserved

rem CGTech environment
set CGTECH_PRODUCTS=%CGTECH_INSTALL%\windows64

rem Set license server host name (LSHOST)
call "%CGTECH_PRODUCTS%\commands\cgtenv"

rem set CGTECH_IGNORELAST=TRUE

set CGTECH_CLASSES=%CGTECH_INSTALL%\classes
if "%CGTECH_LIBRARY%" == "" set CGTECH_LIBRARY=%CGTECH_INSTALL%\library\
if "%CGTECH_LICENSE%" == "" set CGTECH_LICENSE=%CGTECH_PRODUCTS%\license
if "%TEMP%" == "" set TEMP=C:\TEMP
if "%TMP%" == "" set TMP=C:\TEMP
if "%CGTECH_LOCALE%" == "" set CGTECH_LOCALE=english
set CGTECH_LANGUAGE=%CGTECH_CLASSES%\%CGTECH_LOCALE%
set CGTECH_HELP=%CGTECH_INSTALL%\hhelp
set CGTECH_SAMPLES=%CGTECH_INSTALL%\samples\
set CGTECH_TRAINING=%CGTECH_INSTALL%\training\
set CGTECH_DEFAULT_UNITS=INCH
set CGTECH_RGB_TXT=%CGTECH_PRODUCTS%\vericut\rgbhues.txt
if "%CGTECH_JRE%" == "" set CGTECH_JRE=%CGTECH_PRODUCTS%\jre


set path=%CGTECH_PRODUCTS%\vericut;%PATH%

set ARG_SPLASH=-splash:"%CGTECH_CLASSES%\startup.png"

set WAITOPT=
set ARGSTR=
:cgtgetarg
if test%1==test goto cgtchkend
if /I %1==BATCH (
   set WAITOPT=/wait
   set ARG_SPLASH=
)
set ARGSTR=%ARGSTR% %1
shift
goto cgtgetarg
:cgtchkend

if "%OS%" == "Windows_NT" set start_cmd=start "VERICUT" %WAITOPT%
if "%OS%" == "" set start_cmd=start %WAITOPT%

rem "rem" can be removed from one of the following lines to
rem wishes to set the NXV Output Directory.
rem set CGTECH_NXV_OUTPUTDIR=C:\Temp\nxv\working\tmp

rem "rem" can be removed from one of the following lines to
rem wishes to specify the location of the NXV preferences file.
rem default is %HOMEDRIVE%%HOMEPATH%.
rem set CGTECH_NXV_PREFSDIR=C:\Temp\nxv\working\tmp

rem "rem" can be removed from one of the following lines to
rem wished to set the NXV Project Template.
rem set CGTECH_NXV_PROJTEMPLATE=C:\Temp\nxv\working\NXV_Template.vcproject

rem "rem" can be removed from one of the following lines to
rem wishes to set directory for 3D tool models
rem set UGII_CAM_LIBRARY_TOOL_GRAPHICS_PATH=C:\Temp\nxv\working\tmp

if exist "%CGTECH_PRODUCTS%\nx\nx10\%CGTECH_LOCALE%" (
  set UGII_VENDOR_DIR=%CGTECH_PRODUCTS%\nx\nx10\%CGTECH_LOCALE%
) else if exist "%CGTECH_PRODUCTS%\nx\nx10\english" (
  set UGII_VENDOR_DIR=%CGTECH_PRODUCTS%\nx\nx10\english
) else (
  set UGII_VENDOR_DIR=%CGTECH_PRODUCTS%\nx\nx10
)

"C:\Program Files\Siemens\NX 11.0\UGII\ugraf.exe"  %ARGSTR%

:end_cgtech

endlocal

Re: Vericut in NX

PLM World Member Legend PLM World Member Legend
PLM World Member Legend

What's probably causing trouble is that you call C:\Program Files\Siemens\NX 11.0\UGII\ugraf.exe
For NX 11 this should be C:\Program Files\Siemens\NX 11.0\nxbin\ugraf.exe
In my C:\Program Files\CGTech\VERICUT 8.1.2\windows64\commands\nx10.bat file NX is started by calling %UGII_BASE_DIR%\UGII\UGII.BAT"  %ARGSTR% 
in this bat file the correct ugraf.exe is called

Patrick Delisse
KMWE - Aero Engine
NX 12.0, TC 11.2, CAMPOST V22, Vericut 8.2, TDM 4.8
C#, VB, .NET

Re: Vericut in NX

Creator
Creator

@paehv wrote:

What's probably causing trouble is that you call C:\Program Files\Siemens\NX 11.0\UGII\ugraf.exe
For NX 11 this should be C:\Program Files\Siemens\NX 11.0\nxbin\ugraf.exe
In my C:\Program Files\CGTech\VERICUT 8.1.2\windows64\commands\nx10.bat file NX is started by calling %UGII_BASE_DIR%\UGII\UGII.BAT"  %ARGSTR% 
in this bat file the correct ugraf.exe is called


@paehv

I tried the file path C:\Program Files\Siemens\NX 11.0\nxbin\ugraf.exe and also %UGII_BASE_DIR%\UGII\UGII.BAT"  %ARGSTR% both start NX11, but neither include the Vericut interface icon.

 

I appreciate your patience, this is new for me in my career and doing my best to learn as i go.

Re: Vericut in NX

PLM World Member Legend PLM World Member Legend
PLM World Member Legend
Do you start NX with the Vericut Batch?
The vericut interface should add a button after the verify button and add a menu command in Menu > Tools
Use command finder to see if the VERICUT command is available at all. It might be present even if you don't see the button.
Patrick Delisse
KMWE - Aero Engine
NX 12.0, TC 11.2, CAMPOST V22, Vericut 8.2, TDM 4.8
C#, VB, .NET

Re: Vericut in NX

Creator
Creator

@paehv wrote:
Do you start NX with the Vericut Batch?
The vericut interface should add a button after the verify button and add a menu command in Menu > Tools
Use command finder to see if the VERICUT command is available at all. It might be present even if you don't see the button.

@paehv

yes I do start with the batch file. I also thought that may be the issue, but i have searched for the command and the only command that it finds is Export Polygon File.

 

I tried to join the Vericut forums as well, but they are "Not excepting new members" it says to email them for registration. Hopfully i can get registered.

 

I did some digging on the internet yesterday as well (as much as i could afford too) to better understand the script and where everything is looking and pulling from and wasnt able to find anything that looked incorrect.

Re: Vericut in NX

Creator
Creator

I have Confirmed with CGtech that 7.4.1 is in fact not supported in NX11. For NX11 - 12 you will need to upgrade to Vericut version 8+.

 

@paehv thank you for all your help.

Learn online





Solution Information