Click here to Skip to main content
13,095,218 members (72,303 online)
Rate this:
Please Sign up or sign in to vote.
See more:
I have a created a WCF service application, through which i am accesing function of a C++ DLL. The code is given below :
namespace zielhabbegService
    public class zielhabbegServiceClass : IzielhabbegServiceClass
        [DllImport("FANselect.dll", CallingConvention = CallingConvention.StdCall,
                                       EntryPoint = "ZAJsonRequestA", ExactSpelling = false)]
        private static extern IntPtr ZAJsonRequestA([MarshalAs(UnmanagedType.LPStr)]StringBuilder szReq);
        public string getZAJsonRequestA(string input)
            StringBuilder sbuilder = new StringBuilder();
            string sResult = Marshal.PtrToStringAnsi(ZAJsonRequestA(sbuilder));
            return sResult;

This, web service is working fine.
But, when i try to access this through a web application, i am getting this error :

Could not find default endpoint element that references contract 'abc.IzielhabbegServiceClass' in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element.

I found one strange thing here, first I added a service reference of the above WCF service, and then the proxy class generated is IzielhabbegServiceClassClient instead of zielhabbegServiceClassClient ? May be this is the reason why i am not able to get the output
Any help, would be appreciated

Posted 16-Apr-13 1:08am
babu saravanan 16-Apr-13 12:51pm
can you please share the config code for endpoint, what kind of hostiong you are using... please give brief info

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web01 | 2.8.170813.1 | Last Updated 16 Apr 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100