Define a condition in a preserve code block - InfoPath Dev
in

InfoPath Dev

Define a condition in a preserve code block

Last post 07-18-2006 10:07 AM by Greg Collins. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 06-29-2006 12:56 AM

    Define a condition in a preserve code block

    Hi,

    What I try is to define a conditionnal formatting in a preserve code block.

    My problem is that the field is in a secondary data source and I want to make my condtionnal formating based on a field in the primary datasource.

    How can I do for go select a field value in my primary datasource!

    Ex:
    <xsl:when test="xdXDocument:GetDOM()/CaseList/Case/@CHNR != "" and 
    xdXDocument:GetDOM("configuration")/Config/getOrt/List">DISPLAY: none</xsl:when>


    That don't work I have also try with "" in the getDOM but no result.

    Any Idea?

    Thanks
    Infopath 2007, Langage: C#2.0 (Modèle Objet 2003)
    merci de lire ceci
  • 06-30-2006 10:42 AM In reply to

    Re: Define a condition in a preserve code block

    The easiest way to do what you want is to first create your condition on a field that is NOT in a preserve code block -- then look at the restulting XML and copy it to your field that IS in your preserve code block.
  • 07-05-2006 05:55 AM In reply to

    Re: Define a condition in a preserve code block

    Hi Greg,

    Thanks for the idea I have try to make some condition and after make my code block but the problem is that my ddl is in the secondary datasource but in the view.xsl there is in a primary datasource template. So when I make a preserve template I cant call only @CHNR like it was before in my view.xsl. I am in a secondary datasource template.

    So my question is how to call the primary datsource from a secondary template?

    Thanks
    Infopath 2007, Langage: C#2.0 (Modèle Objet 2003)
    merci de lire ceci
  • 07-18-2006 10:07 AM In reply to

    Re: Define a condition in a preserve code block

    Again, the key here is to do something similar outside of a preserve code block first and then look at the resulting XSL. It will show you exactly the kinds of structures you need in order to call from primary to secondary and back. Then you can manually work the code in the preserve code block to match.
Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.