Hi friends.
please help me with this problem, i've searched it for a day but i couldn't solve it!
I use Visual Studio 2012, ASP.NET, c#.
I've created new website ( not web project ),
In solution explorer right click on project and clicked
Add Service Reference
then I've add a web service provider address, a new folder named
App_WebReferences created. It contains ServiceReference1 folder in which there are three files(two .svcinfo and one .wsdl).
Now I use this code as my provider guided:
var srv = new ServiceReference1.PaymentIFBindingSoapClient();
double result = srv.verifyTransaction(refNum, "10004738");
there is no error in compilation and running in localhost.
BUT
when I upload my website files to my ftp on the server..
I get this error message:
*Server Error in '/' Application.
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
**Compiler Error Message:** CS0246: The type or namespace name 'ServiceReference1' could not be found (are you missing a using directive or an assembly reference?)
Source Error:
Line 69: Line 70:
Line 71: var srv = new ServiceReference1.PaymentIFBindingSoapClient();
Line 72:
Line 73: double result = srv.verifyTransaction(refNum, "10004738");
Source File: d:\domains\olomrayaneh.net\wwwroot\ebook\check_payment.aspx.cs Line: 71
Show Detailed Compiler Output:
Show Complete Compilation Source:
Version Information: Microsoft .NET Framework Version:2.0.50727.3643; ASP.NET Version:2.0.50727.3634*
I've stuck in this problem.
Whats the problem!?
How should I solve it?
PLEASE help me !!
I should say that I tried to add this line:
using ServiceReference1;
then the error message line changes to this line with the same message !
and again no error message in localhost running!
my website is build in .Net Framework 3.5
thanks in advance.