We have a standard block called "title_bubble" that we pull into our drawing views to label the view (see images below).
Within that block is an attribute called "5 Scale". This attribute is linked to the view scale and the format is driven by the system defaults in the form of 1:4.
On our Metric Drawings this format is fine; however, when working in Imperial Drawings our Clients expect to see an Architectural format in the form of 3"=1'-0".
The math for converting the scale is simple - taking the 1:4 scale and converting it to a fraction of 1/4 and then multiplying it by 12" (1'-0" converted to inches) and the result is 3". This Resulted Value would then need to be put into a string such as X=1'-0" where X is the resulting value (3").
Would it be possible to create a macro that:
1) finds a block named "title_bubble"
2) looks up the $PRPMODEL:"SW-View Scale(View Scale)" value that the block is attached to
3) Converts the view-scale from a ratio to a fraction (ex. 1:4 converts to 1/4)
4) applies the math (fraction * 12 = X)
5) strings the result into the final format (ex "SCALE X=1'-0"")
6) overwrites the value of the attribute named "5 Scale" with the final scale format from step 5
7) Finds the next block and repeats steps 1-6, else ends.
I'm unable to start the code myself, so I'm hoping someone could assist me with the development of this macro or even suggest an alternative solution.
Thanks in advance.
-Shaun