Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

NX Expresssion/Function Question (ug_excel_read)

Status
Not open for further replies.

Ellzy

Mechanical
Apr 9, 2010
7
Hi,

I have some parts in UG NX4 containing expressions that are updated from an external spreadsheet. When I use the function "ug_excel_read" I am asked to specify a spreadsheet. When I use the menu to locate the spreadsheet it automatically populates the file path into the function formula. This works fine as long as my spreadsheet stays in the same location. If I move the spreadsheet to a different folder or location everything blows up. Is there a way to either make the file path a variable that I can change throughout all of the expressions in my part or can I leave it blank and have it default to searching for the spreadsheet in my working directory? All of this is assuming I am working in native UG right now. If more explanation of my problem or what I am looking for is needed, please let me know. Any advice is appreciated!
 
Replies continue below

Recommended for you

No, the path needs to explicit and up-to-date to work.

That being said, what exactly are you using the 'external' spreadsheet for?

John R. Baker, P.E.
Product 'Evangelist'
Product Design Solutions
Siemens PLM Software Inc.
Industry Sector
Cypress, CA

To an Engineer, the glass is twice as big as it needs to be.
 
Is it possible to store the spreadsheet on the same drive/folder that your NX files are resident in?
 
Thanks for the replies! John, I have an assembly that I am scaling based off of some design calculations and macros in an external spreadsheet. All the calculations are performed in the spreadsheet, it is saved, and then I refresh my parts in UG with a macro to get the new geometry. My problem is that sometimes I need to allow another user to utilize my spreadsheet and UG parts. If they copy the files to a folder on their machine, all the file paths in all of the parts need to be changed. If there is not a way to avoid this, is there a better way to accomplish what I'm trying to do? Thanks!
 
Is there a way I could put the parts and spreadsheet in Teamcenter to allow others access and solve my problem?
 
Actually the Teamcenter solution would be the best long term one if this is going to be a common part of your workflow.

John R. Baker, P.E.
Product 'Evangelist'
Product Design Solutions
Siemens PLM Software Inc.
Industry Sector
Cypress, CA

To an Engineer, the glass is twice as big as it needs to be.
 
That is true John. I wish our IT system allowed that. Even their knowing that having the spreadsheet stored in a vulnerable area...MY USER Folder, they seem to be intransigent.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor