Skip to Content
author's profile photo Former Member
Former Member

How to access Web Dynpro Context Node from form

Hello!

I would like to access Context nodes in Web Dynpro from within an interactive form. The nodes are NOT bound to a form field. I have read about the Adobe XML Form Object Model and apparently it seems to be some java script expression like "xfa.record.<contextnodename>.<attributename>.value" (but this only works for bound data) or "xfa.datasets.data.<something>", but I just don't manage to find the right expression. Can you help?

Thanks for your help

Kind regards

Bettina Hepp

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Mar 10, 2008 at 04:36 PM

    Only the context node that's bound to the form and it's descendents are available in the form, other context cannot be accessed.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Mar 10, 2008 at 06:49 PM

    Hi,

    xfa.record.... statement will follow the tree strucure as per SOM in Data view pallete.

    If nothing helps, you may bind it to a field and make the field hidden. You may please refer the Adobe Designer help and also the` blogs related to scripting in Adobe forms on SDN.

    You will get a Form calc scripting guide and java script guide from SDN or net.

    Thanks and Regards,

    Anto.

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hello all

      thanks for reading this post. As I managed to solve this on my own, I would like to post the solution here:

      Example:

      1. Scenary: I would like to set an element in IF to readonly if a certain control variable in WD is set to "1".

      2. Web Dynpro:

      - In the WD Context I have the following structure: Context/Data/ControlData/ReadOnly (ReadOnly is an attribute)

      - In the Interactive Form properties I set the "Data"-Context-Node as "dataSource"-value

      3. Interactive Form

      - I include the following script in the "initialize" event of the element which should be dependent on the value of my ReadOnly-attribute:

      if(xfa.record.ControlData.Readonly.value == "1"){

      this.access = "readOnly";

      }

      That's it And it works!

      Kind regards

      Bettina

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.