Monday, February 15, 2010

InfoPath Forms Vs ASPX Pages

In order to create forms for the use of SharePoint Sites, we will be generally using either InfoPath forms or ASPX pages.

In this blog, I am going to mention the pros, cons and the decisions that has to be made at the time of development for the forms for the use in SharePoint sites.

In general, the decision to use among InfoPath forms and ASPX pages all depends on the requirement of the form. Most of the Developers or Managers will think of InfoPath forms for developing the forms to use them in SharePoint Sites as it will be easy to develop and there will be no much coding involved.

Before going for such a decision, we need to understand the requirement and also the pros and cons of using InfoPath forms. Based on the requirements complexity, we need to choose either of InfoPath forms or ASPX pages. Because as the complexity increases, ASPX pages will be the best option for creating the forms. As InfoPath forms by itself are incomplete and needs to have a container (like XMLFormViewer webpart) to be placed in the SharePoint Sites for having same look and feel, which is again in an ASPX page, we need to carefully analyze the requirement and take decisions accordingly.


The following are the PROS and CONS (for and against) using InfoPath over ASPX pages which has to be considered before making a decision.


PROS:
  1. If the requirement is all about showing the data in the form from SharePoint Site, or external data store, InfoPath form is recommended as it does not require much coding.
  2. If we need to submit the data in the form to multiple locations such as SharePoint library, external data store, InfoPath forms are the best solution.
  3. Moreover if there is a need to developing numerous forms which are simple enough and well documented, then InfoPath forms should be considered, as they deliver the solution in a short span as it has drag drop features in it and also provides support for prebuilt template parts and shared data connections.
  4. InfoPath forms are more flexible to use for a quick and neat solution as it has some complex out of the box controls, like Date Picker, File Attachment control, Repeating Sections and also have the code-behind if needed to manipulate the data on the form or behind the form and it also includes a Design Checker to help consistency for forms.
  5. InfoPath forms supports data integrity and version control for document management purposes and add structure to information gathering by converting legacy documents to rich InfoPath form templates and are also very nicely integrated with SharePoint custom workflows as workflow association tool.
  6. It is fully integrated in Microsoft Office 2007 suites like Outlook e-mail messages that can be deployed as Outlook e-mail messages, so collegues can complete the forms without leaving the familiar Outlook environment.
  7. InfoPath forms can easily convert word documents and Excel spreadsheets to forms and build templates to work with.It also creates PDF or XPS and other important document formats and is extensible by addition of a free pulg-in to install third party tools and components for document, archival and records management.
  8. Support for information rights management to help manage permission control and building a powerful document management team site and is also fully centralized for entire Organization and enables Organizations to Centrally.
  9. InfoPath forms are firewall friendly, and the InfoPath Forms Services make it easy to extend the forms solutions beyond the firewall because of using many different web browsers and mobile devices.
  10. InfoPath forms are based on XML and the form is rendered using XSLT stylesheet and the data submitted through the form is available in XML format and hence the data is well structured to retrieve later on and dump the data/forms in some external system. This is in combination with BizTalk Server is a perfect architecture for document transition through multiple levels.


CONS:
  1. If it is a single form and needs complex actions, to and fro between the form and the data store, then choosing Custom ASPX pages is recommended.
  2. A web browser-enabled InfoPath form does not support all features of InfoPath client.
  3. If the requirement needs feature like user going through multiple screens, then Custom ASPX is the solution.
  4. Apart from few complex controls, InfoPath browser enabled forms does not support many advanced controls such as Combo Box, Master/Detail view control, etc., Depending on these limitations, we have to decide on InfoPath forms or ASPX pages. Where ASPX pages have no such limitations.
  5. ASPX can have and do everything that an InfoPath form does with an exception of additional development effort. Apart from it, the deployment process of ASPX forms is much better and easier than InfoPath Forms.
  6. InfoPath Forms are inflexible-difficult or impossible to customize unless you can hack the xsl files of InfoPath.
  7. InfoPath forms will not support SharePoint web services data connections in Forms Based Authentication, image buttons, html, and tree control and is difficult to support Forms Based Authentication(FBA).
  8. Moreover it does not support username() function in FBA as it cannot recognize the current user.
  9. It is difficult to perform automated web test against Forms Services and difficult to support automated deployment as you have to unzip the xsn file and programatically modify the manifest.xsf file, and zip back to the xsn file for automated publishing.
  10. The way that Forms Services supports deployment of InfoPath forms is meaningless as it creates SharePoint Solution Packages with GUID and creates features with meaningless names on the SharePoint Features folder.

1 comment:

Please Leave Your Comments Here On This Post.....

Followers