Posts

Showing posts from December 22, 2013

Using WCF with non-microsoft clients

The default wsdl that WCF creates isn't very friendly for human's and other non-microsoft clients to read. To remedy this you can intsall WCFExtras: http://wcfextras.codeplex.com/ To use it, in your endpoint declaration add a " behaviorConfiguration " element with a name something like " WsdlRedirect ". Then add an endpointBehaviors declaration something like this:       < behaviors >        < endpointBehaviors >          < behavior name =" WsdlRedirect " >            < wsdlExtensions location =" https://testwebservices.website.ca/SomeService.svc "                            singleFile =" True " / >          < / behavior >        < / endpointBehaviors >   And add an extension under system.serviceModel like this:      < system.serviceModel >      < extensions >        < behaviorExtensions >          < add name =" wsdlExtensions "    

"An attempt was made to load a program with an incorrect format.” in IIS 7

Was working on an old website dev region that hadn't been used since we upgraded to IIS 7 and a 64-bit web server, and was getting this error: "An attempt was made to load a program with an incorrect format."   After some research I found the answer here: http://stackoverflow.com/questions/41449/i-get-a-an-attempt-was-made-to-load-a-program-with-an-incorrect-format-error-o The solution that worked for me was to enable 32-bit applications in the AppPool.