Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

Possible Duplicate:
SharePoint InfoPath formviewer part

I have a requirement for opening an InfoPath item from an InfoPath library in a custom application page. Here is the code:

XmlFormView formview = null;
formview = new XmlFormView();
formview.Width = Asp.Unit.Percentage(100);
formview.Height = Asp.Unit.Pixel(800);
formview.XsnLocation = "http://dev/infopathlibrary/forms/template.xsn";
formview.ShowHeader = false;
formview.ShowFooter = true;
this.Controls.Add(formview);

I am not able to view the InfoPath item but I am getting the view and close button only.

Could anyone help me to solve this issue ?

share|improve this question
add comment

marked as duplicate by SPDoctor Nov 6 '11 at 17:20

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1 Answer

You might this solution: http://grounding.co.za/blogs/romiko/archive/2009/09/24/integrating-infopath-forms-using-xmlformview-control-with-aspx-pages.aspx. In this solution, the InfoPath control is called via an ASP.NET control on the ASPX page instead of the code-behind.

share|improve this answer
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.