×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

DLL/NX Journal from Batch commands

DLL/NX Journal from Batch commands

DLL/NX Journal from Batch commands

(OP)
Hi all! I need to launch a DLL that i wrote from batch.

I found something on multiple forums and on nxjournaling.com, but not quite the information that i need. I have a few questions:

The best thing would be to launch a DLL (simuling the CTRL+U command within NX) that could interact with a part already open in NX. Also a journal file would be sufficient. I saw that there is the run_journal.exe line to launch a journal file, but I can't manage to interact with an existing session of NX (with an open part). Is it possible? Does it exist something similar to launch directly a DLL?

Thanks a lot

Francesco

RE: DLL/NX Journal from Batch commands

Can you explain more of what you want to do?
If you want to work on a part open in the session, the session should start the program.
Generally, a program run in batch starts its own process and has no UI access.

The only way I can imagine a program communicating with an already open NX session is to use ugs_router.

Mark Rief
NX CAM Customer Success
Siemens PLM Software

RE: DLL/NX Journal from Batch commands

(OP)
Thank you for your answer, i will look into ugs_router.

I'll try to explain everything better with an example. I'd like to open a part (let's say that contains a cylinder) and, leaving the same first session open, launch a series of journals/dll interacting with the cylinder. For example, I could have one journal that evaluate the volume of the cylinder, and another one that modify its dimensions. Then i could like to know again the volume once that the second DLL is finished, and so launch the first dll again and so on.

In other words: is there a way to interact by batch commands with an open session of NX (the one containing the cylinder in this example) such that a third party software (e.g. Matlab) could control the whole process via batch, launching the DLLs/journal files following an algorithm?

p.s. you could ask me why you don't create the control algorithm in NXopen, but I have lots of tools (especially optimization tools) already built and ready in Matlab, so i'd like to let Matlab control everything.

Thanks

RE: DLL/NX Journal from Batch commands

I'm 95% sure that what you are describing is called "remoting"; this allows your program to interact with an open NX session. You can find some example code in your {NX install}\UGOPEN\SampleNXOpenApplications\{.NET | Java} directory.

www.nxjournaling.com

RE: DLL/NX Journal from Batch commands

(OP)
Yes, you are absolutely right. I was looking into that, but I would have liked to know if there was a way to do that via batch. Anyway, i guess i'll use a remote server.

RE: DLL/NX Journal from Batch commands

I'm not sure what you mean by "do that via batch". If you use remoting, your program essentially has full control of the NX session. You could start your program from a batch file if you want; what am I missing?

www.nxjournaling.com

RE: DLL/NX Journal from Batch commands

(OP)
Well, the way I see it, you have the same results, once that the method is working. But i thought that doing the "full control" by command line (windows cmd) was simpler for me than start a server/remoting connection.

I don't know much about programming, so maybe I am wrong or I missed something.

Thanks again anyway.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources