How do I make a checkbox autopopulate address fields in Muse?

Hi!
I am making a website with a form where the customer need to fill in both contact information and billing information. Because it's often the same information I want to have a checkbox so the customer can click on it and it will automatically fill in the contact information so they don't have to retype identical information.
Like this:

You will have to write custom JavaScript to perform the task and you will need to know the exact form field names.
For the check box you will need to code a mouse up action to run JavaScript and you will need to add the JavaScript. The code will need to check the value of the check box and then either populate the fields or clear the fields. Without more details it is hard to tell you how to program your specific form. If designing the form I would have used hierarchical field names for the invoice and shipping fields. So one would have "invoice.company", 'invoice.contact", "invoice.address", "invoice.city", "invoice.province", "invoice.postal", "invoice.phone", "invoice.fax", and "invoice.email". The Shipping fields would have a top level name of "shipping" and the same children field names.
A possible script could then be:
var oInvoice = this.getField("invoice"); // get top level field;
var aInvoice = oInvoice.getArray(); // make array of child fields;
var oShipping = this.getField("shipping");
var aShipping = oShipping.getArray();
console.println(this.getField(event.target.name).value);
if(this.getField(event.target.name).value == "Yes") {
for(i in aInvoice) {
// copy children from invoice to shipping fields;
aShipping[i].value = aInvoice[i].valueAsString;
oShipping.readonly = true; // make shipping readonly;
} else {
oShipping.readonly = false; // clear readonly
this.resetForm([oShipping.name]) // reset array of shipping fields;

Similar Messages

  • How do you make tabbing skip a disabled field?

    Hi, how do you make tabbing skip a disabled field?
    I have a checkbox. If it's checked, one radio button in a radio button group is disabled. However, user can still tab into this disabled radio button. Once it's in there, it cannot tab out or use up & down arrow to move out of the disabled radio button. It just gets stuck there.
    I tried setting access="protected". But it makes no difference.
    Is there a way to exclude a disabled field from receiving a tab in LiveCycle Designer?
    Thanks.

    You may create your JTextField with the text i.e.
    JTextField myTextField = new JTextField("text");
    or anywhere in your program
    myTextField.setText("text");

  • How can I make JSF checkboxes selected by default?

    Hi everyone,
    I have a problem in setting default value for checkboxes. I use them in a table. tableRowGroup's sourceData property is a list data provider. In the page bean I have the following code to select rows:
    private TableSelectPhaseListener tablePhaseListener = new TableSelectPhaseListener();
        public void setSelected(Object object) {
            RowKey rowKey = (RowKey)getValue("#{currentRow.tableRow}");
            if (rowKey != null) {
                tablePhaseListener.setSelected(rowKey, object);
        public Object getSelected(){
            RowKey rowKey = (RowKey)getValue("#{currentRow.tableRow}");
            return tablePhaseListener.getSelected(rowKey);
        public Object getSelectedValue() {
            RowKey rowKey = (RowKey)getValue("#{currentRow.tableRow}");
            return (rowKey != null) ? rowKey.getRowId() : null;
        public boolean getSelectedState() {
            RowKey rowKey = (RowKey)getValue("#{currentRow.tableRow}");
            return tablePhaseListener.isSelected(rowKey);
        }I received a list of objects from a service using list data provider and use checkboxes to select them. Then I get the selected checkboxes in the action method of the page bean using
    RowKey[] selectedRows = getTableRowGroup1().getSelectedRowKeys(); What I want to do is to set all the checkboxes as selected by default. Normally, this is performed by assigning the same values to selected and selectedValue properties of the checkbox component. But, in my case this is not applicable since we take advantage of getSelected() and getSelectedValue() methods in the pagebean. Properties of my checkbox component are as follows:
    <ui:checkbox binding="#{MyPage.checkBox1}"
                                                        id="checkBox1" selected="#{MyPage.selected}" selectedValue="#{MyPage.selectedValue}"/>I cannot assign same values to selected and selectedValue. Can anyone help me to make these checkboxes selected as it is rendered?

    Hi Fanado,
    In Finder, click once on an Excel document then Get Info (command i)
    Choose Open with: Numbers
    Then Change All... to make Numbers the app for all Excel documents.
    The same for Word and Powerpoint
    Regards,
    Ian.

  • How to visit a pasted url in address field?

    This may seem a naïve question:
    Some background: I have never used Safari before. I have just installed *Safari 5.01* for Windows on my *Windows 7 PC*, and when I *+copy and paste+* an url for a particular existing web page into Safari's address field (which url loads successfully in Firefox, Opera, and IE ), I find I have no *go to* or load arrow, or other means, such as pressing enter or return, to make the browser load the pasted address. When I press Ctrl+L nothing happens, whether from the drop down menu at File: *Open Location...* or as a double keyboard command.
    And so I resorted to importing a bookmark for the address from IE, and then Safari loaded it successfully.
    Can I not just copy and paste addresses into Safari's address field and have a *+simple next step+* to load the page as I can with IE, Firefox, and Opera ?
    I tried typing part of the address in manually for Safari's autocomplete to find it, but it wouldn't find the address, which is very new, but does exist, and as I have said, loads in the other three browsers with a simple paste and enter. This *+copy and paste+* method happens to be a very convenient means of loading some sites, with only one option being available, that is the exact address, rather than possibly several options that are offered up as one types part of the address, which have to be looked at and chosen from.
    Any assistance will be appreciated.
    Thanks … allaniam

    *I confirm a similar bug exists on Safari 5.0.2 for Windows, running on a 32bit Windows XP SP3.*
    Description
    1. You copy an URL, not matter how you copy it (copy the URL text, or from another browser address bar, or from a webpage using the contextual menu "Copy Link", and etc)
    2. When you try to paste in the Safari address:
    ===(i) if you use keyboard shortcut Control-V to paste in the URL, and press ENTER - everything is normal, meaning you will leave your previous webpage and go to the new page with that URL you pasted in using Control-V
    ===(ii) if you right click on the Safari address bar, invoke the contextual menu that popups from there, and choose "Paste" from the menu,and then hit ENTER after you paste in the new URL:
    *======(A) the new URL you pasted in will disappear.*
    *======(B) the old URL before your paste, will re-appear in the address bar.*
    *======(C) the cumulative effect this operation will be the same that you reload the previous page.*
    This is the symptoms on 32bit Windows.
    *It seems in the current build of Safari for Win, "Paste" command from a menu denotes something different from its shortcut "CTRL-V".*
    This is a very weird thing.
    Just for the record, Safari 5.0.2 on Mac OSX 10.6.4 doesn't share the bug.
    *By the way, I have also surveyed the exactly version and build numbers for both the Safari versions:*
    Safari 5.0.2, build 7533.18.5: on WinXP 32bit
    Safari 5.0.2, build 6533.18.5: on Snow Leopard.

  • How do I make content in a text field continue onto a new page?

    I am creating a form and one of the pages contains a text field for an essay. I'd like the responses in this text field to carry onto new pages if they reach the end of the first page. How do I make new pages appear with only the continued text field? Thanks!

    All right...
    public class guiClient extends JFrame implements ActionListener {
    static String userString;
    static String currentFont;
    String fontchoice;
    String fontlist;
    static JTextField userName = new JTextField();
    public guiClient() {
         super("My Client");
    public guiClient() {
         super("My Client");
    // Create a ComboBox
    GraphicsEnvironment gEnv = GraphicsEnvironment.getLocalGraphicsEnvironment();
    String envfonts[] = gEnv.getAvailableFontFamilyNames();
    Vector vector = new Vector();
    for ( int i = 1; i < envfonts.length; i++ ) {
    vector.addElement(envfonts);
    JComboBox fontlist = new JComboBox (envfonts);
         fontlist.setSelectedIndex(0);
         fontlist.setEditable(true);
         fontlist.addActionListener(this);
         fontchoice = envfonts[0];     
    //Create a regular text field.
         JTextField textField = new JTextField(10);
         textField.setActionCommand(textFieldString);
         textField.addActionListener(this);
    public void actionPerformed(ActionEvent e) {
    //if the action is from the textfield (e.g. user hits enter)
         if (e.getActionCommand().equals(textFieldString)) {
              JTextField fromUser = (JTextField)e.getSource();
         if (fromUser != null){
    //place user text in editor pane
    //send message to server
                   if (userName.getText() != null) {
                        userString = userName.getText().trim();
                   out.println(userString + ": " + fromUser.getText());
              fromUser.setText("");
         else if (e.getActionCommand().equals(fontlist)){
         JComboBox cb = (JComboBox)e.getSource();
    String newSelection = (String)cb.getSelectedItem();
    currentFont = newSelection;
         userString = currentFont;
    return;

  • How to add extra lines in the address field?

    How, if possible, to add extra lines in the address field? For example, the street address might require two lines:
    Bob Smith
    Newport A  Unit 32
    Century Village
    Aventura, FL 

    Thanks, Barney! It's even easier than the solution I came to: copying and pasting into the field. 

  • How do I hide names from the Address fields?

    here's the problem.
    a group of peers is exchanging emails using the Reply All function. the catch? we need to keep our names out of the Address Fields. if I enter my friend's name into Address Book, Mail insists on showing the full name in the Address Field.
    is there any way to insert only the email address without the name of the recipient in the Address Fields? even when selected from the Address Book, or entered via a Group selection?
    BCC is not an option. De-selecting "When sending to a group, show all member addresses" is also not an option, because I would assume that recipients will not be able to Reply All.
    I tried entering an alias into the Email field in Address book: Alias <[email protected]>.
    any ideas?
    cheers,
    Gregory

    you can uncheck the option to auto complete addresses in Mail preferences->composing. then you can enter the addresses by hand without full names. the addresses will still show of course. or you can create double vcards for people in question in address book that have just email addresses but no names. then Mail will let you choose those.

  • How do I make my desktop MAC address book override the older addresses in my iPhone?

    I have the iPhone 3g and a MAC desktop with snow leopard OS.  I have updated iTunes.  When I try to synchronize my address book between iPhone and MAC desktop, the new contact information from the desktop is not put into the iPhone.  Is there an online tutorial that will show me how to do this?  Another problem, when I try to edit contact information, the Edit menu won't let me delete whole contacts.  Consequently, I have multiple phone numbers for a contact, some of which are old, some new...and I can't remember which, because I thought I had erased the old info.  I want to be able to set the desktop to override the iPhone data, and vice versa, when I want to.  By habit, I don't enter new data directly into my iPhone contact list; I do it from the desk top. 
         I would like to find online tutorial videos that show me how to use the various features of my iPhone.  The online text tutorials aren't as helpful for me, when something goes wrong.

    To make your computer overwrite your iPhone contacts, connect the phone to iTunes, select the Info pane and scroll to the Advanced section at the bottom and put a check by Contacts.  Then sync.

  • New user. Need to know where my email contacts are on my macbook pro and how I can make a group email address

    New user. Email contacts imported to MacBook pro from PC - but I'm unable to call up entire contact list or to make a group emailing contact.

    Assuming you are using Apple's Mail application, contacts are managed via the Contacts application, in your application folder.  As for various addressing methods, including groups, maybe this:
    Mail (Mountain Lion): Address messages - Support - Apple

  • How do I make Smart Groups in Address Book in iCloud?

    I have Smart Groups in my Address Book on my iMac but they don't appear in iCloud. Can anyone tell me how to do this?
    Many thanks in anticipation.

    Welcome to the Apple Community.
    iCloud.com doesn't appear to support smart groups in contacts (for that matter it doesn't support smart mailboxes in mail either

  • How can I make groups on my address book?

    I have an iphone 5c.  I am trying to make a group in my address book.  I need to be able to send a message to a group but have the members of the group respond to me only.  At this point, every message I send to them is getting read by them but then they send a response to the entire group.  It's annoying when not all the members need to hear what is being said. 

    FYI - this is the Using iPhone > Mail discussions group.
    At the Address Book menu bar, go to File > Export and select Address Book Archive.
    Transfer the exported Address Book Archive file to your new Mac.
    At the Address Book menu bar on your new Mac, go to File > Import and select the Address Book Archive file that was exported from your other Mac.

  • How do I make my @me (iCloud) address showup in iOS mail app?

    I have an existing AppleID which I used to set up my iCloud account. During that process, it gave me my new @me.com email address. I then set up iCloud on both my iPhone 4 and iPad (after upgrading both to iOS5). However, the @me.com email address does not show up in my accounts in the mail app. Of course, in settings, the iCloud account is there among all my other email accounts, but just not in the actual mail app itself. In other words, how can I actually use and send from this new @me.com address on my iOS5 devices?
    Bill

    Hi Bill...
    Read here >  Creating an iCloud account: Frequently Asked Questions

  • How to modify the "To:" auto fill address field

    I want to change and/or delete address's that auto fill in the "To:" field of mail.
    Is this possable?

    The Mail.app stores all message recipients in a list of Previous Recipients and the address autofill feature pulls from the Address Book and the list of Previous Recipients.
    At the Mail.app menu bar, go to Window and select Previous Recipients.
    A previous recipient already entered in the Address Book will have a vCard icon to the left of the name or email address. You can remove a previous recipient from the list or add a previous recipient to the Address Book that is not already entered.

  • How can i make the dynamic image link field access camera

    This is for Windows 8 only and needs to use the built in camera of the tablet they will be using. I am not a developerso this seems incredibly difficult to me.

    Hi,
    check out Nialls' Webcam Security Pass sample.
    http://assuredynamics.com/index.php/2011/10/whats-new-in-adep-designer/

  • How can I make an IOS and ANDROID app using MUSE?

    Hi there,
    I don't know anything about coding but I believe you can create something in Muse and use phone gap to turn it into a iOS or Android app - the information on this is extremely scarce - i have just seen little notes like of course you can and so forth - thats hardly helpful - has anyone managed to create something and got their app published on the Apple/Google plaster?  If someone has used something better than phone gap  as a router from muse to the eventual app i would be curious in that too.
    Cheers

    Yes, you can create an app with Muse. Keep in mind it would only be an informational app and contain no phone features such as camera, GEO Location, Data, etc.
    So once agin you would be restricted to an information only type app. Another problem with using Muse to do an app is that Muse uses fixed width design and therefore will not scale depending on device. So if you want to be on phones and tablets you would need to create two versions.
    Using Phonegap Bulid you would you would extract your Muse site (phone version usually unless you change the size of your desktop version) as HTML files and then zip them up. Using Phonegap Build you would be able to create the required files for submission to the app stores (Apple App Store, Google Play, Amazon, Windows App Store). You will need to be on a Mac to be able to submit to the Apple App Store. It will work using Muse but a better solution is to use a build service such as one that I have used in the past called AppsZero - Build Apps With Zero Coding.
    Google and Apple also require paid developer licenses. Apple is $99/year US and Google when I got mine was $25 one-time fee. Not sure if the Google one has changed but the Apple one is still $99/year.

Maybe you are looking for