How to generate workflow code file

Hi all,

I'm developping workflow designer.I have found System.Workflow.ComponentModel.Serialization.ActivityCodeDomSerializer

class can get CodeDom object,how but am I not too clear generate workflow code file(.cs and .designer.cs and .vb and .designer.vb file).Who can give me the detailed explanation how to make or provide some sample code?

thanks.

[389 byte] By [ChrisJiang] at [2007-12-25]
# 1

there is a nice article about designer rehosting at (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnlong/html/WFDsgnRehst.asp) that should have that working. take a look at MemberCreationService and EventBindingService services for more details.

Sergey

sergey.chub at 2007-9-3 > top of Msdn Tech,Software Development for Windows Vista,Windows Workflow Foundation...
# 2

Hi Sergey,

Thanks for your reply.I also want to consult a your question.

I want to get StateMachineWorkflowActivity's .layout file,but I do not want to use LoadDesignerLayout method and SaveDesignerLayout method of WorkflowDesignerLoader class.Ask how I should do?

ChrisJiang at 2007-9-3 > top of Msdn Tech,Software Development for Windows Vista,Windows Workflow Foundation...
# 3

If you just want to get the file, you can also use the GetFileReader and GetFileWriter methods on the Loader service (get a handle from an IServiceProvider). In your implementation of the loader, you can look for the file based on the input and get a reader to that file.

If you actually want to apply that layout, you'll want to use the methods you mentioned on the EndLoad to format your state machine.

What is it exactly that you are trying to do with the layout file?

Matt

MattMilner-Pluralsight at 2007-9-3 > top of Msdn Tech,Software Development for Windows Vista,Windows Workflow Foundation...
# 4

Hi Matt,

My meaning is makes one not to inherit WorkflowDesignerLoader the designer,therefore I cannot use the method of WorkflowDesignerLoader.But the layout file and the WorkflowDesignerLoader is the close correlation,therefore my this tentative plan is possibly not right.Thanks for your reply.

Chris

ChrisJiang at 2007-9-3 > top of Msdn Tech,Software Development for Windows Vista,Windows Workflow Foundation...

Software Development for Windows Vista

Site Classified