.NET C# - Get started

Add the webservice to your project

1. Add Service Reference
2. Add the address https://smsc.vianett.no/smshttp/Service.asmx
3. Call it SMShttpWS

Create your first code (check how many credits the user has left)

// Create the web service

SMShttpWS.ServiceSoapClient s = new SMShttpClient.SMShttpWS.ServiceSoapClient("ServiceSoap12");

// Create a variable for the result
SMShttpWS.SMSHttpResult r = new SMShttpWS.SMSHttpResult();

// Connect to the webservice and put the result in r
r = s.GetBalance(ApplicationId, userName, passWord); // Your ApplicationID, and the users username and password

(r.ErrorCode == 200)
    // Login ok
    int CreditsLeft = r.CreditsLeft;

Good luck with the rest of your application :)



The technology is based on
ViaNett SMS  Copyright SmartSMS AS  Prices / terms & about us