submit button unable to write into database table - InfoPath Dev
in

InfoPath Dev

submit button unable to write into database table

Last post 06-25-2010 01:48 AM by larryp7639. 15 replies.
Page 2 of 2 (16 items) < Previous 1 2
Sort Posts: Previous Next
  • 06-25-2010 01:48 AM In reply to

    Re: submit button unable to write into database table

    Hilary Stoupa:

    Hello:

    No, I don't think anything you are doing will require code. First, let's add that field.

    1. Change your task pane to display the Data Source task pane
    2. Select the main data source
    3. Right click the root folder (probably myFields)
    4. Select Add
    5. Name the field isSubmitted (or another name, if you like)
    6. Change the Data type  to True/false (boolean)
    7. Select OK

    Now you have another field that you can use to know whether the form has been submitted. Next, let's set some rules.

    1. Right click the button you are using for submitting
    2. Change the Action to Submit
    3. Select the Submit Options button
    4. Select Perform custom action using Rules
    5. Select the Rules button
    6. Select the Add button
    7. Give your Rule a meaningful name, like "Submit to database"
    8. Select Add Action ...
    9. Change the action to Submit using a data connection
    10. Make sure the data connection is your main data connection
    11. Select OK
    12. Select OK  again

    This will set up the submission to the database. Next, we'll set a rule to set the value of isSubmitted.

    1. Select the Add button again to add another rule
    2. Give your rule a meaningful name, like "Set isSubmitted"
    3. Select Add Action ...
    4. Change the action to Set a field's value
    5. Select your isSubmitted field in the field area
    6. Type the word true in the value area
    7. Select OK
    8. Select OK again

    Finally, we add the rule for email submission. All of these actions could have been added to a single rule, but sometimes when you are new, it is easier to only have a single action in every rule. That way if something doesn't work the way you anticipate, you can deselect different rules to track down the problem. So, to submit our form to email:

    1. Select the Add button again to add another rule
    2. Give your rule a meaningful name, like "Send email"
    3. Select Add Action ...
    4. Change the action to Submit using a data connection
    5. Make sure the data connection is your email submit connection
    6. Select OK
    7. Select OK  again, and once more to close that window

    For the grand finale, we'll set that conditional formatting on the button.

    1. In the Button Properties, select the Display tab
    2. Select the Conditional Formatting  button
    3. Select the Add button
    4. In the first dropdown, select your isSubmitted field
    5. The second dropdown should say "Is equal to"
    6. In the third dropdown, select Type text
    7. Type in true
    8. Select the Hide this control checkbox

     

     

    Thanks you for the post. 

    __________________
    Watch Grown Ups Online Free


     

Page 2 of 2 (16 items) < Previous 1 2
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.