0

Hi I trying to extract information about the rules that are applied to a number of InfoPath forms, and I am using Powershell to do so.

I have unpacked the template.xsn file, and found the manifest.xsf file that stores this data.

Using the Powershell [xml]$ProjectXmlFile = Get-Content manifest.xsf to get the xml data, I am struggling to identify the nodes correctly.

The nodes are identified using the "xsf:" precursor, for example:

<xsf:submit caption="Submit" disableMenuItem="no" onAfterSubmit="close" showStatusDialog="no">
    <xsf:errorMessage>The form cannot be submitted because of an error.</xsf:errorMessage>
    <xsf:davAdapter name="SharePoint Library Submit" submitAllowed="yes" overwriteAllowed="no">
        <xsf:folderURL value="../"></xsf:folderURL>
        <xsf:fileName value="my:Submit/my:ref" valueType="expression"></xsf:fileName>
    </xsf:davAdapter>
</xsf:submit>

How do I identify these nodes in order to get the information out as normal xml data (i.e. if the nodes didn't have "xsf:" prefixing them)?

This is what I've been trying to use:

foreach ($DataQuery in $ProjectXmlFile.'xsf:xDocumentClass'.'xsf:dataObjects'.'xsf:dataObject'.'xsf:query'.'xsf:sharepointListAdapterRW')
 {
        Write-Host "DataQuery.name = $($DataQuery.'xsf:name')"
}

Or is there another reason that I can't access these nodes?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.