Community
Inventor Programming - iLogic, Macros, AddIns & Apprentice
Inventor iLogic, Macros, AddIns & Apprentice Forum. Share your knowledge, ask questions, and explore popular Inventor topics related to programming, creating add-ins, macros, working with the API or creating iLogic tools.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Tricky template using advanced API

4 REPLIES 4
SOLVED
Reply
Message 1 of 5
S7RM7RPR
314 Views, 4 Replies

Tricky template using advanced API

Firstly, I'm posting this because I'm having problems with a work project so I apologize if I'm vague but there are some things I can't post.

 

I'm attempting to make a standard title block for an extremely variable product, there are specific parts of our product that don't change however. What I am doing is including those "standard" parts in the title block so that they can't be edited and can be used wherever the titleblock is needed.

 

Now, for these standard sections there are a few dimensions that change. The way I have it set up right now is I am using this technique,

 

http://inventortrenches.blogspot.com/2014/06/ilogic-titleblock-project-data-from.html

 

to get all the different variables I need. The problem I'm having now though is that I can't figure out how or if I can use stacked fractions. I have fractions set up in excel, they are going to inventor and getting put in their appropriate fields, but they are appearing as 3/4 instead of stacked.

 

I'm hoping there is some API or VBA code I can use to accomplish this that I have not yet discovered. If there is nothing can you please suggest another option?

 

Note, the details in the title block need to be completely seperate from whatever 3D model is used because of the variability. All the information is being imported from an external source via iLogic or Excel.

 

I'm using Inventor 2015 if that makes a difference.

4 REPLIES 4
Message 2 of 5
Message 3 of 5
ekinsb
in reply to: S7RM7RPR

Inventor does support stacked fractions.  To do any fancy text formatting in the API you use the FormattedText property of whatever object it is that contains the text.  If you open Inventor's Programming Help, click the "Search" tab and enter "XML Tags for FormattedText" you'll find a topic titled the same thing.  This explains how Inventor uses an XML formatted string to allow you to define all of various formatting options.  Towards the bottom of the document it describes how to create a string that has stacked fractions.

 


Brian Ekins
Inventor and Fusion 360 API Expert
Mod the Machine blog
Message 4 of 5
S7RM7RPR
in reply to: ekinsb

The question I should be asking then is if i can format the "prompted text" box or not. The "prompted text" box seems to behave entirely differently from a normal text box
Message 5 of 5
ekinsb
in reply to: S7RM7RPR

Unfortunately it appears that prompted text fields do not support any special formatting so this is not currently possible.  I suggest you post this on the Inventor IdeaStation forum.


Brian Ekins
Inventor and Fusion 360 API Expert
Mod the Machine blog

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

Post to forums  

Autodesk Design & Make Report