Data source design issue - InfoPath Dev
in

InfoPath Dev

Data source design issue

Last post 02-05-2010 03:39 AM by Jimmy. 7 replies.
Page 1 of 1 (8 items)
Sort Posts: Previous Next
  • 02-02-2010 04:50 AM

    Data source design issue

    I am building a form where a user will reply to a list of questions. The list of questions comes from a secondary data source via a web service.  The input box for the answers should appear under each question and there is a variable number of questions.  But presumably the answers need to be on the main data source else they will not be saved when submitted.

    If this is the case, then do I somehow need to copy the answers from the secondary source to the main source when saving or submitting?  Then would I need to copy them back to the secondary source fields when re-opening the form so that they appear underneath the correct question?

    All this sounds a bit complictated. Am I doing something wrong?

  • 02-03-2010 03:20 PM In reply to

    Re: Data source design issue

    Or you need to copy the questions into the main data source as well -- because what if they change over time? Then you'd have answers that don't make sense....

    Do you write code? You can do this with code. Or you can use qRules -- it has a command that will let you copy repeating data from one data source to another (along with any number of other cool commands). There's a free trial available here.

    Hilary Stoupa

  • 02-03-2010 11:40 PM In reply to

    Re: Data source design issue

    I'm working on the copying now based on sample code I found from you.

    Thanks!

  • 02-04-2010 06:52 AM In reply to

    Re: Data source design issue

    Hi again Hilary,

    Spent hours wondering why my code based on your sample wasn't working. It's because I was using your "my:" namespace.  So I have a couple of questions about that:

    Is this namespace always set to the date and time that the template was first saved?

    Does it ever change?

    Can I find it from within IP or do I always need to save a form as xml in order to see it?

    TIA

  • 02-04-2010 07:23 AM In reply to

    Re: Data source design issue

    Graeme:
    Is this namespace always set to the date and time that the template was first saved?

    For forms created from a blank data source, it will be http://schemas.microsoft.com/office/infopath/2003/myXSD/, followed by the date and time (GMT) the template was created (not saved).

    Does it ever change?

    No.

    Can I find it from within IP or do I always need to save a form as xml in order to see it?

    Right-click any node in your main data source, select Properties, and then Details.
    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
  • 02-04-2010 07:50 AM In reply to

    Re: Data source design issue

    Thanks for that Jimmy.

    One more - in the comments to Hilary's article she says about the extra blank row:  "just don't include the blank row by default -- you'll find this under the default values"

     http://www.infopathdev.com/blogs/hilary/archive/2008/07/04/how-do-i-copy-repeating-data-from-an-external-source-into-my-form.aspx

    I can't find any such option - I'm looking at Repeating Table Properties - Edit Default Values...

     UPDATE: OK, found it under Tools - Default Values.

    Graeme

  • 02-05-2010 02:56 AM In reply to

    Re: Data source design issue

    Spoke too soon above - the Default Values menu option is on the IP tools menu, but not when developing in Visual Studio.  How can I set this value in VS designer?

    UPDATE: Spoke too soone again - I just found that too - it is the same as Form Options - Advanced - Edit Default Values

  • 02-05-2010 03:39 AM In reply to

    Re: Data source design issue

     You should also be able to find it under the Data menu in VS.

    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
Page 1 of 1 (8 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.