How do you divide a segment equally with a range in visual basic?
length is 144 in
range- 7.5 - 9in
answer- (18) at (range 8 in)
like to know how to do this in Visual Basic so I can create some rules and forms in iLogic
Solved! Go to Solution.
There are loads of ways to do this. Here is one:
Sub Demo() Dim Length As Double Dim Range As Double Length = 144 Range = 8 MsgBox (Answer(Length, Range)) End Sub Function Answer(L As Double, R As Double) Answer = L / R End Function
This should be a start for you
Yes, it's not difficult, but can be tricky and frustrating! Parameters can be pretty fickle when it comes to units.
If you have:
d0 = Length (in)
d1 = Range (in)
d2 = Answer/Segments (ul)
Note that the inch units cancel each other to give a unitless value (in/in = ul).
Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register
Start with some of our most frequented solutions to get help installing your software.