Is there any way, in plain vanilla MicroStation, to measure the slope of a line? Assuming 2D, basic XY coordinates, no exaggeration.
Thank you
MaryBMSTN 08.11.09.397
Slope cannot be calculated in a 2d file. Slope is relationship of the change in elevation to the horizontal distance. There is no elevation in a 2d file. The provided basic macro requires a 3d file.
Not true. Macro reports a 2D slope based upon Delta Y/ Delta X but 3D slope based upon Delta length/Delta Z.
This version adds a place text above line in the middle - only uses 2D slope in this version.
Charles (Chuck) Rheault CADD Manager
MDOT State Highway Administration
My post is simply a slightly modified version of the original. It still echo's 2D (and 3D) slopes, but only uses the 2D slope as a label.
I had one a while ago that did that. I will see if I can locate it.
What you need in these, is a check against a rotated view as this version will give wrong result as written. There are alternatives to get the slope in any view orientation, but I have always struggled with that type of code.
What I imagine in a finished macro, is a dialog box that opens after accepting the line and in the dialog box is the slopes with radio buttons so you can select 2D or 3D slope as a label and options for % slope, rise over run, run over rise and different labeling options - above, below, by origin or in a leadered note.
CAD COP I have that one I think it was by Tim shoemaker of the TMC but it is compiled version of bas and needs 2 macros but it only works in XM not 8i.. slopeset.ba and Slope.ba
the Slopeset.ba works in 8i but not the label slope which is slope.ba,
Lorys
Started msnt work 1990 - Retired Nov 2022 ( oh boy am I old )
But was long time user V8iss10 (8.11.09.919) dabbler CE update 16 (10.16.00.80)
MicroStation user since 1990 Melbourne Australia.click link to PM me
Here is a vba I wrote many years ago, it does ratio/percent as allows for exag, and adding a negative in front of the number. The keyin is "vba run [slopelabler]startup.main". it does not factor the z in a line.
Larry WilsonLWilson@LJBinc.com
Unknown said: Here is a vba I wrote many years ago, it does ratio/percent as allows for exag, and adding a negative in front of the number. The keyin is "vba run [slopelabler]startup.main". it does not factor the z in a line.
thanks a big bunch Lawrence
from Lorys
Larry
Looks like I spoke too soon,
I get run time error windows 7 , ustn ss1 but the dialog runs