Welcome to Office Zealot Sign in | Join | Help
InfoPath Server Form Invocation - part 1

There are always questions on how does my form know where to open, in the browser or in the rich client?

The simple answer is to set the document library settings to open in the preferred environment. This can be either the InfoPath rich client or the browser.

The problems start to arise when you want to copy and paste a link and put it in email or IM to someone. The issue is how document libraries interact with the list items.

A when you click on an item in a document library there is SharePoint Java Script that gets activated and the script determines some things about your environment. These things are the default item open setting, permissions, type of document etc.

Depending on what the default open item is set to SharePoint may try to invoke InfoPath client or it may try to send the request to InfoPath Forms Service.

 Once the decision is made to send the request to InfoPath forms service the URL should look something like this:

http://server/_layouts/FormServer.aspx?XsnLocation=http://server/documentlibrary/Forms/template.xsn&SaveLocation=http://server/documentlibrary&DefaultItemOpen=1

The important things to look at is the DefaultItemOpen. This URL parameter detemines how the server will try to render the form.

DefaultItemOpen = 0 means try to render in the rich client

DefaultItemOpen = 1 means try to render in the browser.

There are other URL parameters such as OpenIn, SaveLocation, XsnLocation, XmlLocation. I will go into more detail about these later. I will also discuss how permissions are handled for forms.

 

The power of the press

I just got the Jan 7th issue of Information Week and i was reading the letters to the editor. There were a couple of letters about Windows Vista in this issue. One of the letters I found very interesting. It stated how arrogant Microsoft was about creating an operating system that is in compatible with the previous version.

The example the writer gave was "Vista isn't compatible with the lower Windows operating systems. For example, if a file is saved in Vista, it can't be opened in Windows; the file can't even be renamed."

Wow! I couldn't believe this letter was published. If you read the quote the writer doesn't say what program they are using they just say if you save a file using Vista. What does that mean? Do they mean a Microsoft Word file? Hmm, I don't know.

The problem is that someone is going to read this letter and take it as a factual piece of information.

Monitoring InfoPath Server

Now that InfoPath Server has been out for a while I wanted to get an idea of how people are using it and what type of health monitoring scenarios. The main scenarios we are looking at are around how admins can determine when InfoPath is doing something bad on the server. Such as, a user has deployed a form and it makes a large amount of data connections on start up. Each connection brings back large amounts of data. If this form is used by hundreds of users it could easily bring the overall performance of a server down.

 What other types of scenarios would be important to SharePoint administrators?

Dynamic languages vs. static languages.

 I recently stated doing some work with JavaScript as part of working on infoPath Forms Server. I realized that you can do some pretty powerful and cool things with JavaScript however the lack of strong types is a little hard to get used to.

In Java script you can do things like:

function TestFunction()

{

  

    var myVariable = 33;

    alert(i);

 

    myVariable = CallBack;

   

    myVariable();

 

}

 

function CallBack()

{

    alert("CallBack");

}

In this example I create a variable named myVariable and assign the integer value 33 to it. Then I assign the value or location of the function CallBack to the variable myVariable.

I then invoke the function by treating it as a function i.e. myVariable().

This is pretty cool and very powerful. However, the problem comes when you start looking at a large complex code base. Since there are no types you can’t easily determine the type of a variable. What the InfoPath team has done is used a naming convention for the variables. This allows us to track the object back to a source file.

However, since this is still a non typed language and there is no easy way to use the right click style go to definition found in Visual Studio and other tools.

When learning a new code base tools like this make things much easier. Working in JavaScript is analogous to walking around a dark room looking for a marble.

If anyone has any hints or tips on navigating large JavaScript code base let me know your thoughts.

Cell Phones.

What is the deal with cell phones?

Why do people need to have so much connectivity? I do have a cell phone but it does just the basics.

How about the people who have those things in their ears? Are they really that important?

 Now Apple is going into the phone business, I don't get that move either.

More Posts Next page »