Switch view based off content of text box - InfoPath Dev
in

InfoPath Dev

Switch view based off content of text box

Last post 02-14-2008 11:14 AM by barmatt80. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 02-12-2008 10:52 AM

    Switch view based off content of text box

    I do not think it is possible, but just want to check.  I have a text box(txtBox1) and based on what is typed in that text box, I want it to change to another view(VIEW2).  Is it possible to do this with code?

    I would like to use somethign like this on the on after chage event for the text box:

    If thisXDocument.DOM.selectSingleNode("/my:myFields/my:txtBox1").text = "0" Then

    thisXDocument.View.SwitchView("VIEW2") End If

    I got it to work, but only if I used the above code in a button rather than in the on text change event.

     Any suggestions? or am I stuck with a button?

     

    Thanks

     

  • 02-14-2008 11:14 AM In reply to

    Re: Switch view based off content of text box

    I found out that using code two switch views is not available using OnAfterChange or OnBeforeChange events.  Though still looking for a work around.  I think I will just have to add another step in the forms.

Page 1 of 1 (2 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.