Expand my Community achievements bar.

Guidelines for the Responsible Use of Generative AI in the Experience Cloud Community.
SOLVED

("Subform1.Name.ui.#textEdit.border.fill.color") - wht is 'UI' here?

Avatar

Level 8

Hello

I am new to Java script of a interactive form, when i saw adobe help, i found the below block,

When setting the background color or the fillable area for each text field, your scripts must access...properties that require a reference syntax expression that includes the number sign (#). Because JavaScript does not interpret the number sign (#) properly in reference syntax expressions, the script uses the resolveNode method to resolve the expression.

xfa.resolveNode("Subform1.Name.ui.#textEdit.border.fill.color").value = "153,204,255";

xfa.resolveNode("Subform1.Address.ui.#textEdit.border.fill.color").value = "153,204,255";

Pls. let me know
1) Here what is 'ui' (I knew user iterface, but, why did he kept here)
2) He said, '#' will not interprete correctly@! then whty did he used again here?
3) Where can i find the numbers that represent the physical visible colors, like here "153,204,255" REPRESENTS blue
4) wht is 'xfa'?
5) WHT IS 'resolveNode' here?
1 Accepted Solution

Avatar

Correct answer by
Level 10

Hi,

I will do my best to try and explain.

You are getting into involved scripting, which can be challenging to transfer from one form to another.

  1. "ui", does stand for user interface and is the method for accessing the visual appearance of the object, for example the fill colour. The script can be simplified to Subform1.Name.ui.oneOfChild.border.fill.color.value = "255,255,255";  See an example here: http://assure.ly/ewrLMo and John Brinkman's blog: http://blogs.adobe.com/formfeed/2008/10/exclusion_groups_v20.html.
  2. I am not sure what JavaSctipt would interprete the # as, but I know that # is needed when using this method. As I said above, the script can be simplified, so that you don't need to specifically reference the object's className (textEdit).
  3. The colours are expressed as Red, Green, Blue (RGB). You can explore colours at http://kuler.adobe.com/.
  4. "xfa" stands for XML Form Architecture. There is a strict structure for objects in the hierarchy. In addition there are a number of Document Object Models, one of which is the XFA DOM. xfa.resolveNode is scripting against this model. This is heavy stuff and I am struggling to describe it properly.
  5. Have a look here at resolveNode: http://assure.ly/kUP02y.

The concepts here are fairly involved and you will need to read around the topics.

I really hope this helps,

Niall

View solution in original post

1 Reply

Avatar

Correct answer by
Level 10

Hi,

I will do my best to try and explain.

You are getting into involved scripting, which can be challenging to transfer from one form to another.

  1. "ui", does stand for user interface and is the method for accessing the visual appearance of the object, for example the fill colour. The script can be simplified to Subform1.Name.ui.oneOfChild.border.fill.color.value = "255,255,255";  See an example here: http://assure.ly/ewrLMo and John Brinkman's blog: http://blogs.adobe.com/formfeed/2008/10/exclusion_groups_v20.html.
  2. I am not sure what JavaSctipt would interprete the # as, but I know that # is needed when using this method. As I said above, the script can be simplified, so that you don't need to specifically reference the object's className (textEdit).
  3. The colours are expressed as Red, Green, Blue (RGB). You can explore colours at http://kuler.adobe.com/.
  4. "xfa" stands for XML Form Architecture. There is a strict structure for objects in the hierarchy. In addition there are a number of Document Object Models, one of which is the XFA DOM. xfa.resolveNode is scripting against this model. This is heavy stuff and I am struggling to describe it properly.
  5. Have a look here at resolveNode: http://assure.ly/kUP02y.

The concepts here are fairly involved and you will need to read around the topics.

I really hope this helps,

Niall