• Blog posts


    By Luke Davenport 


    You would like a ‘Select Folder’ dialog box to pop up when running an iLogic rule, to choose the destination folder/directory for file to be exported.


    As usual, our brave Inventor leader Curtis Waguespack has got some useful iLogic code allowing user to pick a destination folder for a ‘Save As’ operation. 


    But this is only suitable for saving Inventor files as Inventor files. If you want to export a PDF, STEP, DWF, DXF etc. etc. and have the browser pop up for destination folder then we need some other codes…

    Also, there is some info online for creating a File Open dialog box using iLogic - using code similar to below, but this is selecting an Inventor file not a folder, so it’s no good for this purpose.

    Well given that we can use most VB.Net code in an iLogic rule, we can take advantage of the common or garden FolderBrowserDialog no worries. 

    You can download a working example iLogic rule below. It will do the following when run from any Inventor file:

    • Prompt the user to pick a folder from Windows explorer (with option to create a new folder if desired)
    • Export a generically named example PDF to the selected folder.
    • Ask user if they want to open the exported PDF. 

    A couple of notes:

    • I imagine you won’t want your exported file to be called ‘EXAMPLE EXPORTED FILE NAME’ – so this will need to be tinkered with of course.
    • Apologies to my distinguished English readers for using the US spelling of ‘Dialogue’ J - He who writes the programming language makes the rules….

    Download the code HERE