Results 1 to 10 of 10

Thread: Appending to an expression in annotation template

  1. #1
    100 Club JeremiahM's Avatar
    Join Date
    2000-12
    Location
    Colorado Springs, CO
    Posts
    186
    Login to Give a bone
    0

    Question Appending to an expression in annotation template

    I need help figuring out and expression. I am creating an annotation template for parcels that I want to show the APN# and Area in acres. The format of the annotation should be as follows:

    APN# xxx-xxx-xxxx
    xx.xxx ac.

    What I have so far is:

    APN# xxxxxxxxx.xxx
    xx.xxxxxxxx (created and expression to divide Polyline AREA by 43560.17)

    So far I can fudge the the "APN #" by placing it as text before the annotation attribute and left justifying everything, but I would prefer a prefix in the expression so I can use a center justification and I dont know if the hyphenation is possible.

    I would like to add a suffix of "ac." to the acerage and limit the amount of decimal places shown.

    Thanks for the help,

    Jeremiah

  2. #2
    AUGI Addict
    Join Date
    2015-12
    Location
    Arizona
    Posts
    2,478
    Login to Give a bone
    0

    Default Re: Appending to an expression in annotation template

    Jeremiah


    Is the parcel area in your connected database?
    If so that annotation template should select from
    DATA, and read from the connected database.

    Have the parcels been used to create a polygon topology?
    If so then a Topology query would work to place the area Label
    at the centroid of the poloygons.

    This might be easier to help you set-up if you
    sent a small sample of your data, and the connected
    database if any.

    I would also like to see what you have used, that you believe
    will take the polyline area, and perform any mathematic evaluation
    of it in an annotation template. As I have experiented with this
    functionality, and it causes MAP to return an invalid expression
    when editing the annotation template, and results in either no label
    being placed or a text string value, like only APN and no parcel number
    even when I connect it to the correct database.
    Last edited by mjfarrell; 2004-07-22 at 09:26 PM.

  3. #3
    100 Club JeremiahM's Avatar
    Join Date
    2000-12
    Location
    Colorado Springs, CO
    Posts
    186
    Login to Give a bone
    0

    Default Re: Appending to an expression in annotation template

    Right now I am grabbing the APN from Object Data and the area from the Polyline area property.

    APN Expression: :NO_APN@019_parcel_w_prcl_all_tab

    Area Expression: (/ .AREA 43560.17)

    Sorry, can't send data.

    Jeremiah

  4. #4
    AUGI Addict
    Join Date
    2015-12
    Location
    Arizona
    Posts
    2,478
    Login to Give a bone
    0

    Default Re: Appending to an expression in annotation template

    Well in my little world I can grab the APN from the linked database
    and the area from the polyline area and this works perfect.
    However when I attempt to have it return the area using the expression
    (/ .AREA 43560) the annotation template then only returns the TAG value
    in my case the number two (2)
    And any attempt to append a prefix to the parcel number also causes it to fail
    to return the parcel number.
    That and an error message when editing the template Unsupported operator specified in expression: /.AREA
    Where did you read that you should be able to add to the text field in an
    annotation template, or is this something you thought they would do?


    I just tested the template again, and I had left a space out after the (/)
    so that part works for me now.
    Now I am wondering why it wont let me put APN# in front of the parcel number??
    Great question!
    Last edited by mjfarrell; 2004-07-22 at 10:14 PM.

  5. #5
    AUGI Addict
    Join Date
    2015-12
    Location
    Arizona
    Posts
    2,478
    Login to Give a bone
    0

    Default Re: Appending to an expression in annotation template

    Well, I am eagerly awaiting the final on this.
    At this time it appears the it will do the math
    no problem. Only adding any suffix or prefix text
    seems to cause the annotation to fail.
    The help file hints at this, only does not explicitly
    say that it will not.

  6. #6
    AUGI Addict Glenn Pope's Avatar
    Join Date
    2001-05
    Location
    Austin, TX USA
    Posts
    2,201
    Login to Give a bone
    0

    Default Re: Appending to an expression in annotation template

    You can use lisp in the expression. This should work for the area.

    (strcat (rtos (/ .AREA 43560.00) 2 2) " AC")

  7. #7
    AUGI Addict Glenn Pope's Avatar
    Join Date
    2001-05
    Location
    Austin, TX USA
    Posts
    2,201
    Login to Give a bone
    0

    Default Re: Appending to an expression in annotation template

    Is the APN a real number or integer or character in your object data?

  8. #8
    AUGI Addict
    Join Date
    2015-12
    Location
    Arizona
    Posts
    2,478
    Login to Give a bone
    0

    Default Re: Appending to an expression in annotation template

    In my world they are both real numbers
    and occasionally they have alpha characters
    at the end or beginning. Don't ask me why.

  9. #9
    100 Club JeremiahM's Avatar
    Join Date
    2000-12
    Location
    Colorado Springs, CO
    Posts
    186
    Login to Give a bone
    0

    Default Re: Appending to an expression in annotation template

    Thanks Glenn,

    That worked for the area, i'm not real educated in Lisp...

    The APN OD is the Character Type, I tried to modify what you did with the area formula, but to no avail...

    Jeremiah

  10. #10
    AUGI Addict Glenn Pope's Avatar
    Join Date
    2001-05
    Location
    Austin, TX USA
    Posts
    2,201
    Login to Give a bone
    0

    Default Re: Appending to an expression in annotation template

    This will get you the APN# in front of the number.
    (strcat "APN# " :NO_APN@019_parcel_w_prcl_all_tab)

    About the hyphenation
    So far I can't get the hyphens. There seems to be a limit of 3 in the number of operations you can do in an expression. To put in the hyphens you need 4. This is the expression needed.
    Code:
    (strcat "APN# " (substr :NO_APN@019_parcel_w_prcl_all_tab 1 3) "-" (substr :NO_APN@019_parcel_w_prcl_all_tab 4 3) "-" (substr :NO_APN@019_parcel_w_prcl_all_tab 7))
    This would turn what in the OD "XXXXXXXXXX" to "XXX-XXX-XXXX".

Similar Threads

  1. Prefix in annotation template?
    By KrakowiAneczka in forum AutoCAD Map 3D - Annotations
    Replies: 4
    Last Post: 2011-07-14, 11:44 PM
  2. Define Annotation Template
    By brian.young in forum AutoCAD Map 3D - General
    Replies: 3
    Last Post: 2009-01-21, 12:50 PM
  3. can't insert customized annotation in the template
    By jlizann in forum Revit Architecture - General
    Replies: 1
    Last Post: 2006-12-07, 10:38 AM
  4. ANNOTATION TEMPLATE
    By VBOYAJI in forum AutoCAD Map 3D - General
    Replies: 1
    Last Post: 2006-11-01, 05:01 PM
  5. How to get dwg variables in annotation expression builder?
    By norrin in forum AutoCAD Map 3D - General
    Replies: 7
    Last Post: 2006-05-02, 08:12 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
  •