Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I have a list on a SharePoint site. When I open that list in InfoPath, I see the fields to the right. When I load the edit form, store a value and run a rule based on that stored value.

I will have potentially SEVERAL of these decision points, and adding a new column to my list to store/manage each decision point will clutter the original list beyond recognition.

How can I create a field in my SharePoint-linked InfoPath form directly, but NOT have it associated with a SharePoint list? I don't care if the data is lost when the form closes. It will be regenerated each time the form loads.

enter image description here

share|improve this question
add comment

1 Answer 1

up vote 1 down vote accepted

Short answer: you can't. But I think you have a couple options.

Try using a custom Content Type rather than creating columns directly on the list. When using a CT, you can make the backing fields (i.e. the 'decision point' columns) hidden so they don't appear in forms. This could still produce more 'clutter' than what you're comfortable with, though.

You can also try creating a secondary data source based on a simple XML document. I think this is the method you're looking for. I've only done it one time, but it worked well in my not-too-complicated use case.

First create an XML file, something like this:

<?xml version="1.0" encoding="UTF-8"?>
<logic>
    <valueA></valueA>
    <valueB></valueB>
    <valueC></valueC>
</logic>

Here I've given myself three fields - valueA, valueB, valueC - for storing my 'decision points' inside a single group. Multiple groups may be allowed but I've not tried that.

Next, create a data connection to Receive data from an XML document. You are required to include the file as a resource (which you want to do anyway) when working with SharePoint list forms. And since the XML is basically empty, you might as well load the data on form open. That's about it for the data connection. You can set initial values for these fields in a Form Load rule, if necessary.

share|improve this answer
    
This isn't exactly what I had in mind, but it is working like a charm. I'll have to add more flags manually as I need more, but this is MUCH better than nothing. THANK YOU! –  Jerry Jan 17 '12 at 23:39
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.