Click here to Skip to main content
15,891,943 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Error: Server did not recognize the value of HTTP Header SOAPAction Pin
Scott5222-Dec-16 1:59
Scott5222-Dec-16 1:59 
QuestionNeed help populating fields from database to form in page load Pin
Bootzilla3320-Dec-16 8:51
Bootzilla3320-Dec-16 8:51 
AnswerRe: Need help populating fields from database to form in page load Pin
Richard Deeming20-Dec-16 10:18
mveRichard Deeming20-Dec-16 10:18 
QuestionViewData, Viewbag and tempdata not working Pin
Member 815484520-Dec-16 6:47
Member 815484520-Dec-16 6:47 
AnswerRe: ViewData, Viewbag and tempdata not working Pin
Richard Deeming20-Dec-16 8:09
mveRichard Deeming20-Dec-16 8:09 
GeneralRe: ViewData, Viewbag and tempdata not working Pin
Member 815484520-Dec-16 8:36
Member 815484520-Dec-16 8:36 
GeneralRe: ViewData, Viewbag and tempdata not working Pin
Richard Deeming20-Dec-16 10:11
mveRichard Deeming20-Dec-16 10:11 
QuestionASMX: Facing problem to send user credentails from client side to service end Pin
Tridip Bhattacharjee19-Dec-16 3:51
professionalTridip Bhattacharjee19-Dec-16 3:51 
i consult these two web site just to know how to work with soap header

https://www.codeproject.com/articles/4398/authentication-for-web-services-using-soap-headers

https://www.codeproject.com/Articles/27365/Authenticate-NET-Web-Service-with-Custom-SOAP-Head

i also develop my web service this way. see the code
C#
namespace CustomAuthWithHTTPModule
{
    /// <summary>
    /// Summary description for SecureWebService
    /// </summary>
    public class Authentication : SoapHeader
    {
        public string User;
        public string Password;
    }

    public class SecureWebService : WebService
    {
        public Authentication authentication;

        [WebMethod]
        [SoapHeader("authentication", Required = true)]
        public string ValidUser()
        {
            if (User.IsInRole("Customer"))
                return "User is in role customer";

            if (User.Identity.IsAuthenticated)
                return "User is a valid user";
            return "not authenticated";
        }

    }

}


in my console apps i create the proxy of the above web service just by add web reference. the problem is AuthHeaderValue or UserCredentialsValue both property is not being expose at client side by which i can send user credentials. see my client code
C#
ServiceReference1.SecureWebServiceSoapClient xx = new ServiceReference1.SecureWebServiceSoapClient();

            ServiceReference1.Authentication a = new ServiceReference1.Authentication();
            a.User = "Hello";
            a.Password = "Hello";
            xx.AuthHeaderValue  or xx.UserCredentialsValue // not being expose


guide me where i made the mistake. i am working with VS2013 IDE. thanks
tbhattacharjee

AnswerRe: ASMX: Facing problem to send user credentails from client side to service end Pin
jkirkerx19-Dec-16 11:40
professionaljkirkerx19-Dec-16 11:40 
GeneralRe: ASMX: Facing problem to send user credentails from client side to service end Pin
Tridip Bhattacharjee20-Dec-16 21:17
professionalTridip Bhattacharjee20-Dec-16 21:17 
AnswerRe: ASMX: Facing problem to send user credentails from client side to service end Pin
jkirkerx21-Dec-16 9:49
professionaljkirkerx21-Dec-16 9:49 
GeneralRe: ASMX: Facing problem to send user credentails from client side to service end Pin
Tridip Bhattacharjee21-Dec-16 20:31
professionalTridip Bhattacharjee21-Dec-16 20:31 
GeneralRe: ASMX: Facing problem to send user credentails from client side to service end Pin
jkirkerx22-Dec-16 8:20
professionaljkirkerx22-Dec-16 8:20 
GeneralRe: ASMX: Facing problem to send user credentails from client side to service end Pin
Tridip Bhattacharjee22-Dec-16 21:28
professionalTridip Bhattacharjee22-Dec-16 21:28 
GeneralRe: ASMX: Facing problem to send user credentails from client side to service end Pin
jkirkerx23-Dec-16 7:02
professionaljkirkerx23-Dec-16 7:02 
QuestionASMX Web Service Soap Extension ProcessMessage function not calling Pin
Tridip Bhattacharjee19-Dec-16 2:09
professionalTridip Bhattacharjee19-Dec-16 2:09 
AnswerRe: ASMX Web Service Soap Extension ProcessMessage function not calling Pin
Tridip Bhattacharjee21-Dec-16 20:32
professionalTridip Bhattacharjee21-Dec-16 20:32 
Questionasp .net web development Pin
Sanju govind18-Dec-16 20:53
Sanju govind18-Dec-16 20:53 
AnswerRe: asp .net web development Pin
Peter Leow18-Dec-16 21:02
professionalPeter Leow18-Dec-16 21:02 
QuestionRe: asp .net web development Pin
ZurdoDev19-Dec-16 8:23
professionalZurdoDev19-Dec-16 8:23 
AnswerRe: asp .net web development Pin
koolprasad200320-Dec-16 22:43
professionalkoolprasad200320-Dec-16 22:43 
QuestionNeed help on passing id to next page on response.redirect Pin
Bootzilla3318-Dec-16 10:43
Bootzilla3318-Dec-16 10:43 
AnswerRe: Need help on passing id to next page on response.redirect Pin
F-ES Sitecore18-Dec-16 21:59
professionalF-ES Sitecore18-Dec-16 21:59 
QuestionData not updating on fields using UPDATE Statement Pin
Bootzilla3318-Dec-16 10:41
Bootzilla3318-Dec-16 10:41 
AnswerRe: Data not updating on fields using UPDATE Statement Pin
Richard Deeming19-Dec-16 2:33
mveRichard Deeming19-Dec-16 2:33 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.