Community
Navisworks API
Welcome to Autodesk’s Navisworks API Forums. Share your knowledge, ask questions, and explore popular Navisworks API topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Checking for available license via Automation API

2 REPLIES 2
Reply
Message 1 of 3
|flyte|
666 Views, 2 Replies

Checking for available license via Automation API

Is there a way via the API to check for a valid license. I want to check for this before I attempt to create the NavisworksApplication() object.

 

If no license is available when trying to create the NavisworksApplication, then a dialog pops up. I would rather this dialog not appear, so before attempting any automation, I want to check for license availability first.

 

thanks,

 

Tags (3)
2 REPLIES 2
Message 2 of 3
markusvikström
in reply to: |flyte|

I solved this by querying the Flexlm server and browsing the returned string for the license and available licenses.

 

E.g. Using the System.Diagnostics.Process with necessary arguments:

 

lmutil lmstat -a -f [feature] -c [port]@[servername]

 

Capturing the Process.StandardOutput.ReadToEnd() you can use regular expressions or similar to very fast find the necessary availability of the licenses.

 

Hope this gave some ideas...

 

BR,

Markus

 

 

 

 

 

Message 3 of 3
|flyte|
in reply to: markusvikström

Does anyone else consider this a serious ommision from the automation api? The whole point of it is so that we can perform tasks that don't require user interaction!! Checking for a license seems to be pretty integral in the process.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


Autodesk Design & Make Report