Switch View on value change (Not form load or button) - InfoPath Dev
in

InfoPath Dev

Switch View on value change (Not form load or button)

Last post 07-22-2013 07:51 AM by BejeweledOne. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 07-19-2013 09:42 AM

    Switch View on value change (Not form load or button)

    I had hoped that Qrules would solve this issue for me but it doesn't appear to. I have a browser form and I need either a dialog box to appear (collapsible section will not meet this need) or a view switch when a person selects a specific option. I have an option button where they are selecting from one of two values. If they select one of the values I need to be able to generate the dialog box or switch to a view where they are presented with a message that they have to accept before they go back to the 'form'. I see where Qrules has the ability to show a dialog box (but not for a browser form) or to set the default view. Is it possible to use the 'set default view' to change to another view when this value changes or does it only work on form load? Is there another option in Qrules that will help this situation? Thanks
  • 07-19-2013 10:03 AM In reply to

    Re: Switch View on value change (Not form load or button)

     Hi - the limitations you are seeing are based on limits within InfoPath itself. We can't display dialog boxes in a browser form, even in the code. The object model doesn't allow it. We can't switch views on field changes.

    I think the work around I would use is:

    Put all the controls on the form in a section.

    Put a message to the user with an "okay" button in another section.

    If they select the value where you need to display the message, hide the section with all the controls and display the section with the message with the okay button for them to accept the message.

    I think this would fill your requirement as well as switching views or dialogs, don't you?

    Hilary Stoupa

  • 07-20-2013 05:49 PM In reply to

    Re: Switch View on value change (Not form load or button)

    Right!

    If your view is of a reasonable length (<4 pages in InfoPath Designer) then you should use sections, not separate views.

    Why?

    • views take seconds to switch to, sections don't
    • sections can be maintained with less effort, no separate view updates needed
    • Hilary's workaround works

     

    Patrick Halstead
    Project Manager at Qdabra
  • 07-22-2013 07:51 AM In reply to

    Re: Switch View on value change (Not form load or button)

    Actually because of the form and how many sections it has that are hidden/displayed at any given time/state of values on the form, that would not be the best option. I considered that first when I realized I couldn't do a popup dialog box. Also, we needed to make this something that would stand out and that the form user would have to read.


    I got around it another way based on a brief post by Jimmy from several years ago. I used 4 picture buttons, 1 value field, a set of formatting rules and a couple of action rules to do what I wanted. I have attached a sample form for anyone who is interested. It's really very simple and the form user won't know the difference.
Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.