Need To ID the Form name - InfoPath Dev
in

InfoPath Dev

Need To ID the Form name

Last post 10-24-2006 11:20 AM by Bill . 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 10-24-2006 10:13 AM

    • Bill
    • Top 200 Contributor
      Male
    • Joined on 09-26-2006
    • USA
    • Posts 57

    Need To ID the Form name

    Hello,

    I am attenmpting to see if when a form is opened if its name is Form 1. If it is, I want to set some form variables from the On Load event.

    I can not identify the object container that holds the name of the opened info path form. I tried the following but it does nothing:

    If thisXDocument.DOM.baseName.Equals("Form 1")Then
    --set some form variables
    End If

    Any help would be appreciated.

    Thanks

    Bill
    William L Fringer
    Database Administrator/Systems Integration Specialists

    L & S Associates, Inc.
    Michigan State University Corporate Research Park

    1-800-766-6185, ext 2076
  • 10-24-2006 11:09 AM In reply to

    Re: Need To ID the Form name

    I dint get what you are trying to do here but
    thisXDocument.DOM.baseName will always be null.
    "baseName" defines the nodename without namespace prefix.

    If you are looking for the filename then you need to look in
    thisXDocument.URI;
  • 10-24-2006 11:12 AM In reply to

    • Bill
    • Top 200 Contributor
      Male
    • Joined on 09-26-2006
    • USA
    • Posts 57

    Re: Need To ID the Form name

    Agni,

    Do you know the actual name?

    thisxdocument.URI.xxxxxx

    Thanks!
    William L Fringer
    Database Administrator/Systems Integration Specialists

    L & S Associates, Inc.
    Michigan State University Corporate Research Park

    1-800-766-6185, ext 2076
  • 10-24-2006 11:19 AM In reply to

    Re: Need To ID the Form name

    No you need to get it by string manipulations. Like getting the string after the last "/"
  • 10-24-2006 11:20 AM In reply to

    • Bill
    • Top 200 Contributor
      Male
    • Joined on 09-26-2006
    • USA
    • Posts 57

    Re: Need To ID the Form name

    Thanks!!
    William L Fringer
    Database Administrator/Systems Integration Specialists

    L & S Associates, Inc.
    Michigan State University Corporate Research Park

    1-800-766-6185, ext 2076
Page 1 of 1 (5 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.