0
votes

I have an Infopath 2010 form that's been developed for a document library in SharePoint 2010. The form contains custom VB code, which is saved on a shared drive.

However, should the VB project on the shared drive get deleted/damaged/forgotten about, is there a way to retrieve the custom code from SharePoint itself? I know you can go to Library Settings>Advanced Settings>Document Template>Edit Template to retrieve the Infopath form, but when you attempt to edit the custom code, Infopath asks for the VB project location.

Does a plain-text, uncompiled version of the code get stored somewhere in SharePoint when the form is deployed?

2

2 Answers

1
votes

When I have needed to get the code for a form and don't have access to original code files, one approach I have taken is to save the form as source files (either unzipping the template with a tool like 7-zip or from the publish menu in InfoPath in design mode) and then decompiled the code DLL with ILSPY. Imperfect & a bit of a pain, but has allowed me to see what may be going on in a template file and recreate the source code when needed.

0
votes

Found my own answer - looks like I'd be out of luck.

http://www.bizsupportonline.net/blog/2013/recover-make-changes-infopath-forms-sharepoint.htm

Paragraph at the bottom just before "3 ways you can find out whether code was written for a form template"

That's a pretty helpful feature, Infopath...