Query/Submit fields - InfoPath Dev
in

InfoPath Dev

Query/Submit fields

Last post 07-27-2007 02:08 AM by ollewessel. 14 replies.
Page 1 of 1 (15 items)
Sort Posts: Previous Next
  • 07-16-2007 08:03 AM

    Query/Submit fields

    Hi,

    I apologize if posting in the wrong section, I just need to know:

    Can I populate a textbox with data from a query, and then submit the data in the textbox to another web service? 

    Yes or no is a good enough answer, however if yes thankful for tips how to.

    Greetz
    Olle
     

    InfoPath 2007.
  • 07-16-2007 11:15 AM In reply to

    Yes you can have multiple webservice data connections that submit or receive.

    It would depend on the web serivice but you can see the fields in the operations and then submit it. It is all just a matter of moving the data to other fields or using fields as parameters.

     If you have looked at the Database Acceleraot Web Services there are multiple ways to submit data.

    Qdabra Database Accelerator Suite Version 2.0 - Developer

    We would need more details to give you more detailed assistance.

    Filed under:
  • 07-17-2007 06:44 AM In reply to

    Hi, thank you for your answer.

    I have a web service with many different submit or receive operations available. They work isolated one by one, but when it comes to combining many of them in one form it becomes more difficult.

    What I wanted to do above, get query result from connection 1 in textbox A, then submit the data in textbox A to connection 2, is now solved. Thank you. I have to be careful with mapping the fields and parameters together.

    But what about this case: get query result from connection 1 in textbox A, then use the data in textbox A for another query to connection 2, is that possible? In that case I would need to insert a second query button, how? I notice the query button has no settings interface like the submit button.
     

    InfoPath 2007.
  • 07-17-2007 06:53 AM In reply to

    Query is an action that is available on about any control in the rules section. I would typically create a rule on the field where the query value is stored that runs the second query. that way each time it is changed it automatically runs the subsequent query.  But you can put a rule on a button or whatever you want.
  • 07-17-2007 08:13 AM In reply to

    What a quick answer :-)

    Unfortunately I don't get it working, I put a query rule on textbox A, trying both with "is not blank" and "is present" conditions, but textbox A does not "fire" to connection 2.

    Neither does the rules and custom code button work, although I carefully attach the textbox A to the button with rules and conditions. Confusing.
     

    InfoPath 2007.
  • 07-18-2007 05:25 AM In reply to

    I'll make myself more clear. Also I like to keep the questions in one thread instead of spread in different sub-forums.

    The rules work - but not in the way I want them to. I have a "textbox A is not blank" rule on a button, but this only checks if textbox A is empty or not. If it is blank the button does not work, if it has an entry it uses the second query connection but with an empty query, it does not send the data in textbox A as I want it too. Question hence:

    1. How do I tie the data in textbox A to the button so I can send it (in a query)?

    For the textbox A itself I also put a rule on it but I can't make it "fire" automatically. Question:

    2. How do I make the field automatically launch a query?
     

    EDIT: Can that Qdabra DBXL run on Vista? I have IIS 6.0 installed but it does not install.

    InfoPath 2007.
  • 07-20-2007 06:07 AM In reply to

    Well whatever is in your query fields when you execute the query is what is used.  It sounds like you need some preliminary action to seed your fields before the query.  I would recomend making a test form and then playing witht he query funtionality, put all of the query fields and all of the resulting data fields in the view and then experiment.

    A textbox field only fires on an update whether by the user or from another trigger / action.  Typically the user enters some peice of data and then that would be the query parameter and the query would be executed.

    You can put rule in the open rules so that itlaunches automatically when the form opens. This is slightly different than the default for data connections to run automatically. This would allow you to do some other checks and seed your query values but would run before the user saw the view.

    DBXL can run on Vista but it is difficult since Vista only supports IE 7 and webdav has been altered some.  Contact me directly and I might be able to help troubleshoot.

    Filed under:
  • 07-23-2007 04:52 AM In reply to

    Clay Fox:

    Well whatever is in your query fields when you execute the query is what is used.  It sounds like you need some preliminary action to seed your fields before the query.  I would recomend making a test form and then playing witht he query funtionality, put all of the query fields and all of the resulting data fields in the view and then experiment.

    I get your point. But what it all comes down to is if this textbox A (datafield of data source 1) can become a query field of data source 2. At the same time, so to say. I am gonna play around with VSTA and event programming, maybe there is some useful stuff in there?

    Clay Fox:
    DBXL can run on Vista but it is difficult since Vista only supports IE 7 and webdav has been altered some.  Contact me directly and I might be able to help troubleshoot.

    This is not my main issue but I will look at it at times. When I downloaded I got a mail from colleagues of yours(?) with some help for Vista users.
     

    InfoPath 2007.
  • 07-23-2007 05:51 AM In reply to

    The datafield of source1 (textbox A) could be the query field of your second data connection, depending on how it is configured, but I know it can have a rule that passes its value (set field value) to another query field or in the data connection itself pass it's value to the web service.

  • 07-23-2007 08:02 AM In reply to

    Again, thank you for all the answers.

    I have solved it like this:

    Created a rule button, that populates the query field of source2 with the value of  textbox A (source 1). The rule looks like: Set a field's value: query field 2 = textbox A. Then execute the query.

    But putting a rule on the textbox still does not work. The rule on textbox A is (condition: is present) Set a field's value: query field 2 = .
    The full stop means "this field", I guess, but the query field does not get populated. 

    I am happy enough with the rule button but just out of curiosity and saving mouseclicks; I would be even happier to get the textbox to pass data automatically?
     

    InfoPath 2007.
  • 07-25-2007 07:36 AM In reply to

    Clay Fox:

    The datafield of source1 (textbox A) could be the query field of your second data connection, depending on how it is configured,

    How? 

    Clay Fox:

    but I know it can have a rule that passes its value (set field value) to another query field or in the data connection itself pass it's value to the web service.

    How in the data connection itself?
     

    InfoPath 2007.
  • 07-25-2007 10:20 PM In reply to

    Hi Ollewessel,

    You can use a rule on the textbox to set the query field to source1. Leave the condition blank and it will always update the query field in your secondary data source when someone types in a value. You can add an action to set the field's value and you can add another action to query the data source. Clay's on vacation until next Monday (7/30/07).

    Cheers!

    Patrick Halstead
    Project Manager at Qdabra
  • 07-26-2007 01:01 AM In reply to

    Hi,

    Nobody is typing in this textbox, my idea was to immediately send the results from query 1 (printed in this textbox) to query 2. But for now I solve it with buttons. 

    InfoPath 2007.
  • 07-27-2007 01:08 AM In reply to

    OnAfterChange or add a rule after the query for 1.
    Patrick Halstead
    Project Manager at Qdabra
  • 07-27-2007 02:08 AM In reply to

    Is OnAfterChange equal to Changed Event? In the programming menu I only have three events to choose from, Changing Event, Validating Event, and Changed Event.
    InfoPath 2007.
Page 1 of 1 (15 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.