Praveen battula

i created a workflow consists of two tasks. in my workflow.xml
<Task0_FormURN>urnTongue Tiedchemas-microsoft-comSurpriseffice:infopath:ClientForm:-myXSD-2007-05-02T08-40-27</Task0_FormURN>
<Task1_FormURN>urnTongue Tiedchemas-microsoft-comSurpriseffice:infopath:ClientForm2:-myXSD-2007-05-04T11-45-42</Task1_FormURN>

in my second task it should call ClientForm2 when task changed from task1 to task2,

but when i click on second task i m able to see ClientForm, why not ClientForm2,

what could be the issue any ideas.......
what i need to do to get ClientForm2....

thanks in advance



Re: SharePoint - Workflow For second task also i am getting first infopath form, why not second infopath form?

cksturton

In the create task method of each task have you set the SPWorkflowTaskProperties.TaskType property For the first task set it to 0, for the second task set it to 1.

Hope that helps,

-Cynthia





Re: SharePoint - Workflow For second task also i am getting first infopath form, why not second infopath form?

Praveen battula

thank you very much, it's working
thanks alot.
actually i don't know this property,





Re: SharePoint - Workflow For second task also i am getting first infopath form, why not second infopath form?

cksturton

I'm glad it worked. The TaskType property is what tells the workflow which task form to use for that task. <Task0_FormURN> will be used if task type is set to 0, <Task1_FormURN> will be used if task type is set to 1, etc.

-Cynthia





Re: SharePoint - Workflow For second task also i am getting first infopath form, why not second infopath form?

Needo

Hello

I have done as u said, but for its still unable to see the 2nd form,

i wrote this code in createTask event of 2nd task

XmlSerializer serializer2 = new XmlSerializer(typeof(ContentForm));

XmlTextReader reader2 = new XmlTextReader(new System.IO.StringReader(WorkflowProperties1.InitiationData));

ContentForm conform = (ContentForm)serializer2.Deserialize(reader2);

sUser3 = conform.sendmail;

ĄŻbut form doesnot appear so the object is null, and gace exception.

Please tell me any thing

Thanks

Needo






Re: SharePoint - Workflow For second task also i am getting first infopath form, why not second infopath form?

Praveen battula

hi Needo,
You are wrong.
the code given above is only write in on workflow activated event.
for each and every task there is a property called taskpropertes.
in this case you just want to show up 2nd infopath form for ur 2nd task, write the code as shown below.
taskproperties2.Tasktype =2; //here 2 is the task types given in workflow.xml
if you want to access the values from infopath form,
string value = taskproperties2.ExtendedProperties["key name"];


thanks
Praveen.





Re: SharePoint - Workflow For second task also i am getting first infopath form, why not second infopath form?

Needo

Thanks Buddy Smile

Thanks Alot Smile

You are my hero. You solved me a problem for which i spent 1 whole day.

Take Care






Re: SharePoint - Workflow For second task also i am getting first infopath form, why not second infopath form?

Praveen battula

hi Needo,

but you didn't mark me as answer.

ok, keep posting, so we can share knowledge.

thanks
Praveen.