Infopath 2010 and CSS - InfoPath Dev
in

InfoPath Dev

Infopath 2010 and CSS

Last post 02-19-2012 08:44 PM by rahulbabar. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 02-09-2012 09:17 AM

    Infopath 2010 and CSS

    Hi ,

    I would like to attach my own css file to infopath 2010 form template.

    The reason for using external style sheet is if I create 50 forms then all I can do is edit the css file to keep my look and fell consistant for 50 form.

     I have been struggling to find the solution in google but no luck till now.

    Thanks in advance.

  • 02-15-2012 01:13 AM In reply to

    you can create custom template part for layout and look and feel and use it across different forms.

    You can refer below  URL.

    http://deepumi.wordpress.com/2012/01/08/create-custom-template-in-infopath-2010/

    Thanks,

    Rahul Babar

     

    ================================================
    ASP.NET, C#, Sharepoint 2007/2010/2013/SP Online, Infopath 2007/2010/2013 Admin/Developer
  • 02-15-2012 03:10 AM In reply to

    Hi Rahul,

     This way you can create a new form depending on the existing template. But where is the concept of External CSS.

    I would like to control my styling using CSS file. Sorry, I am a newbee to Infopath not sure if this is somthing possible or relavent with infopath 2010.

    Is there any posiblity that we can add Class or ID attributes to the controls like textbox.

    What is the equivalent control of asp.net lable in Infopath. I would like to change the text in runtime depending upon some rules. Seems like there are many limitations in Infopath.

    well thanks Rahul.

  • 02-19-2012 08:44 PM In reply to

     Hi Venkata,

    In infopath 2010, you will get option to save source files which will extract all the files inside .xsn template (archive). Then open View1.xsl and it contains XML Styles for controls on infopath. It is similar to CSS only. Also note that since infopath documents are ultimately XML documents, to style the controls you have to use XSL (Xml style language). Also the controls you see on the infopath forms are not actually Objects like ASP.NET controls, so you can not use them like controls. You have to always work with XML schema and XML documents to modify the values in infopath controls.

    After modifying XSL file, you have to right click on manifest.xsf and choose design and save it again.

    Thanks,

    Rahul Babar

     

    ================================================
    ASP.NET, C#, Sharepoint 2007/2010/2013/SP Online, Infopath 2007/2010/2013 Admin/Developer
Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.