• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Discussion Groups

    Autodesk Vault Customization

    Reply
    Contributor
    Posts: 13
    Registered: ‎09-20-2012

    GetNumberingSchemesByType - AutogenField class - Current Value

    90 Views, 2 Replies
    09-20-2012 08:22 AM

    Hi,
    I'm new in this forum....

     

    I have a problem reading the AutogenField class, in particular I don't know how to read the current value of

    FieldType Autogenerated.

    I haven't found a member in this class.

     

    For example in the ComplexField ther is ComplexVal member.

     

    This is my code:

     

    foreach (NumSchmField n in num)
     {
       FieldType fT = n.FieldTyp;
        if (fT == FieldType.FixedText)
         {
            FixedTxtField f = (FixedTxtField)n;
             MessageBox.Show(f.FixedTxtVal);
             }
        else if (fT == FieldType.FreeText)
          {
             FreeTxtField f = (FreeTxtField)n;
               MessageBox.Show(f.DfltVal);
         }
         else if (fT == FieldType.Autogenerated)
         {
           AutogenField f = (AutogenField)n;

     

     

    Can anyone help me?!?

     

    ...Sorry for my bad English....:smileyhappy:

     

     

    thanks

    Michele

    Please use plain text.
    Employee
    Posts: 652
    Registered: ‎12-12-2006

    Re: GetNumberingSchemesByType - AutogenField class - Current Value

    09-21-2012 12:50 PM in reply to: Micky_SDP

    To repeat your question, you have a numbering scheme with an AutogenField and you want to know what the next number is going to be. 

     

    I don't think there is a way to get that information without generating the next number in the sequence.



    Doug Redmond
    Software Engineer
    Autodesk, Inc.
    http://justonesandzeros.typepad.com/

    Please use plain text.
    Contributor
    Posts: 13
    Registered: ‎09-20-2012

    Re: GetNumberingSchemesByType - AutogenField class - Current Value

    09-24-2012 12:05 AM in reply to: Micky_SDP

    Thank's for the reply...

     

    I try with Autocad 2013 and when I save the draw with a numbering scheme with an AutogenField, Autocad offers me the next number automatically.

     

    This information is saved into Autocad?

    Because if this is true, I can try to save this infomation into my application by code..

     

    Michele

    Please use plain text.