Issue dated - 9th June 2003

-


Previous Issues

CURRENT ISSUE
INDIA NEWS
NEWS ANALYSIS
STOCK FILE
INDIA TRENDS
E-BUSINESS
OPINION
FOCUS
COMPANY WATCH
TECHSPACE
TECHNOLOGY
PRODUCTS
EVENTS
COLUMNS
TECH FORUM

THE C# COLUMN

BETWEEN THE BYTES
TECHNOLOGY
SPECIALS <NEW>
HMA BANKBIZ
EC SERVICES
ARCHIVES/SEARCH
IT APPOINTMENTS
WRITE TO US
SUBSCRIBE/RENEW
CUSTOMER SERVICE
ADVERTISE
ABOUT US

 Network Sites
  IT People
  Network Magazine
  Business Traveller
  Exp. Hotelier & Caterer
  Exp. Travel & Tourism
  Exp. Backwaters
  Exp. Pharma Pulse
  Exp. Healthcare Mgmt.
  Express Textile
 Group Sites
  ExpressIndia
  Indian Express
  Financial Express

 
Front Page > TechSpace > Story Print this Page|  Email this page

InfoPath—The latest forms designer

Tech Forum - Dr. Nitin Paranjpe

All said and done, most line-of-business applications require a lot of data entry. We require a front-end to develop and paint forms, capture and validate the data and finally store and edit it in a database. Nothing new here. But usually the data layer, the validation layer and the front-end layer are all separate entities. Of course there are tools that help you integrate it all together.

In fact, the latest integrated development environment (IDE) of VS.NET really gives you the feeling that data, business logic and the user interface are very nicely integrated. But that is more due to a very sophisticated IDE rather than the layers being integrated in reality.

You must realise that for a database, it does not matter whether data was added by a direct insert command, through OLEDB, a COM component, an ASP page or Windows forms. Similarly, for end users, as long they can add and analyse data it doesn’t matter whether you are using client-server, three-tier, Web based, .NET based or Java based technology. Validation components are typically written in isolation wherein these only accept inputs and return values.

Due to this level of demarcation across layers, creating a set of data capture forms has always been cumbersome and code heavy. Of course, the existing development tools help you automate a lot of stuff, but it’s not been all that easy.

Now there’s InfoPath, and it’s a cakewalk! InfoPath is a very innocuous-looking tool which makes data capture as painless and simple as possible, yet without losing on any possible sophistication you may want! What’s more, this works across thin bandwidth in a dial-up scenario.

Although it is still a part of Office 2003 beta version, I found it very useful and powerful. Therefore, I am highlighting its features, functionality and possible shortfalls here.

As an IT professional, it is important to know all possible ways of doing things. You never know when the need will arise. You need to be prepared and you need to have versatile knowledge.

What is InfoPath?
InfoPath provides a single, fast and versatile mechanism of designing and managing data capture functionality. It can be used for ad-hoc data capture as well as sophisticated business validation based data entry.

The core data format used by InfoPath is XML. Therefore, you can integrate it with any existing database source within the organisation. InfoPath does the following:

  1. Creation of forms.
  2. Completion (data capture) using these forms.
  3. Submission of these forms (data) to various destinations (databases or other processes).

Very often different applications are used for entering related data. Here the method of data entry, the development tool and the destination database can be different. Moreover, users may be required to do repetitive entry of the same information due to the diversity of the applications. Data captured in informally created forms like Word or Excel is difficult to integrate with the core organisational database. InfoPath can help in such situations.

Data storage and processing
Firstly, InfoPath can store the form data offline. This is very useful for roaming users and field staff. When they connect to the extranet, the data can be sent to the central server and processed further. During offline entry, data is stored locally on the laptop.

Secondly, data can be stored to a database directly, or submitted to a Web service for processing. Windows Sharepoint Service is a new feature that allows team management of documents. InfoPath can also integrate directly with WSS.

Once data is entered into InfoPath, it need not go only to one destination. Each data element can be reused to update other related data sources / applications as well. Thus the user needs to enter data once and leave the complexity to InfoPath. Of course, all this needs to be configured and programmed in the beginning. But the development time is dramatically lower than what you have ever experienced.

InfoPath features
The forms designer is very flexible. Moreover, the form elements directly bind to the XML schema. Therefore, the form elements do not need to worry about data sources, DSN connections, database drivers and availability of connection.

The XML schema is defined and mapped to form elements. On submission, individual elements of the XML data can be used as required to update one or more data sources.

In traditional forms-based applications, the form designers typically knew the data structure of the back-end database and then created forms based upon this knowledge. Therefore, there was always a one-to-one correspondence between the UI element and the backend database fields. Now, by introducing an XML based—independent—schema as the data source for the InfoPath form, the possibilities of reuse and enriched use are dramatically increased.

Compared to Web forms and even Windows forms, InfoPath is a much more feature-rich forms designer. It provides many special formats, lists, grids and so on, which would otherwise require lot of manual tweaking in traditional forms design.

Most importantly, InfoPath is designed to be an environment for quick data driven forms design. Therefore, you can create a sophisticated UI in a much lesser time compared to traditional forms design tools. It even has features, which in traditional forms are very difficult to integrate, like Rich Text, AutoCorrect and Spelling Check support. Today, even with .NET a lot of cumbersome code and patchwork would be needed to provide such features in a form.

Programming InfoPath
As expected in any Microsoft product, the InfoPath environment is fully programmable. Hats off to Microsoft on this. Whether it’s an operating system or database or messaging server or a small desktop product like MSN Messenger or Outlook Express—everything that Microsoft makes is programmable. What’s more, it is comprehensively documented and explained using very rich content.

Thus InfoPath has its own object model. Incidentally, the best way to learn object-oriented design is by understanding how Microsoft makes object models. Word for example, is one of the most exquisitely designed and implemented object models. Look at the VS.NET IDE, delve deeper into Distributed Management Objects for administering SQL Server or simply learn from the elegant and smart object design of MS Graph. Anything you lay your hands on is a great learning opportunity. Open your mind and imbibe knowledge. It provides full scripting support for validation and UI management. It also provides programmability for direct Web service integration of the form elements.

Form building
One of the biggest problems in form design is how to manage a one-to-many data entry scenario. InfoPath solves this problem elegantly. There are repeating and non-repeating sections in the forms designer. There are optional sections that can be added at runtime based upon user needs. It provides brilliant conditional formatting. Something which we have used in Excel very often. Users often ask why such features cannot be given in internal Web applications. Here is the answer. Now this is available without any coding using InfoPath.

Validation
Validation rules are easily definable. Rules can be simple stuff like range parameters or could be more complex like a custom script.

Views and consolidation
The underlying XML schema for the form can be a pre-existing file or you can actually create it from scratch. Lists can be populated from database data. Controls can be data bound with custom rules. In offline mode, the data in the lookup fields can be cached. The same forms can have multiple views. The commonest would be detail and summary. But you can also have tabular v/s descriptive, tabular v/s graphical and so on.

A brilliant feature is consolidation. Very often we have to fill up a form for a repetitive task. For example, if you have gone on four tours and are filing a tour expense form, you have to fill four separate forms. This is cumbersome. Moreover, you cannot know information across all forms unless you do things manually. InfoPath allows you to consolidate multiple instances of the same form—not a single line of code required for this! This is a great feature for surveys. Just get individual files in a directory and choose the Merge options.

Security and safety
InfoPath supports digital signatures. For every feature of InfoPath, I was forced to think how easy or difficult this feature would be to incorporate in custom-built forms. You know the answer to this one for digital signatures. Although InfoPath is not a browser-based application, it does support sandboxing. This ensures that the forms can access local resources only when explicitly allowed by the security policy.

I would say the best part of this tool (and also the worst!) is that it is in reality an independent tool. It does not require Microsoft Office to be loaded at all. It loads by itself. This is not a Web-based tool. It runs in its own environment. This is probably the only disadvantage of this tool. It is not a deployment free solution. You have to load it once on every machine that participates in the InfoPath workflow. For internal users and roaming users with laptops, this is not a problem really. But for users who want to make use of a cybercafe it does pose a problem.

Where to use InfoPath?
As of today we have so many tools and technologies to make forms and integrate these with databases. Now we have one more. When to use InfoPath and when not to use it must be understood clearly.

For a very tightly controlled line-of-business application you should continue to use traditional development tools. But there are scenarios where we do use traditional form design where you should think of InfoPath. Here is a list of areas where InfoPath would be useful.

  1. Ad-hoc forms that are either paper-based or e-mail-based.
  2. Forms, which are currently hard-coded with a single database, but require integration with other databases or applications.
  3. Business process automation workflows.
  4. Mobile and field force information capture.
  5. Customer level data capture to eliminate paperwork in forms processing (use along with digital signatures).
  6. Teamwork involving multiple forms and multiple persons across locations.
  7. For consolidation and processing of similar forms submitted by multiple persons or locations.

This is only a representative list. As you learn more about the tool, I am sure there will be additional opportunities that will come to fore.

Conclusion
InfoPath is a great tool, built with finesse, sophistication as well as simplicity in mind. I would call it a masterpiece that combines the latest high technology with complete user focus in a single product—while providing a host of features which traditional form design environments have not been able to provide even in the .NET rich client days.

Imagine the amount of code you have to write to create a set of data capture forms that support generic schemas, multi-view support, digital signature support, rich text and image support, spell check and proofing tools support, generic and dynamic destination support, with full object mode and programmability and sandboxing. Just leave it all and use InfoPath!

About the Author:Dr Nitin Paranjape is the Chairman and MD of Maestros (Mediline). He is a consultant with many organisations, covering appropriate technology utilisation, business application of relevant technology, application architecture and audit as well as knowledge transfer. He has authored more than 650 articles on various technology-related subjects. He can be contacted at nitin@mediline.co.in
<Back to top>


© Copyright 2003: Indian Express Group (Mumbai, India). All rights reserved throughout the world. This entire site is compiled in
Mumbai by The Business Publications Division of the Indian Express Group of Newspapers.
Please contact our Webmaster for any queries on this site.