Using CAB With Indigo Web Services

Topics: CAB & Smart Client Software Factory
Mar 16, 2006 at 11:29 AM
originally posted by: capricorn1

I am still in the process of familiarizing myself with CAB and I have a few questions regarding Indigo Web Services.

Can I use Indigo Web Services in my CAB implementation? If so, how would I go about doing this? Is there any documentation available regarding this topic?


Mar 17, 2006 at 2:10 PM
originally posted by: ChrisHolmes

Yes, you can use Indigo services with CAB just fine. CAB doesn't really affect Indigo in any way. The application I'm working on currently uses one WCF web service and one WCF tcpTransport service and both work just fine.

I will assume you're familiar enough with Indigo/WCF to create a web service and run it in IIS. If you can do that then all you need to do is run the svcutil.exe to generate the proxy class file and the config file information. You'll get two output files from running svcutil.exe - a MyService.cs file and an output.config file. The contents of output.config need to be copied to your App.config file in your Shell of the CAB application. Include the MyService.cs file in your CAB project and you're good to go.

The only problem I ran into with this whole scenario was where the config information needed to be stored for Modules that want to load an Indigo service. I thought I could get away with the Module having it's own App.config file and storying the Endpoint information there, but when I did the Shell wouldn't load the service correctly. I think this was because when my Module loaded, it was trying to create an instance of the service to add to the rootWorkItem, and since the configuration information wasn't available (because the module wasn't fully loaded at the point) then it couldn't connect to the service and the Module failed to load. So, I have solved this problem by having all Indigo Endpoint config information in the Shell's App.config file.

If you have specific questions go ahead and e-mail me. Happy to help with this. If I get motivated maybe a blog post on the whole deal.
Mar 28, 2006 at 6:27 AM
originally posted by: capricorn1

Thank You!

I appreciate the feedback.