<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Newbie Questions</title><link>https://www.infopathdev.com:443/forums/39.aspx</link><description>New to InfoPath? Search to see if your question has already been answered. If it has not, then ask it here or the appropriate topic forum.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Remove all signatures from a form with javascript</title><link>https://www.infopathdev.com:443/forums/thread/3333.aspx</link><pubDate>Fri, 20 Oct 2006 21:13:38 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:3333</guid><dc:creator>Eric</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/3333.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=3333</wfw:commentRss><description>I got this code snippet to work but it actually removes the signature block completely from the code as opposed to just unsigning it.  I will have to look further.&lt;br /&gt;&lt;br /&gt;function dooButton::OnClick(eventObj)&lt;br /&gt;{&lt;br /&gt;____var oSignedDataBlocks = XDocument.SignedDataBlocks;&lt;br /&gt;____var count = oSignedDataBlocks.Count;&lt;br /&gt;____if( count &amp;lt;= 0 )&lt;br /&gt;____{&lt;br /&gt;________return;&lt;br /&gt;____}&lt;br /&gt;____XDocument.UI.Alert( oSignedDataBlocks.Count + " signature blocks." );&lt;br /&gt;____&lt;br /&gt;____var i = 0;&lt;br /&gt;____for( var i = 0; i &amp;lt; count; i++ )&lt;br /&gt;____{&lt;br /&gt;________var oSignedDataBlock = oSignedDataBlocks.Item( i );&lt;br /&gt;________if( oSignedDataBlock != null )&lt;br /&gt;________{&lt;br /&gt;____________if( oSignedDataBlock.Signatures != null )&lt;br /&gt;____________{&lt;br /&gt;________________var oSignatures = oSignedDataBlock.Signatures;&lt;br /&gt;________________var count2 = oSignatures.Count;&lt;br /&gt;________________XDocument.UI.Alert( count2 + " signatures in signature block " + i + " of " + count );&lt;br /&gt;________________for( var j = 0; j &amp;lt; count2; j++ )&lt;br /&gt;________________{&lt;br /&gt;____________________var signatureNodeRef = oSignedDataBlock.Signatures.Item( j );&lt;br /&gt;____________________var oSignatureNode = signatureNodeRef.SignatureBlockXmlNode;&lt;br /&gt;____________________if( oSignatureNode != null )&lt;br /&gt;____________________{&lt;br /&gt;________________________oSignatureNode.parentNode.removeChild( oSignatureNode );&lt;br /&gt;____________________}&lt;br /&gt;________________}&lt;br /&gt;____________}&lt;br /&gt;________}&lt;br /&gt;____}&lt;br /&gt;}&lt;br /&gt;</description></item><item><title>Remove all signatures from a form with javascript</title><link>https://www.infopathdev.com:443/forums/thread/1613.aspx</link><pubDate>Fri, 20 Oct 2006 20:46:16 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:1613</guid><dc:creator>Eric</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/1613.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=1613</wfw:commentRss><description>Hello,&lt;br /&gt;&lt;br /&gt;I need to remove all signatures from a form when it moves from one view state to a "rework" view state.&lt;br /&gt;&lt;br /&gt;this is my code fragment so far (doesn't work!) based on other posts I found in the forums.&lt;br /&gt;&lt;br /&gt;function dooButton::OnClick(eventObj)&lt;br /&gt;{&lt;br /&gt;	var oSignedDataBlocks = XDocument.SignedDataBlocks;&lt;br /&gt;	var count = oSignedDataBlocks.Count;&lt;br /&gt;	if( count &amp;lt;= 0 )&lt;br /&gt;	{&lt;br /&gt;		return;&lt;br /&gt;	}&lt;br /&gt;	XDocument.UI.Alert( oSignedDataBlocks.Count + " signature blocks." );&lt;br /&gt;	&lt;br /&gt;	var i = 0;&lt;br /&gt;	for( var i = 0; i &amp;lt; count; i++ )&lt;br /&gt;	{&lt;br /&gt;		var oSignedDataBlock = oSignedDataBlocks.Item( i );&lt;br /&gt;		if( oSignedDataBlock != null )&lt;br /&gt;		{&lt;br /&gt;			if( oSignedDataBlock.Signatures != null )&lt;br /&gt;			{&lt;br /&gt;				if( oSignedDataBlock.Signatures[0] != null )&lt;br /&gt;				{&lt;br /&gt;					var oSignatureNode = oSignedDataBlock.Signatures[0].SignatureBlockXmlNode;&lt;br /&gt;					if( oSignatureNode != null )&lt;br /&gt;					{&lt;br /&gt;						oSignatureNode.parentNode.removeChild( oSignatureNode );&lt;br /&gt;					}&lt;br /&gt;				}&lt;br /&gt;			}&lt;br /&gt;		}&lt;br /&gt;	}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;</description></item></channel></rss>