-
I see. Yes, I just tried this and got the same results. It seems this is happening because InfoPath sends the commandset implicit_transactions onbefore your query. Then the DELETE is considered an implicit transaction, and InfoPath sends the command: IF @@TRANCOUNT > 0 ROLLBACK TRANWhich rolls back your ...
-
Please remember that using a full XPath is always wrong when you are trying to target a specific node in a repeating group (unless you want the first node or are using filters in square brackets []).
In a changed event, e.Site should be positioned at the node to which the event is attached (in this case it looks like it's ADD_FLG). What ...
-
Perhaps this will do the trick?
http://www.infopathdev.com/blogs/hilary/archive/2009/03/13/locked-schema-got-you-down.aspx
-
I'm not that well-versed on saving and closing from code, but for number 1, if you're using the 2007 object model, it's MessageBox.Show(...), just like any Windows Forms app. In the 2003 object model, it would be thisXDocument.UI.Alert(...)
-
What do you mean by "it didn't work?" Did you get an error message? If so, what?
-
Ordinary file attachment controls store files directly in the form's XML, so I doubt that there is any way to avoid this issue while storing the files in ordinary file attachments.
I would second Ernesto's suggestion to try out qRules to see if it will work in this situation.
-
Most likely the issue is that the Clone() method does not actually clone a node. It just clones the XPath navigator. Please check out this post:
http://www.infopathdev.com/forums/p/11440/40502.aspx#40502
-
You need to add rules to the radio button's field, and based on the value of that field, clear the values of the fields that should be empty when the radio button has each available value.
-
Looks like you're almost there. In step 2, you need to set the rule on the field itself, not the attribute, and the rule should be setting the value of the attribute (which you appear to already be doing).
If you fix that, you should be all set.
-
Ok, thank you. Which node is the repeating one in your data source? I guess it's item? If that's the case, please try this:
string
r = e.Source.SelectSingleNode("field1", NamespaceManager).Value;