tags:

views:

321

answers:

4

I see all sample from nServiceBus to be a standalone process, so can it be integrated with winform? if yes, where can i find samples?

A: 

You can just call nServiceBus class like usual in WinForm.

Ngu Soon Hui
A: 

If you want the generic host to run as a winform you need to pass it /gui on the command line.

Udi Dahan
I mean, if i already have a winform app, i wanna emply nServiceBus to pub/sub message, how to do this, since your nServiceBus has so little document. thanks for the great messaging framework.
Benny
Then in your main method of your program class, you'd write something similar to the following:NServiceBus.Configure.With() .SpringBuilder() .XmlSerializer() .MsmqTransport() .PurgeOnStartup(true) .UnicastBus() .LoadMessageHandlers() .CreateBus() .Start();You can see this in the AsyncPages sample, just make sure not to use "WithWeb()" in your WinForms app.Hope that covers it for you.
Udi Dahan
thanks Udi Dahan. I am excited to directly communicate the writer. thousand thanks.
Benny
A: 

Udi,

In VB.net the line bus = NServiceBus.Configure.With() .SpringBuilder() .XmlSerializer() .MsmqTransport() .PurgeOnStartup(true) .UnicastBus() .LoadMessageHandlers() .CreateBus() .Start()

does not work, compiler error Error 1 Reference required to assembly 'NServiceBus, Version=2.0.0.963, Culture=neutral, PublicKeyToken=9fc386479f8a226c' containing the type 'NServiceBus.IStartableBus'. Add one to your project. c:\users\simonxps\documents\visual studio 2010\Projects\TestNServiceBus\TestNServiceBusClient\Form1.vb 20 15 TestNServiceBusClient

Obviously I have a reference to the NsericeBus.dll

Any ideas

simon thompson
A: 

I'm getting this same error in a vb.net app - did you find a solution?

mgcain