Get lists in cascade with a different combination in custom dialog boxes

Adobe LiveCycle Designer Cookbooks by BR001: using app.execDialog () in a form in Adobe Designer

1.PNG

I am the above post and try to do this:

1.

When I select "Åland", he must show the cities of this island in a new list box that is added to the first. When I select a city ranked, it shows the district as a result to a third list box, like this:

Capture.jpg

(The dialog box above is created with excel visual basic.)

The combination of the above selection is random. When you select point 110-> article 1103, it may or may not show 11031, according to data provided by the document of the requirement.

I studied the code in the sample PDF file. Now, I can only reach this step: select the item 110-> article 1103, it shows 11031.

But I see no better way to add additional selection (for example workflow It can also browse the 120-> 1204-> 12043).

My code

function customDialogBox() {}

var dialogDescriptor = {}

"DS1": function (dialog) {/ / the first list}

DS1 var = dialog.store (['DS1']);

for (var DS1 item) {}

If (DS1 [point] > 0) {}

var selectedValue1 = item;

break;

}

}

If (dialogObject.selectedItem (DS1) == '110') {//when "110" in the first list is enabled, it allows the display of list2

Dialog.visible ({}

LST2: true

});

} else {}

Dialog.visible ({}

LST2: false

});

Dialog.Load ({}

"txt1": selectedValue1

});

}

},

'LST2': function (dialog) {/ / the second list}

When "1103" in the second list is selected, it envisibles list3

},

'LST3': function (dialog) {/ / the third list}

concatenate and return the string selected in List1, List2, List3

}

};

var dialogObject = {}

DS1: data.list1, map / / a, storing the data in the first level

LST2: data.list110,//a card, storing the data in the second level, when the parent code is 110

LST3: data.list1103 //a card, storing the data in the third level, when the parent code is 1103

}

}

Basically it is to hardcode the selection flow. I want to dynamically generate lists.

I think store all lists and identify them by ID, perhaps, in this way:

Header 1

var dialogObject = {}

DS1: data.list1,

LST110: data.list110,

LST1103: data.list1103,

LST120: data.list120,

......

}

But how can I correctly identify, in order to show/hide the lists and finally out of the string that is concatenated in function customDialogBox()?

Or maybe is there a better way to retrieve the list when execution, please enlighten me!

2. Moreover, it is possible to do research (find the code and highlight the result element) as shown in the picture above? Can you give me a few keywords that I need google with?

A big thank you!

It is possible to dynamically create objects and dialogue, as well as of the data within the json object...

What I mean by item ID is the ID of the element in your dialog box, such as DS1, LST2, LST3... but it cannot be LST10, is too long, the dialog box will not interpret the ID because of its length

What I want to say to the good conditions in the initialize event, is when the event initialize when the user selects an item in the first list, you call, you will have to do if statements with variables in behind to guide the behavior of the dialog box to display the lists and data you want exactly want to display.

Tags: Adobe LiveCycle

Similar Questions

  • Problem with custom dialog box

    I have a custom dialog box. The code goes here

    import net.rim.device.api.system.Bitmap;
    import net.rim.device.api.ui.Color;
    import net.rim.device.api.ui.component.Dialog;
    import net.rim.device.api.ui.container.VerticalFieldManager;
    import net.rim.device.api.ui.decor.BackgroundFactory;
    
    public class CustomDialog extends Dialog{
    
        public CustomDialog(int command,String msg,int color,int alpha){
             super(command, msg, command,Bitmap.getPredefinedBitmap(Bitmap.EXCLAMATION), VerticalFieldManager.FOCUSABLE);
             setBackground (BackgroundFactory.createSolidTransparentBackground (color, alpha));
        }
    
    }
    

    I'm the caller to another class as follows

    CustomDialog d = new CustomDialog(Utils.D_YES_NO,"Do you want to exit",Color.BLUE,140);
    d.show();
    

    Its display very well and as I intended it to be. But the problem is that I'm not able to get the index of the choice to perform certain actions, such as

        int i=d.getSelectedValue();
    
                        if(i==Dialog.D_YES){
                            Dialog.alert("hi");
                        }
    
                        }
    

    Its do not call the dialog box, can anyone suggest me how to get the index of the choice that I chose to say YES or NO and to perform tasks accordingly

    Plese try suite

    CustomDialog d = new CustomDialog(Dialog.D_YES_NO,"Do you want to exit",Color.BLUE,140);
                    d.show();
                    d.setDialogClosedListener(new DialogClosedListener() {
    
                        public void dialogClosed(Dialog dialog, int choice) {
                            /*
                             *   // Field descriptor #211 I
                                  public static final int YES = 4;
    
                                  // Field descriptor #211 I
                                  public static final int NO = -1;
                             */
                            int i=choice;
                            System.out.print("Selected Value :"+choice);
                            if(Dialog.YES==choice){
                                System.out.println("Selected Value : YES");
                            }else if(Dialog.NO==choice){
                                System.out.println("Selected Value: NO");
                            }
    
                        }
                    });
    

    If it is useful, please make as response and do not hesitate on LIKE button thanks

  • I get my serial number and click on 'Download', then the dialog box says 'unavailable screen '.  What the devil?

    I get my serial number and click on 'Download', then the dialog box says 'unavailable screen '. What the devil?

    Please access the following link to download the installer of Photoshop elements 14. If you're still having problems, try to please the link to Chrome or Firefox and check if it downloads.

    Download Photoshop Elements | 10, 12, 14, 11, 13

    Thank you.

  • Name to appear first in the custom dialog box pop-up list

    Hi Forum.

    Thanks for the support so far.  I'm creating a simple custom dialog box which will be "popup", few names in the drop-down list.

    I read an external txt file bearing the name corresponding to the drop-down list. I try to display the name "Stephen" in the txt file as the first and then others follow one by one. Please help on this.

    name listed in the pop-up window

    Dialog.Load ({}

    names of:

    {

    'The King':-1.

    'Queen':-2,.

    'Jack':-3,.

    "Stephen":-4,.

    "Robert":-5,.

    }

    })

    He tried as below but found that the myList3 variable is directly instead of its value ("Stephen").

    Dialog.Load ({}

    names of:

    {

    myList3 : + 1, / / the variable myList3 will be known as "Stephen" stored inside.

    'The King':-1.

    'Queen':-2,.

    'Jack':-3,.

    "Stephen":-4,.

    "Robert":-5,.

    }

    })

    Appreciated your timely help on that. Thank you.

    See examples 3 and 4 in the execDialog API reference.

  • How can I replace the mime types of server, always get the mp3, rar, sid, bin files directly in the dialog box "where do you want to save this file?"

    I used to be able to click on MP3 files, the way back when, and Firefox asks where I wanted to save. Nowadays, it opens a new tab with a flash drive.
    By clicking on the "unknown" files, like .sid, .prg, .zip, .rar is ' this is a BIN file. [Cancel] [Save] ». It does not give me a check box for "always do this".
    I would like that option to edit so that certain types of files, such as PDF, regardless of mimetype, always get opened in a new tab if you click. Also some types of files, based on the extension, always go directly to the dialog box "Where you want to save the file?", without worrying if there is a viewer or a builtin player or not. In my Firefox (41.0.1 14.04LTS 32-bit Ubuntu) I have never the choice "do this for these files always" more.
    Googling led me to delete my file mimeTypes.rdf and since file extensions can even "well known", such as .zip, are treated as BIN files and I get the box Cancel-or-Save for those too - again without the choice of "always save the BIN files.

    These files are send as Content-Type: application/octet-stream and Content-Disposition: attachment;
    To send files in this way, you cannot save an automatic action.
    You can see that in network monitor.

    Content-Disposition: attachment; filename="TURRICAN_AMIGA_PORT.sid";
    Content-Type: application/octet-stream
    
  • Need help with custom dialog box

    I created a custom help dialog box. The problem is that 5 buttons do not properly fit in my manager of horizontal field on some blackberry devices. How can I make own? I tried to use my own custom buttons that allow me to specify their width and height, but I'm unable to get the width of the dialog box, so I can't determine how wide should be buttons.

    import net.rim.device.api.ui.component.ButtonField;
    import net.rim.device.api.ui.component.Dialog;
    import net.rim.device.api.ui.container.HorizontalFieldManager;
    
    public class HelpDialog extends Dialog
    {
        static int ButtonPressed;
        HorizontalFieldManager hfmChoices = new HorizontalFieldManager();
        ButtonField cmdFirst = new ButtonField("|<")
        {
            protected boolean navigationClick(int status, int time)
            {
                ButtonPressed = 0;
                close();
                return true;
            }
        };
        ButtonField cmdPrev = new ButtonField("<")
        {
            protected boolean navigationClick(int status, int time)
            {
                ButtonPressed = 1;
                close();
                return true;
            }
        };
        ButtonField cmdNext = new ButtonField(">")
        {
            protected boolean navigationClick(int status, int time)
            {
                ButtonPressed = 2;
                close();
                return true;
            }
        };
        ButtonField cmdLast = new ButtonField(">|")
        {
            protected boolean navigationClick(int status, int time)
            {
                ButtonPressed = 3;
                close();
                return true;
            }
        };
        ButtonField cmdClose = new ButtonField("Close")
        {
            protected boolean navigationClick(int status, int time)
            {
                close();
                return true;
            }
        };
    
        public HelpDialog(String message, int page, int maxPages)
        {
            super("Help (Page: " + page + " of " + maxPages + ")\n\n" + message + "\n", null, null, -1, null, 0);
            ButtonPressed = -1;
            if (page <= 1)
            {
                cmdFirst.setEnabled(false);
                cmdPrev.setEnabled(false);
            }
            if (page >= maxPages)
            {
                cmdNext.setEnabled(false);
                cmdLast.setEnabled(false);
            }
            hfmChoices.add(cmdFirst);
            hfmChoices.add(cmdPrev);
            hfmChoices.add(cmdNext);
            hfmChoices.add(cmdLast);
            hfmChoices.add(cmdClose);
            add(hfmChoices);
        }
    }
    

    Thank you

    Most people have no need a close button, they expect the ESC to do it for them.

    That said, I disagree with this statement:

    "I think that the only good way to use managers other than the AbsoluteFieldManager, is to use them at all."

    Designing a user experience that works well on multiple devices is difficult, and I don't think that has a size fits all approach work.  In addition, I don't have the time to create formats for specific screens for each device type, and although this will not happen now, I didn't have to rework screen designs every time that a new device came out.  I think that it is possible to create a common user interface experience given the size of the screen, and whether it is touch.  If you want to read my thoughts on this, have a look at the tutorial of the user interface you will find here:

    http://supportforums.BlackBerry.com/T5/Java-development/tutorials-for-new-developers-part-1/m-p/1621...

  • When you use my dynamic stamp I get the "undefined" Word where the text entered in the dialog box must be

    I get my dialog box open no problem I enter click data OK but the stamp shows that the text field is "undefined". "Text fields names are 'Due' and 'WorkOrder' in the photo below they appear"DueValue"and WOrkOrderValue", then the results as 'undefined' for both. I put the code at the bottom that I delete the section that caused the word "value" is displayed at the end of the deadline and order of business.

    < AcroForm >

    < ACRO_source > CaseNumField: calculate < / ACRO_source >

    < ACRO_script >

    / * belongs to: AcroForm:CaseNumField: calculate * /.

    var = {} dialog box

    DueValue:

    WorkOrderValue:

    function: Commit (dialog) {/ / called pressed OK}

    results var = dialog.store ();

    This. DueValue = results ["tx1"];

    This. WorkOrderValue = results ["tx2"];

    },

    Description:

    {

    name: 'Information stamp control', / / title of the dialog box

    elements:

    [

    {

    type: "display."

    elements:

    [

    {

    name: "reason: «,»»

    type: 'static_text. "

    },

    {

    item_id: "tx1"

    type: 'edit_text. "

    Multiline: true,

    Width: 200,

    height: 40

    },

    {

    name: "work order #: «,»»

    type: 'static_text. "

    },

    {

    item_id: "tx2"

    type: 'edit_text. "

    Multiline: true,

    Width: 200,

    height: 40

    },

    {

    type: "ok_cancel."

    ok_name: "Ok."

    cancel_name: "Cancel".

    },

    ]

    },

    ]

    }

    };

    If (event.source.forReal & & (event.source.stampName == "#VOfL_5866j3cq0GIzQbaLC"))

    {

    If ('ok' is app.execDialog (dialog))

    {

    CMSG = var dialogue. DueValue;

    Event.Value = "Due\n" + CMSG;

    event.source.source.info.DueValue = CMSG;

    CSMG is "Work Order\n" + dialog box. WorkOrderValue;

    this.getField("WorkOrder").value = CMSG;

    }

    }

    Title of the dialog box get ready unless the code is executed in a context of trust. It's a bit complicated to put up with a custom in a stamp file dialogue box, so I won't even try to explain it.

  • How to load the PDF (HTML Loader) with the reference of the file (dialog box) [AIR]?

    Hello.  I try to get my AIR application to load a PDF document from the dialog box using the file reference class.

    With the code that I have if I use an ordinary charger so I can get a PNG image to be loaded into a container and display on the screen.  But PDF requires HTML Loader that seems not to accept event.target.data because he expects a string.

    This is the error I got

    TypeError: Error #1034: Type coercion failed: cannot convert ["'FileReference object] in flash.net.URLRequest.

    at test_pdf_load_from_dialogfla_fla::MainTimeline/loadFile() [test_pdf_load_from_dialogfla_fl a.MainTimeline::frame1:61]

    Test_pdf_load_from_dialogfla.swf [UnloadSWF]

    Here is my code:

    import flash.net.URLRequest;

    import flash.display.MovieClip;

    import flash.html.HTMLLoader;

    import flash.net.FileReference;

    import flash.net.FileFilter;

    var file:FileReference=new FileReference();

    var container: MovieClip = new MovieClip();

    addChild (container);

    var i: Number = 1;

    the button is an object on the stage, will not be called via actionscript

    button.addEventListener (MouseEvent.CLICK, showDialog);

    var myFile:FileReference;

    var myFileLoader:HTMLLoader;

    function showDialog(e:MouseEvent):void {}

    myFile = new FileReference();

    var PDFFileType:FileFilter = new FileFilter ("PDF Documents (*.pdf) ',"*.pdf"");

    myFile.browse ([PDFFileType]);

    myFile.addEventListener (Event.SELECT, selectFile);

    }

    function selectFile(e:Event):void {}

    myFile.addEventListener (Event.COMPLETE, loadFile);

    myFile.load ();

    }

    myFileLoader = new HTMLLoader();

    function loadFile(e:Event):void {}

    myFileLoader.load ((e.target) m:System.NET.SocketAddress.ToString ());

    }

    (with the new selection of forum I also can't seem to put this topic in the location of the ActionScript of Flash Pro forum.)

    Success!

    I was thinking about this subject for several hours, when I thought that "maybe the statement in the function loadFile e.target may contain the"name"property.

    When I used a trace statement to test this, my thoughts have revealed that, to be precise.  The appeal of e.target.name fills indeed console output with the correct file name.

    To be sure that I did the following:

    myFileLoader.load (new URLRequest (String (e.target.name)));

    myFileLoader.width width = [[set to something other that the default value of 0 to show the PDF of the HTMLLoader content]]

    myFileLoader.height = [[ditto of the previous line, the default value is 0, which would make the invisible PDF content]].

    I'm so happy to have had this inspiration and also to the fact that the ActionScript documentation I found has good examples to follow.

  • How to continue rendering of the transition with the custom dialog box open

    Hello

    I'm working on a plugin for some transitions custom (currently for CS6/CC on Windows).

    I use a custom dialog (hasCustomDialog in PiPL) during the esSetup box to define the transition parameters. While the dialog box is open, first execution is suspended until the dialog box is closed.

    The problem is, if I'm fiddling with the settings I do not see the changes in the program monitor and I don't get any comment first.

    I tried to make the dialog non-blocking, but then first did not executives when I changed something in the dialog box.

    Anyone know if it is possible to maintain the dialogue and still have first actively updating the display?

    Kind regards

    Philipp Stelzer

    But I want to keep the dialog box open to see the changes directly without opening the dialog box whenever I want to change a value. Is this possible with a custom dialog?

    It is not the case.  But using the AE API with extensions of the transition, you should be able to achieve the same thing, with the effect controls panel, containing all your effects settings.

  • Problem with keyboard shortcuts in the filter dialog boxes - CS5 64-bit Windows 7

    While in the filter > sharpening > Unsharp Mask dialog box, I hit the < SPACEBAR > to get the hand in vain tool the screen cursor change cursor default 'box' so I tried again and still no change until I moved the mouse. then only the hand familiar tool icon appeared.  Good, so I then used hand tools, using the mouse to reposition my opinion and released the left mouse button, but the tool hand cursor remained on the screen until I moved the mouse again.  I have experienced the same problem (always in the filter > sharpening > dialogue emphasis) with the shortcuts of the Zoom tool using the ctl <>and < alt > key.  Not really a problem of killer but confused, not less.  Holder to try to solve the problem, I have known the exact symptoms same for each of the filter dialog boxes > blur filter > noise, filter > sharpness, filter > aesthetic and filter > other.  I also have Photoshop CS3 installed and all shortcuts work as expected.  Anyone else seeing this odd behavior?

    What you see is a bug.   We have an internal bug on this issue.

  • Problem chart/getting updated when you press on the background thread notification dialog box

    I have a user who is graphical reports strange behviour after our request and only under the following condiitions alarms:

    1 sets of users clock back to trigger the alarm

    2 user locked the BB

    3. the user receives alarm 1 minute later

    4. the user unlocks the BB

    The strange behavior is that the background seems to resemble a back buffer bland with a rectangular hole where the notification dialog box should be.  The user clicks then the graphics and where the button should be back to normal.

    The question is not if the user does not lock the BB first - it's only under the condition of deadlock that the problem occurs.  The user statement also sometimes see a dialog "Please wait" when running our application after unlocking, but never when our application is stopped.

    Model is 8310 with 4.5 and approximately 3 MB of free space depending on the situation-> filefree.

    The dialog box is to be generated and added to the queue by a background thread using the following method:

        private void notifyUser(String msg) {
            UiEngine ui = Ui.getUiEngine();
            EncodedImage icon = Theme.getIcon(false, true);
            Bitmap bm = null;
            if (icon != null) {
                bm = icon.getBitmap();
            } else {
                bm = Bitmap.getPredefinedBitmap(Bitmap.EXCLAMATION);
            }
            synchronized (Application.getEventLock()) {
                Screen screen = new Dialog(Dialog.D_OK, msg, Dialog.OK, bm, Manager.VERTICAL_SCROLL);
                ui.pushGlobalScreen(screen, 1, UiEngine.GLOBAL_SHOW_LOWER);
            }
        }
    

    I checked the problem does not occur on the "BOLD", Pearl Flip, or 8100 with real hardware.  The problem never happens in simulators (tried about 6 models).

    Any thoughts?  Is there something wrong with the code above or spark a dialogue for a non-event like this thread?

    Thanks in advance...

    The workaround for the "locked" State is to implement MemoryCleanerListener in your main application class. This listener is notified when the device is locked. We define a property here "deviceWasLocked", then query this property of our custom popup dialog to determine if we arrive on a locked screen.

    Then we switch our application in the foreground (requestForeground) that clears up this particular issue, and any event goes well.

    The problem of 'missed calls' is a little more complicated, unfortunately, but you're not complaining that one!

    Having said all this, I'd love to see other ideas on how to solve this problem. We strugggled for several weeks with this problem when the 4.3 is released.

  • can I return a string in a custom dialog box created with app.execDialog ()?

    Adobe LiveCycle Designer Cookbooks by BR001: using app.execDialog () in a form in Adobe Designer

    I am the above post and try to do the following:

    Capture.PNG

    I want to write the output of one of the selection of list to PDF dialog box, what I'm going to script?

    Something like document. Write() in Javascript (see: http://www.tutorialspoint.com/javascript/javascript_dialog_boxes.htm ). I tried to use document. Write() in the script dialog box, but it doesn't seem to work.

    Or can the dialog box return a string value?

    According to the PDF example in the first link, this dialogObject is what is returned when you see a dialog box:

    var dialogObject = {}

    DS1: ({}),

    execDialog: function() {}

    Return app.execDialog (dialogDescriptor);

    },

    selectedItem: {function (control)}

    If (typeof (control) = "string") {}

    control = this [control];

    }

    for (var control element) {}

    If (typeof (control [item]) = 'object') {}

    var r = this.selectedItem (control [item]);

    If (r! == undefined) {}

    Return r;

    }

    } else {}

    If (control [point] > 0) {}

    Returns [dot] control;

    }

    }

    }

    },

    };

    Return dialogObject;

    Hello

    Yes it is possible, by removing the execDialog() function and call the just before execDialog the dialogObject return, you call the dialog box to be executed directly in the service, so if you start a string on the top of the function and the validation value you set the string value of the item found in the list box then you will be able to return the value of the string instead of the dialogObject...

    Here is a short example:

    dialog() {} function

    var strValue = "";

    var dialogDescriptor =

    {

    Description:

    {

    align_children: "align_row."

    items:]

    {

    type: "display."

    align_children: 'align_left,

    items:]

    {

    type: 'edit_text. "

    item_id: "txt1"

    Width: 300

    },

    ]

    },

    {

    type: "ok_cancel."

    }

    ]

    },

    validate: function (dialog)

    {

    No validation required

    Returns true;

    },

    commit: function (dialog)

    {

    elements var = dialog.store ();

    strValue = items ["txt1"];

    },

    };

    var dialogObject =

    {

    execDialog: function() {return app.execDialog (dialogDescriptor);},

    //...

    };

    app.execDialog (dialogDescriptor);

    return strValue;

    }

    Hope this will help you

  • When I try to open the file with Chinese or Japanese script, a dialog box appears in a black screen

    When I click on the PDF file, a dialog box appears with the text Chinese or Japanese on a black screen

    fornarina75,

    Try this:

    1 Quit Safari.

    2 start the player from the /Applications/ folder and accept the end user license

    3. load the PDF in Safari.

    Thank you.

  • I can't navigate and select with the mouse in some ID dialog boxes

    I recently installed ID CC 9.1X64 on a PC running Windows 7 Professional with SP1.

    The application seems to work OK in regard to most but when some dialog boxes (for example Options of cell Style) pop up I cannot select items or navigate around the area by clicking with the mouse. I have to use the tab and return keys, which is awkward and done things, such as the definition of the outline styles, almost impossible.

    Does anyone have any idea why this might be happening? I had something similar with another application.

    Malcolm

    It is the following: panels and InDesign tools answer not to the clicks of the mouse (Windows 7/Vista)?

  • GREP with the Javascript vs find/replace dialog box

    InDesign CS4

    Search/replace, GREP tab dialog box

    To find:

    (www: http\:-/-/) ([\w\-\?\=\&]+[\.\/]?) +

    This expression finds links pretty well.

    When I put in a .jsx file and fire in the actions palette, it does not work.

    The following works, but obviously does not correspond to as many hypertext links:

    http\:\/\/([\w\-\]+[\.\/]?) +

    as in

    ([app.findGrepPreferences.findWhat = ' http\:\/\/([\w\-\]+[\.\/]?) +';

    I tried to add?,-?, and? but it bombards the - no match.

    Same with initial either / or between http as the beginning of the pattern and www.

    I wonder if a grep javascript guru could give me a clue as to how to translate it?

    Thank you.

    Hey!

    Definition of GREP via JavaScript needs to use to escape. If your GREP in JS expression would look like this:

    app.findGrepPreferences.findWhat = "(www|http\\:\\/\\/)([\\w\\-\\?\\=\\&]+[\\.\/]?)+";
    

    Hope that helps.

    --

    tomaxxi

    http://indisnip.WordPress.com/

Maybe you are looking for

  • Separator of the shutters and window resize

    I took this VI from the demo of OOP and trying to understand the behavior of the two strings in the upper part of the VI (upper pane). I've colored the two separators in red to make them visible. When resizing the window, the string on the left indic

  • Error number: 0 x 80248011

    I have Windows XP, Windows Update program does not work, it shows the error number: 0 x 80248011 what I need to do?

  • Get codes error 0 x 8246007 and 0x8007F0F4 when trying to install KB02686509

    This is a repost of a persistent problem, I did everything that was suggested, and all I ask is that someone looks at the code to update security and how it is written because it lacks a few prerequsites for install it correctly.

  • Replacement XP

    Hi all I recently reached a particularly nasty on my main system spyware that my current (paid) protection software cannot get rid of. All of the software drivers etc are up to date prior to infection and I am hated for spending more money on another

  • Volume, network and power icons disappeared from the Notification area

    For no reason that I can discern, I started today and these 3 icons are missing from the notification area. I want that they come back then I right-click the notification area, went to properties and arrived at the tab Notification area. Forthose ico