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

Start Inventor with fix application options

62 REPLIES 62
Reply
Message 1 of 63
michael_marx
6089 Views, 62 Replies

Start Inventor with fix application options

Is there a way to import application option xml file everytime in Inventor during startup? Like autocad with their profile option /p 

 

mima

62 REPLIES 62
Message 41 of 63
Scott.Hawkins
in reply to: Milan_Nosil

Hi Milan,

 

I hope this is something that only needs to be done once, not every time that a user starts Inventor.

Inventor should remember the settings unless the Inventor Reset Utility (Windows Start->Autodesk->Inventor 2018->Tools->Inventor Reset Utility) is used, or maybe if the user resets the ribbon (right-click Ribbon->Ribbon Appearance, Reset Ribbon).

So this should probably be in a bat file that is only run once after install.

 

The other option that I mentioned is creating a deployment: 

 

https://knowledge.autodesk.com/search-result/caas/CloudHelp/cloudhelp/2016/ENU/Autodesk-NetworkAdmin...

 

This is where the CAD Admin (someone who manages installation, maintenance, usage policies, styles, documentation standards, etc.) creates a common installation on a network drive where all the users can install from.

The deployment provides a simplified installment for users, and a chance for the CAD Admin to standardize many things for all users.

For example, a license can be set up as part of the installation so that the users don't need to do that part and can use licensing in the way that the company intended.

 

This command line option was actually designed to be used as part of the deployment process, and so the deployment provides options to specify application option and user customization files that were created by the CAD Admin with settings that all users should share.  Usually the files are created by exporting, but can be refined by careful hand editing of the XML files.  Unfortunately there is not a lot of documentation about the contents of these files, but the important settings can usually be determined with a little bit of experimentation, and possibly by asking questions here on the Forum.

 

The reason that this command line option does not work in the interactive mode, is that it was not designed for that.  It was designed as part of the implementation of the deployment and so is actually part of the installation process.

The method that was designed interactive usage is the import process which can be run interactively from the Tools->Application Options dialog and the  Customize User Commands... dialog.

 

Please let me know if you need any more information about creating or using deployments.

 

Thank you,

Scott



Scott Hawkins

Inventor Software Developer
Message 42 of 63
Scott.Hawkins
in reply to: ACEDeSmedt

Please be careful about trying to wrap this up as something that will be run on every start.

The problem is that when the /register command line switch is used, then the registration occurs in the background even though Inventor returns immediately.

So if you try to rerun Inventor immediately in the interactive mode you might get something like this:

 

Inventor is reregistering.png

 

This may or may not happen, and it could take a variable amount of time to finish, so putting a fixed delay would not be safe and would just tend to annoy users by forcing them to wait.

 

Thank you,

Scott



Scott Hawkins

Inventor Software Developer
Message 43 of 63
ACEDeSmedt
in reply to: Scott.Hawkins

Are you sure control is directly given back?

I've just tested it on Inventor 2015 and the inventor.exe process is running for several seconds in the background and no child processes are started up.

 

I've also tested it with a *.bat file and it seems to work as expected:

 

@echo off
echo Loading customizations
call "C:\Program Files\Autodesk\Inventor 2015\Bin\Inventor.exe" /language=ENU /importcustomizations="C:\Users\klaas.de.smedt\Desktop\Test.xml" /register
echo Starting Inventor
start "" "C:\Program Files\Autodesk\Inventor 2015\Bin\Inventor.exe" /language=ENU

 

The difference in the call command and the start command is that call won't return control to the bat script until the called process is finished. The start command is used to close the bat file after Inventor is started.

 

Disclaimer: my customization file was a recent export and doesn't supply any changes to the customization of Inventor.

 

Regards,

Klaas De Smedt

=================================
If this is the solution, push the solution button 😉 (and maybe some kudos)
Autodesk Product Design Suit - Ultimate edition (Subscription)
Message 44 of 63
Scott.Hawkins
in reply to: ACEDeSmedt

Hi Klaas,

 

I am certainly not a bat file expert, and I can see that you know more about it than I do.  What makes me nervous is that if I run Inventor /register on the command line it returns immediately to the prompt and if you fire off another Inventor command immediately then you get the reregistration dialog.  Perhaps a Windows shell spawns all commands in a new process and returns automatically?  I am most familiar with shells such as bash that will block unless you put commands explicitly into the background.

 

If your solution works reliably for you, and you want to try to prevent the user from changing your settings, then it sounds like a good solution.

 

Thank you,

Scott



Scott Hawkins

Inventor Software Developer
Message 45 of 63
Milan_Nosil
in reply to: ACEDeSmedt

Hi Klaas,

 

Thank you so much. That's exactly what I needed!! Smiley Very Happy

Thank You and Scott for your effort. (When I asked Autodesk, they told me the command line was broken Smiley LOL )

 

 

Best regards

Milan Nosil

Message 46 of 63
Milan_Nosil
in reply to: ACEDeSmedt

I've been experimenting a bit - I've done it to perfection. The click on the Inventor icon will launch the .bat file on background (the process is invisible).

 

The basis is your .bat file - then I create a text file with the end .vbs.

In this .vbs file is written:

 

Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.run "%comspec% /c C:\Users\******\Desktop\Inventor_2018.bat",0
Set WshShell = Nothing

 

(C:\Users\******\Desktop\Inventor_2018.bat - replace your own path to the .bat file)

 

 

Then open the propetries Inventor shortcut icon (desktop) and write application target - path to .vbs file.

 

 

It's done Smiley Wink

 

Milan Nosil

 

 

Message 47 of 63
ACEDeSmedt
in reply to: Milan_Nosil

I Have some code that will wait until a process is ended in VBA; maybe it will port easily to vbs so you can get rid of the bat file:

 

Dim command As String
command = "" ' Insert the inventor command here

Dim Program As New IWshRuntimeLibrary.WshShell
Program.Run command, vbHide, True

Program = Nothing

 

=================================
If this is the solution, push the solution button 😉 (and maybe some kudos)
Autodesk Product Design Suit - Ultimate edition (Subscription)
Message 48 of 63

@johnsonshiue

 

Hi Johnson,

 

You wrote the following:

 

"Hi! I am on R2011SP1 also. I just tried it 5 minutes ago and it works for me. You need to follow the format exactly. Here is the target path I have in the R2011 shortcut.

 

"C:\Program Files\Autodesk\Inventor 2011\Bin\Inventor.exe" /IMPORTOPTIONS="C:\Program Files\Autodesk\Inventor 2011\Preferences\MyApplicationOptions.xml"

 

Please note that my OS is XP and the Inventor 2011 path could be different if you are not on XP. Plus the options xml file path and file name will be adjusted according to your system.

Thanks!"

 

 

Do you know if It is possible to load also some perferences (User perferences regarding the ribbon), together with the application options?

 

Regards,

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

Message 49 of 63

Hi Arthur,

 

I will answer for Johnson, since his post was in 2010.

There is a more recent post where this was addressed.

I assume that you are not still using XP

 

importing customizations from command line 

 

Thank you,

 



Scott Hawkins

Inventor Software Developer
Message 50 of 63

Thanks,

But the shortcut is not working.
Could you please take a look?

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

Message 51 of 63

The link is set to open in a new tab.

Maybe your browser does not allow that.

The link is:

 

https://forums.autodesk.com/t5/inventor-forum/start-inventor-with-fix-application-options/m-p/738908...

 

Or you can just browse back to it.

The message time date is 

09-18-2017 03:16 PM (September 18, 2017)

 

Hope that helps.



Scott Hawkins

Inventor Software Developer
Message 52 of 63

That is the link to this topic.
I am asking for two xml files loading on startup!!

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

Message 53 of 63

Hi, if it helps you, I worked this topic on the blog (but it's written in Czech) Smiley Wink

 

https://www.inventor3dblog.cz/inventor-automaticke-nacitani-nastaveni-pri-spusteni/ 

Message 54 of 63

you can pass both files this way (I tested few minutes ago, and don't mess up simple quotes with double quotes because the HAVE to be double quotes, otherwise you will waste the next 2 hour to figure out why it doesn't work as it happened to me Smiley Embarassed 😞

"C:\...\Inventor.exe" /importoptions="<FQFN to your application options xml>" /importcustomizations="<FQFN to your customization xml>"

the effect will be that the settings specified in your XML files will override (at next restart) whatever the user has specified in his session.

You need to plan a little bit carefully where you will place your files because in Windows there is a length limit to what you can specify in a shortcut

Massimo Frison
CAD R&D // PDM Admin · Hekuma GmbH
Message 55 of 63
Jakob_Hamburg
in reply to: freesbee

Hi! I am using Inventor 2021 on Windows10.

 

I have to work for two different departments which use different settings.

I want to start Inventor with different Application settings, therefore I added in the windows icon in the field "target" the relevant importoptions. (In the end I will have two windows icons on my desktop.)

 

My "target" field says now:

"C:\Program Files\Autodesk\Inventor 2021\Bin\Inventor.exe" /IMPORTOPTIONS ="C:\Users\xxx\AppData\Local\Autodesk\Inventor2021\Preferences\ApplicationOptions_test.xml"

 

But the Application options do not change. The "ApplicationOptions_test.xml" is not loaded.

Does this switch not work for Inventor 2021? Or is it that I don not have admin rights on this computer?

Can anybody please help me?

 

Message 56 of 63

Can you share the ShortCutFile.

Can you make a screenshot like this:

bradeneuropeArthur_0-1632999737535.png

 

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

Message 57 of 63

My shortcut looks like this:

Jakob_Hamburg_0-1633000014235.png

 

Message 58 of 63
SharkDesign
in reply to: michael_marx

I assume you are replacing the XXX with the actual user name?

 

 

  Expert Elite
  Inventor Certified Professional
Message 59 of 63
Jakob_Hamburg
in reply to: SharkDesign

yes, sure
Message 60 of 63


@Jakob_Hamburg wrote:

 

Does this switch not work for Inventor 2021? Or is it that I don not have admin rights on this computer?

 

 


I wanted to say: "Or is it because I do not have admin rights on this computer?"

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

Post to forums  

Autodesk Design & Make Report