<?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>Code</title><link>https://www.infopathdev.com:443/forums/45.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Signing a part of my Form</title><link>https://www.infopathdev.com:443/forums/thread/14719.aspx</link><pubDate>Thu, 13 Jul 2006 15:36:50 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:14719</guid><dc:creator>fredarwin</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/14719.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=14719</wfw:commentRss><description>Well, i got a solution&lt;br /&gt;if u´are working with signed forms, form library and sql database and you need change some field in the Document after u're sign the form and save this change to datasources do the nex code:&lt;br /&gt;&lt;br /&gt;function XDocument::OnSign(eventObj)&lt;br /&gt;{&lt;br /&gt;&lt;br /&gt;	var Signature = eventObj.SignedDataBlock.Signatures.Create();&lt;br /&gt;&lt;br /&gt;	Signature.Sign();&lt;br /&gt;	eventObj.ReturnStatus = true;&lt;br /&gt;	&lt;br /&gt;	if (XDocument.IsSigned)&lt;br /&gt;	{	&lt;br /&gt;		XDocument.DOM.selectSingleNode("/dfs:myFields/dfs:dataFields/d:SolicitudesMS/@autorizado").text="1";&lt;br /&gt;	&lt;br /&gt;		var idsolicitud=XDocument.DOM.selectSingleNode("/dfs:myFields/dfs:dataFields/d:SolicitudesMS/@idsolicitudesMS").text;&lt;br /&gt;	&lt;br /&gt;		try&lt;br /&gt;		{&lt;br /&gt;		&lt;br /&gt;		XDocument.QueryAdapter.Command = 'execute "sp_autoriza" ' + idsolicitud; &lt;br /&gt;		XDocument.Query();&lt;br /&gt;		&lt;br /&gt;		var oXDocument2= XDocument.DataAdapters("Enviar a SP");	&lt;br /&gt;		oXDocument2.Submit();&lt;br /&gt;		}&lt;br /&gt;		catch (ex)&lt;br /&gt;		{&lt;br /&gt;			Xdocument.UI.Alert(ex.description);&lt;br /&gt;			eventObj.ReturnStatus = false;&lt;br /&gt;		}&lt;br /&gt;	}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;the master tip for execute the sp is include the sentence:&lt;br /&gt;SET IMPLICIT_TRANSACTIONS off&lt;br /&gt;</description></item><item><title>Re: Signing a part of my Form</title><link>https://www.infopathdev.com:443/forums/thread/14718.aspx</link><pubDate>Wed, 12 Jul 2006 14:21:56 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:14718</guid><dc:creator>fredarwin</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/14718.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=14718</wfw:commentRss><description>Thanks for the advise, i did change of the field on ip but cant change the database field.&lt;br /&gt;my code:&lt;br /&gt;//*****Execute Signature wizard*********///&lt;br /&gt;XDocument.UI.ShowSignatureDialog(); &lt;br /&gt;///////////////////change ip field after sing//////////	&lt;br /&gt;XDocument.DOM.selectSingleNode("/dfs:myFields/dfs:dataFields/d:SolicitudesMS/@authorize").text="1";&lt;br /&gt;///////change database field//////&lt;br /&gt;var objADOAdapter;&lt;br /&gt;var id=XDocument.DOM.selectSingleNode("/dfs:myFields/dfs:dataFields/d:SolicitudesMS/@id").text;&lt;br /&gt;objADOAdapter = XDocument.DataObjects("sample").QueryAdapter;&lt;br /&gt;objADOAdapter.Command='execute "SP_AUTORIZA" ' + id;&lt;br /&gt;objADOAdapter.Command.Execute;&lt;br /&gt;//////////send to mform library--------&amp;gt;&lt;br /&gt;var oXDocument2= XDocument.DataAdapters("SendToSP");	&lt;br /&gt;oXDocument2.Submit();&lt;br /&gt;////////////&lt;br /&gt;&lt;br /&gt;This is executed without problems, but my database field never is updated why??.&lt;br /&gt;I never get a message error.</description></item><item><title>Re: Signing a part of my Form</title><link>https://www.infopathdev.com:443/forums/thread/14717.aspx</link><pubDate>Wed, 12 Jul 2006 10:01:26 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:14717</guid><dc:creator>Kalyan Gaddam</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/14717.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=14717</wfw:commentRss><description>Hello,&lt;br /&gt;&lt;br /&gt;Did you try using OnAfterChange event handler on the authorized field. The field is updated when the changes happen in the xml. Please read the link below.&lt;br /&lt;a target="_blank" href=http://msdn.microsoft.com/library/default.asp?url=/library/en-us/ipsdk/html/xdevtOnAfterChange_HV01021366.asp&gt;http://msdn.microsoft.com/library/default.asp?url=/library/en-us/ipsdk/html/xdevtOnAfterChange_HV01021366.asp&lt;/a&gt;</description></item><item><title>Signing a part of my Form</title><link>https://www.infopathdev.com:443/forums/thread/12918.aspx</link><pubDate>Tue, 11 Jul 2006 13:51:23 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:12918</guid><dc:creator>fredarwin</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/12918.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=12918</wfw:commentRss><description>I have a form published in a form library. my fields published are:&lt;br /&gt;name, department, position, authorized.&lt;br /&gt;I am using a main database connection to storege data.&lt;br /&gt;&lt;br /&gt;when i submit data: firts save data to my database and then are sent to the form library&lt;br /&gt;&lt;br /&gt;I am using Signatures by section and the fields that are signed are:&lt;br /&gt;name, department, position.&lt;br /&gt;&lt;br /&gt;Well, i need to update the authorized field &lt;b&gt;after i sign &lt;/b&gt; the other fields and save changes.&lt;br /&gt;&lt;br /&gt;This is possible?&lt;br /&gt;&lt;br /&gt;I need do this because i need to show in my form library view the authorized field.</description></item></channel></rss>