Message 1 of 3

Not applicable
04-15-2021
08:18 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello, I'm new to iLogic and I need to create a rule that will read some iProperties values and save them as custom properties, with assigned name and value converted to text.
It's because I later must export this model to IFC (using 3rd party software) and my properties set as number (not all of them), are displayed in IFC model with many more decimal places (different unit) than that showed in iProperties tab in Inventor.
I'm using Inventor 2015
Here is a preview of my code:
dl = Round(SheetMetal.FlatExtentsWidth,0) szer = Round(SheetMetal.FlatExtentsLength,0) gr = Round(Parameter("Grubo��"),0) volume = iProperties.Volume If dl<szer Then wym = szer ElseIf szer<=dl Then wym = dl End If vol = volume/1000000000 powi = vol/(gr/1000) iProperties.Value("Custom", "O40 Areal [m2]") = powi iProperties.Value("Custom", "O41 Volum [m3]") = vol iProperties.Value("Custom", "O42 Lengde [mm]") = wym iProperties.Value("Custom", "O43 Tykkelse [mm]") = gr iProperties.Value("Custom", "O44 Profil") = iProperties.Value("Project", "Stock Number")
Parameters O40 and O41 are those in question. O42 and O43 are exported as needed.
I suppose that saving a value as text would solve the problem of this strange conversion during export.
Have a nice day
Solved! Go to Solution.