Skip to main content


Hello,


I´ve been
reading through some posts about my problem but still can‘t quite get this
right.


I have an
Infopath form with 4 views. The first view is for a user who fills out a form
and then submits. Another user gets an email and opens the workitem, which is
the link to the second Infopath view; he reviews the information and chooses an
action and so on. This is not the problem, the workflow works perfectly.


I’m storing
the data from the first view in a SmartObject using the create method in the
Infopath view when submitting. The smartobject is created successfully, and the
form closes. As mentioned in other posts, I have created a datafield (called
SmOID) in the view for storing the SmartObject unique ID.


When the
second user opens the form with his view I want to load the SmartObject. I
first create a rule in the Open section in Form Options. This rule puts the id
parameter in the Load method equal to the SmOID field. Next rule calls the Load
function.


 


Now, here
comes the problem. Loading info from the SmartObject isn’t working. Is there
some step I’m missing? Does the create SmO rule have to be after the Submit
Workflow rule? I’m assuming that when the next user opens his view, the process
knows the SmoID, because it acts like an XML data field? Should the SmOID
datafield be placed somewhere specific in the form (not inside section etc.)?


 


Any nudge
towards the solution would be much appreciated – I need help :)


Update:


 


My rules in Submit are as follows:


Create Smo


Set SmOID = id (return property of Create method)


Submit Workflow


 


When calling the Load method I get error: Some rules were not applied. It seems the return property is not set to my datafield - any ideas?


The good news is what you are trying to do is very common and people do it all the time.  I would verify that you are truly getting the correct ID back from the create method and it is being stored in the data field.  Another approach would be to generate some sort of unique ID in the form, then store that in the SmartObject rather than relying on the return.  That way you always have the ID.


I'm guessing you are using forms server and getting the dreaded 'some rules were not applied', one of the most useless error messages of all time.  If you temporarily change your form to use the thick client instead, when you get that error you will also get a 'Show Details' button that will give more information about the cause of the error.  Knowing the cause of the error will put you one step closer to finding the answer.


Reply