InfoPath Form Template Part data source appending to existing Main data source instead of replacing

by michaellotter 13. November 2007 08:47

This week I started cross training a client employee on what I’ve been doing for the past 5 months because I’m leaving the project soon and start to look for a new project. Yesterday during our first session we discussed InfoPath Template Parts and how to build them and use them with existing InfoPath Forms. One thing that was brought to my attention again was how it interacts with an InfoPath Form when an existing control is being updated. When I discovered this the first time I forgot to blog about it but this time I didn’t want to pass up the opportunity because I think it’s pretty important to understand if you are going to use InfoPath Template Parts.

When building a new InfoPath Template Part you define the data source and then design the template part or you design the template part and let that define your data source. Once done you save it and then add it to the InfoPath designer when a form is being designed. At that point you then add it to the form and it magically appears and the new fields are added to the data source. All that is the straight forward stuff but now things start to get a little more complicated when you go back and modify the template part. If you go back to the template part and make a visual change (meaning not adding a new control that updates the data source) and save the changes and add it back into the InfoPath designer and update the existing control on the form everything works just fine. Now if you were to update the same template part but add a new control/field and save the changes and add it back into the InfoPath designer and update the existing control on the form everything appears to work just the same but it actually does one extra thing, it appends all the fields to the main data source again with the new one.  Logically you would think it would just update the existing structure with the new field but it doesn't.  If you’re not paying attention this could cause some major problems if things are not cleaned up. To clean things up just delete the original fields and then move the new fields to the location of the original fields and rename the new fields to the names of the original fields (sorry that’s so confusing).  It's pretty easy to do because InfoPath should have only added "_1" to the end of the new fields or the next number available.  If you don’t do the clean up then any existing data will still reference the original fields and won’t show up on the form because the form now points to the newly appended fields. This is sort of messy but I’m sure it’s done this way to preserve the original structure just in case it’s needed. That’s the only logical reason that I can think off at this point.

After writing this I sort of think the reason for not doing it before is because it’s so confusing to understand the situation without physically seeing it. With that being said I’m thinking about buying some capture software to create a video of what I’m talking about and hope this will give more clarification of what I’m talking about.

Cheers

Tags:

InfoPath 2007 | InfoPath Form Template

The InfoPath 2007 designer not always setting the field control Font size correctly the first time

by michaellotter 22. August 2007 04:19

Last week while waiting for my plane to takeoff from Newark airport, I was thinking I was going to start running out of new things to post but I'm finding out that won't be true anytime soon because I keep running into new little things all the time.  Currently most of my posts aren't super technical but more general things but that's only because that's the phase the current project is in. 

Enough of me jabbering and onto what I wanted to post about for this time, while over the past month designing these forms one thing that I've noticed is the font size is not always correctly being set through the InfoPath designer.  The buttons are probably the most common control that I have the problem with and I'm not 100 percent sure why but it's just something I've noticed.  Usually once the form has been graphically designed I do a "ctrl + A" key combination to select everything in the view and then change the font type and size and then go through and change all headings to a bigger font size and I'm done.  Well I've found out this approach isn't full proof and even if the font size in the designer says it's a certain size that's not always true.  Once I recognize it's not the correct size I change it to a different font size and then back to the original font size and then it sets correctly. 

That's all I really wanted to say and I know that's not much but it's something I've had to keep an eye on with all the forms that we are building and it's a pain in my side. Some of you might not think it's a big deal but there is nothing worse than showing a new form to a client and then the client pointing out not all font sizes aren't the same.

Cheers

Tags:

InfoPath 2007 | InfoPath Form Template

Online Resources for InfoPath 2007 Template Parts

by michaellotter 9. August 2007 05:06

Recently had a comment asking for online resources for InfoPath 2007 Template Parts and only posted 2 links because they were easiest to find.  Since then I went looking a little harder and found the following and in my opinion the "Designing and using template parts" is probably the best one of the lot.  It links to about 6 or 7 online MS articles that cover about everything on template parts.

Cheers

Designing and using template parts
http://office.microsoft.com/en-us/infopath/CH101638151033.aspx

Lab 10: Creating and Inserting InfoPath 2007 Template Parts
http://msdn2.microsoft.com/en-us/library/bb267331.aspx

How to: Share InfoPath 2007 Template Parts and ActiveX Controls
http://msdn2.microsoft.com/en-us/library/bb409614.aspx

InfoPath Team Blog - Template Parts 101
http://blogs.msdn.com/infopath/archive/2007/03/14/template-parts-101.aspx

The SharePoint Factory - InfoPath 2007: Form Template Parts
http://spsfactory.blogspot.com/2006/07/infopath-2007-form-template-parts.html

InfoPath 2007: Creating a Template Part
http://blog.funknstyle.com/?p=503

Tags:

InfoPath Form Template

About me

Michael Lotter
B&R Business Solutions
SharePoint Solution Architect
MCTS
More...

 

SharePoint Saturday

SharePoint Saturday is a free event open to the public and is focused on all aspects of SharePoint and related Microsoft Office technologies.  
  

 

 

 

 

 

 

Calendar

<<  February 2012  >>
MoTuWeThFrSaSu
303112345
6789101112
13141516171819
20212223242526
2728291234
567891011

View posts in large calendar

RecentComments

Comment RSS