Get Help

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Community
- :
- Creo Parametric
- :
- Part Modeling
- :
- Architectural Dimension Converter: Creo 2.0 + refe...

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

Showing results for

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

02-16-2013
12:25 AM

02-16-2013
12:25 AM

Architectural Dimension Converter: Creo 2.0 + references

*A recent post had me try something different.*

How do you make only a few select dimensions show feet/inches in an architectural format without changing the configuration files in Creo?

"*Simple!*" ...some would say, but I can tell you that this little exercise was a full day's work.

Suppose you need to see 9' - 4 1/2" on just one area of a drawing for say only 3 dimensions. Sure, you can edit this value easily.

But say you -*really*- need this to be associative? Say you -*really*- want to check some values quickly? Suppose you -*need*- an Architectural Calculator?

Well, here it is!

The attached file is Creo 2.0 but I have also included text files for making this work in most older versions quickly.

First of all, the image is the "Converter" in graphic format using annotations and a sketch for a driving the primary dimension. In order to convert a value, simply double-click on the sketch dimension annotation and edit the value. Regenerate the model and the variables update. The denominator limit can be set in relations.

The first 5 lines in the attached relations file include the following two user input parameters:

/* set denominator limit (2, 4, 8, 16, 32, 64, or 128)

dim0denl=16

/* inch dimension or value to be converted

dim0=d0

As you can see, you can drive this from a dimension or simply enter a value for dim0. Please notice that all the parameters are driven with the prefix dim0 so you can easily duplicate the entire list by replacing dim0 with dim1 in a text editor.

As noted, you also get control of the denominator. The relations will check for a valid value and will default to 64 if the supplied value for dim0denl (*Dimension Denominator Limit*) is inappropriate. The Converter will allow a denominator value of up to 128. More than this seems moot when using fractional formats.

There are four text annotations on the screen in order to manage presentation. The text for these annotations are included in the attached zip file as well. Please note that the Converted Value is formatted in the annotation using the appropriate parameters.

One problem I encountered was not being able to add the " (inch) symbol within a string variable in the relations. The only solution I found was to add the inch symbol at the annotation level. Also note the added space before the formatted string DIM0FRAC parameter. This allows the inch symbol to be placed directly behind the integer inch value if the fraction is 0 (zero) and therefore omitted.

The obvious question remaining is Rounding. Yes, the converter rounds up on 1/2 and greater of 1/denominator value and down for anything less as to conventional decimal conversion.

The remaining features is to drop off zero value fractions, always note feet, including 0'. Always note while inches including 0". A length less that 1/2 1/denominator value will return 0' - 0".

*I hope you have a chance to play with, or better yet, use this information. If you find this useful, please take the time to rate this document.*

Disclaimer: I have tested this to the best of my ability and as far as I can tell, it is working properly as discussed above. If for some reason you find anything to be amiss, *PLEASE* let me know so I can correct it.

Labels:

2 REPLIES 2

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

02-16-2013
01:44 AM

02-16-2013
01:44 AM

Re: Architectural Dimension Converter: Creo 2.0 + references

*You can review the relations to see if they are compatible with your version:*

/* set denominator limit (2, 4, 8, 16, 32, 64, or 128)

dim0denl=16

/* inch dimension or value to be converted

dim0=d0

/* test denominator entry (64 default on error; 128 max)

if dim0denl<>128

if dim0denl<>64

if dim0denl<>32

if dim0denl<>16

if dim0denl<>8

if dim0denl<>4

if dim0denl<>2

dim0denl=64

endif

endif

endif

endif

endif

endif

endif

/* transform feet value to string variable "feet" including zero

dim0ft=(dim0/12)

dim0ift=floor(dim0ft)

if itos(dim0ift)==""

dim0feet="0"

else

dim0feet=itos(dim0ift)

endif

dim0feet=dim0feet+"'"

/* transform remaining inch value to string variable "inch" including zero

dim0in=dim0-(dim0ift*12)

dim0iin=floor(dim0in)

if itos(dim0iin)==""

dim0inch="0"

else

dim0inch=itos(dim0iin)

endif

/* round fraction up on 1/2 denominator limit, otherwise down

dim0rem=dim0-((dim0ift*12)+dim0iin)

dim0remr=dim0rem+(1/(dim0denl*2))

dim0remn=floor(dim0remr/(1/dim0denl))

/* determine minimum denominator value; test decending order

dim0fr=(1/dim0denl)*dim0remn

dim0den=128

if dim0fr*64==floor(dim0fr*64)

dim0den=64

endif

if dim0fr*32==floor(dim0fr*32)

dim0den=32

endif

if dim0fr*16==floor(dim0fr*16)

dim0den=16

endif

if dim0fr*8==floor(dim0fr*8)

dim0den=8

endif

if dim0fr*4==floor(dim0fr*4)

dim0den=4

endif

if dim0fr*2==floor(dim0fr*2)

dim0den=2

endif

/* match numerator to denominator; confirm not-zero

dim0num=dim0fr*dim0den

if dim0num==0

dim0den=0

endif

/* build fraction string or blank if zero

if dim0num==0

dim0frac=""

else

dim0frac=" "+itos(dim0num)+"/"+itos(dim0den)

endif

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

02-16-2013
12:30 PM

02-16-2013
12:30 PM

Re: Architectural Dimension Converter: Creo 2.0 + references

very excited to try it out!

joe="thankful"

Top Tags

- ptcuser_portal
- creo_parametric_proengi…
- creo
- creo_machining_proengin…
- modeling
- creo_simulate_proengine…
- parametric
- renderings
- drawing
- design
- creo_system_administrat…
- rendering
- creo_customization_proe…
- 3d
- pro/engineer
- cad
- proengineer
- material
- arx
- assembly
- parameters
- library
- sheetmetal
- pro/e
- creo_parametric
- ptc
- graphic
- part
- wildfire5
- creo_2.0