Ok, this question has been answered many times. But not for this scenario. I created new '开发者_高级运维Infopath Form Template' project, added new Class Library project to the solution and then created a Web Service proxy in that Class Library. When I try to create an instance of the Web Service client proxy I get this exception.
The usual solution is to copy the app.config into the Windows/Web application, but what about Infopath Form Template? I tried just adding the app.config to the project, but it didn't work.
Does anyone have an idea?
Thanks! Michael
What eventually worked for me: I created a solutions which contains only the Class Library project with the service. I edited the Form code using VSTA project (not form template project in regular Visual Studio), and copied there the app.config.
Works :)
精彩评论