HumbleChief Posted April 7, 2016 Share Posted April 7, 2016 ...and make it unusable out of the box? Seriously. Why? Can anyone answer that question? Chief? SEVEN decimal places? Seriously? Who made that decision? And why isn't there a clear, easy to understand article on how to round to various, actually usable, decimal places? Truly stumped here. I don't use macros much but need them occasionally for specific projects and tonight I was using them to show the area of Poly Lines for a site plan and add the %area% macro and it resolves to SEVEN decimal places. So, so frustrating. So I scour the forums and the internet to find a clue and of course Joe has some very helpful information that is unfortunately unfathomable to the every day user. So I've wasted an hour trying to figure out how to get a simple poly line label to resolve to 0 decimal places - with absolutely no help from Chief help files or on line articles. So what was the reason to include this 'feature' when it is completely unusable without re-writing the macro? Anyone? EDIT: And why seven decimal places? Genuinely curious. Why not 12? 15? Or a usable 2 and let the macro guys get to 7 if need be but where in Chief, anywhere, for any reason would you need seven decimal place accuracy? Just a really strange mind set that I simply don't understand. Link to comment Share on other sites More sharing options...
johnny Posted April 7, 2016 Share Posted April 7, 2016 I haven't used it yet but are you telling me the area ends up with 7 decimal regardless if you want that or not? So you want it to show 24.50 SF and it shows 24.5072054? That is nuts if thats what we are talking about. Link to comment Share on other sites More sharing options...
Joe_Carrick Posted April 7, 2016 Share Posted April 7, 2016 You need a Ruby "User" macro. Here's one for you - name it PolyArea referenced ? obj=referenced : obj=owner obj.area.round(0) - or- owner.area.round(0) That's all there is to it. Link to comment Share on other sites More sharing options...
HumbleChief Posted April 7, 2016 Author Share Posted April 7, 2016 I haven't used it yet but are you telling me the area ends up with 7 decimal regardless if you want that or not? So you want it to show 24.50 SF and it shows 24.5072054? EXACTLY what you get out of the box. Just really strange thinking. Link to comment Share on other sites More sharing options...
HumbleChief Posted April 7, 2016 Author Share Posted April 7, 2016 You need a Ruby "User" macro. Here's one for you - name it PolyArea referenced ? obj=referenced : obj=owner obj.area.round(0) - or- owner.area.round(0) That's all there is to it. I knew you'd have some useful help Joe and I appreciate it greatly but why should I need anyone's help for such a simple task? What do you think they were thinking when they included this 'feature'? Did you ever talk to Dermot about such things? It's just so bizarre to me. Do you have a theory? And thanks again. Link to comment Share on other sites More sharing options...
Joe_Carrick Posted April 7, 2016 Share Posted April 7, 2016 I knew you'd have some useful help Joe and I appreciate it greatly but why should I need anyone's help for such a simple task? What do you think they were thinking when they included this 'feature'? Did you ever talk to Dermot about such things? It's just so bizarre to me. Do you have a theory? And thanks again. I don't know why they bothered to provide the "Object Specific" name value pairs for Polyline Labels. There were several of us that requested Labels for Polylines and I have a complete macro package available for Site Area Analysis using them. I sell that package for $25.00 I can say that CA doesn't seem to want to do anything more to make Ruby more useful - even though it shouldn't take much time to do so. If they would open the doors to the model data I could create macros that would allow complete annotation of Elevations and Sections including all the materials and finishes. BTW, It's not the "feature" that is a problem. It's that they tried to provide a "shortcut" custom label and didn't think about the number of decimal places that would be appropriate for Imperial and/or Metric users. In addition, the %area% macro they provided is in Sq.Ft. for Imperial Units but there might be cases where you would need it in Sq.In. or Sq.Yds or even Acres. There is no way to perform any direct calculations on the output of %area% Link to comment Share on other sites More sharing options...
HumbleChief Posted April 7, 2016 Author Share Posted April 7, 2016 I don't know why they bothered to provide the "Object Specific" name value pairs for Polyline Labels. There were several of us that requested Labels for Polylines and I have a complete macro package available for Site Area Analysis using them. I sell that package for $25.00 I can say that CA doesn't seem to want to do anything more to make Ruby more useful - even though it shouldn't take much time to do so. If they would open the doors to the model data I could create macros that would allow complete annotation of Elevations and Sections including all the materials and finishes. BTW, It's not the "feature" that is a problem. It's that they tried to provide a "shortcut" custom label and didn't think about the number of decimal places that would be appropriate for Imperial and/or Metric users. In addition, the %area% macro they provided is in Sq.Ft. for Imperial Units but there might be cases where you would need it in Sq.In. or Sq.Yds or even Acres. There is no way to perform any direct calculations on the output of %area% I don't doubt your analysis is correct Joe. I use macros so seldom that I don't seem to need them but when I do I think your package would be worth many times the amount you charge. I'm posting a video showing my ineptness even with the simple macro solutions you gave me. Link to comment Share on other sites More sharing options...
HumbleChief Posted April 7, 2016 Author Share Posted April 7, 2016 Sometimes I just feel stupid when I use Chief Architect, no other way to put it. Link to comment Share on other sites More sharing options...
Joe_Carrick Posted April 7, 2016 Share Posted April 7, 2016 Larry, Go back into that macro and check it to "Evaluate" Otherwise it just returns the text that you typed. Link to comment Share on other sites More sharing options...
HumbleChief Posted April 7, 2016 Author Share Posted April 7, 2016 Larry, Go back into that macro and check it to "Evaluate" Otherwise it just returns the text that you typed. Got the short one to work the other showed an evaluation error. Tried Eric's dbx. but still wouldn't evaluate. Really Chief why did you bother with this? And set your users up for failure? Still curious. Link to comment Share on other sites More sharing options...
Joe_Carrick Posted April 7, 2016 Share Posted April 7, 2016 I'm sorry Larry, It's a tool - a programming tool - and for those who learn the Ruby Scripting Language it works. I know there are users who just want it to be exactly what they want OOB. CA has unfortunately seldom listened intently to requests from us. It's like the Framing Schedule where they give us 2"x4" instead of 2x4 in the Nominal Size Column. They've been told it's wrong but they haven't fixed it. Link to comment Share on other sites More sharing options...
HumbleChief Posted April 7, 2016 Author Share Posted April 7, 2016 Yeah I understand Joe, just baffled by it. Thanks again for your help! I'm off to bed. Link to comment Share on other sites More sharing options...
DRAWZILLA Posted April 7, 2016 Share Posted April 7, 2016 Joe , I set up that macro and all I get is the ole eval. error. tried all the reference, owner and none, got a secret handshake. Link to comment Share on other sites More sharing options...
Joe_Carrick Posted April 7, 2016 Share Posted April 7, 2016 Perry, Can you post a pic of the macro (in Text Macro Management) ? There must be something wrong in the script. I just copy/pasted it in a new macro and checked "Evaluate" and it works perfectly. Link to comment Share on other sites More sharing options...
DRAWZILLA Posted April 7, 2016 Share Posted April 7, 2016 Perry, Can you post a pic of the macro (in Text Macro Management) ? There must be something wrong in the script. I just copy/pasted it in a new macro and checked "Evaluate" and it works perfectly. here it is Link to comment Share on other sites More sharing options...
Alaskan_Son Posted April 7, 2016 Share Posted April 7, 2016 Looks like you problem is that you copy and pasted both of Joe's suggested macros...including the "or". I believe it is one or the other, not that whole thing. Link to comment Share on other sites More sharing options...
DRAWZILLA Posted April 7, 2016 Share Posted April 7, 2016 Thanks Michael, I thought the macro was the whole thing. Link to comment Share on other sites More sharing options...
HumbleChief Posted April 7, 2016 Author Share Posted April 7, 2016 Looks like you problem is that you copy and pasted both of Joe's suggested macros...including the "or". I believe it is one or the other, not that whole thing. True that. Link to comment Share on other sites More sharing options...
rlackore Posted April 7, 2016 Share Posted April 7, 2016 I know nothing about Ruby, but I futzed around with Joe's macro and was able to make it work to output acres: referenced ? obj=referenced : obj=owner (obj.area / 43560).round(2) But it seems that my user-defined macros are saved with the plan file, so I have to export/import them to share them among plans and users. I'm also curious why they export as a .json file instead of as a Ruby script. I've saved the .json files in my default Ruby directory, but they don't automatically load when I open Chief (shouldn't they?). Link to comment Share on other sites More sharing options...
DRAWZILLA Posted April 7, 2016 Share Posted April 7, 2016 Put the macro's in your template plan, then they will always be there when needed Link to comment Share on other sites More sharing options...
Joe_Carrick Posted April 7, 2016 Share Posted April 7, 2016 Robert, .json is Chief's Export/Import format - and yes, they need to be imported into each Plan (or the Default Plan Template) in order to be available. There are ways to make some commonly used extended Ruby scripts available but that's another subject entirely. Link to comment Share on other sites More sharing options...
Joe_Carrick Posted April 7, 2016 Share Posted April 7, 2016 Thanks Michael, I thought the macro was the whole thing. Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now