Results 1 to 3 of 3

Thread: Fields with formulas not updating in block

  1. #1
    I could stop if I wanted to
    Join Date
    2011-09
    Posts
    308
    Login to Give a bone
    0

    Default Fields with formulas not updating in block

    Hiya gang,

    I'm working on a block for a client and I've hit a roadblock.

    Basically the block is a slope arrow.

    Upon insertion the user is prompted for two values stored in attributes:


    • Slope High Point
    • Slope Low Point


    What I want is for the slope text in the block to display the slope as a percentage based on this formula:

    ((HighPoint-Lowpoint)/Distance)*100)

    Where Highpoint and Lowpoint are the values entered by the user on insertion and Distance is the value of the Polar Stretch.

    I can get Highpoint mnus Lowpoint to work, and I know I can resolve the distance of the stretch parameter, but I can't seem to make the complete formula work.

    I can get each step of the formula to work so I have made a test block with multiple attributes, each with one step of the formula, and this works, but when ever you change the any of the values you have to regen like 4 times to get all the formulas to update.

    I'd like the slope value to just change as you drag the grip. I'm sure it's just some syntax issue when I'm trying to do it all in one formula.

    Block is attached, all attributes visible for troubleshooting sake. They are in the lower left and they represent:


    • High Point of slope (entered by user on insertion)
    • Low point of slope (entered by user on insertion)
    • Difference in height
    • Distance of stretch parameter
    • Slope RAW (Difference in height divided by distance)
    • Slope Percent (Slope RAW x100)


    Hope you can shed some light on this for me.

    Thanks in advance,

    -JP
    Attached Files Attached Files

  2. #2
    I could stop if I wanted to
    Join Date
    2011-09
    Posts
    308
    Login to Give a bone
    0

    Default Re: Fields with formulas not updating in block

    Hiya gang, there seemed to be a great deal of confusion about this on the Autodesk forums becuase the block I uploaded was my test/troubleshooting block that I used just as a proof of concept.

    So... attached is the original (non functioning) block.

    It has 2 attributes only:

    • High Point
    • Low Point



    The text on the slope line contains a field that is a formula:

    ((Highpoint value-lowpoint value)/distance1)100


    It works (or doesn't) like this:


    1. Insert the block
    2. User is prompted to enter the value for High Point
    3. User is prompted to enter the value for Low Point
    4. Stretch the arrow
    5. The formula should calculate the slope percent based on entered info and the length of Distance1


    Hope this clears things up. And thanks all for your help.
    Attached Files Attached Files

  3. #3
    Woo! Hoo! my 1st post
    Join Date
    2016-11
    Posts
    1
    Login to Give a bone
    0

    Default Re: Fields with formulas not updating in block

    Use this:
    ((Highpoint value-lowpoint value)/distance1)*100

Similar Threads

  1. Formulas For Fields
    By DavidMacomber in forum AutoCAD Fields
    Replies: 7
    Last Post: 2016-04-21, 04:42 PM
  2. Replies: 0
    Last Post: 2009-05-01, 03:25 PM
  3. Updating Title Block Fields Using SSM
    By nogienugz in forum AutoCAD Sheet Set Manager
    Replies: 4
    Last Post: 2008-01-24, 03:23 AM
  4. Replies: 7
    Last Post: 2007-06-07, 03:58 PM
  5. Excel Formulas in Fields
    By red2002yzfr1 in forum AutoCAD Fields
    Replies: 2
    Last Post: 2005-07-28, 06:21 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •