A list change doesn’t always trigger an InfoPath customized form refresh…

This was a strange one learned today under a bit of pressure (and a crazy idea that I thought of on my very own!)

I have a list in test that I’m keeping separate from the production list due to a ton of significant modifications that have changed/rechanged/scope-creeped over the last three months. Requests to change the “form fields” had, up to this point, just been changes to the labels in front of the fields. I didn’t worry about making the minor name tweaks in the actual list fields because I didn’t want to deviate any more than I already have from what’s in production.

That was all well and good… until the customer noticed that the column headers didn’t match the field name changes on the form. Late in the game and testing was supposed to start this afternoon, but fine… I’ll do it. I had them give me a list of the column names that absolutely needed to change, and what the field name should be. All normal stuff…

I made the changes in the list, and then went to Customize Form to pull in the changes and re-publish it. I was a bit surprised I didn’t get the warning message saying there were list changes, but I normally don’t change field names like that. I tweaked a couple of things on the form labels, re-published, and let them know I had done all the changes…

… only to find that all the list field name changes had reverted to the old names.

Suffering from insanity, I did the same thing again, expecting to get different results. And true to insanity, I got the same results. What’s worse, I wasn’t seeing a way I could change the field name on the form to get what I wanted in the list.

I sat back for a second and thought… I know the form has to refresh from the list when I add new fields to the list. How can I force a refresh, and if I can, will it grab the field name changes from the list?

“Test Field 1” to the rescue!

I added a test field to the list along with changing a couple of the field names to see if they would be refreshed in the form. The new field triggered the InfoPath form refresh, and the refresh picked up both the new field and my field name changes. Sighs of relief were heard in the mancave office…

I made the rest of the name changes, tossed another test field in there, got the form updated, and then deleted (and refreshed again) the test fields. Everyone was happy, and the “must have by 1 pm” was made with minutes to spare.

I still don’t know why a field name change wouldn’t trigger the form refresh, but I now know I can force it by putting a new field in the list, which WILL trigger the refresh.

In the Notes world, Joe Litton used to call this type of stuff “TJN” (“That’s Just Notes”). In my SharePoint world, I use the “TJS” variation…

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s