Skip to main content

Setting the header values in webRequest?

Comments

3 comments

  • Permanently deleted user
    Hi Phil,

     

    You need to create a variable say "webHeaders" of type "System.Net.WebHeaderCollection", then use an Invoke Method as follows:

     

         TargetObject = webHeaders

     

         MethodName = Add

     

         Parameters: Type = String

     

    Value = "new WebHeaders("Accept: application/json; odata=verbose") Now, pass webHeader to the WebRequest activity as headers.

     

    Kindly let me know if you need any more help.

     

    Regards,

     

    Mohammad Ashraf                             
    0
  • Permanently deleted user
    Trying to do this but get the error: "

     

    The Content-Type header cannot be changed from its default value for this request."
    0
  • Permanently deleted user
    Hi Darko,

     

    If you are still getting this error, can you please post a sample request and obscure the data as required?

     

    Regards,

     

    Wayne Richard

     

    Latitude Geographics Group Ltd.

     

    Head Office: 300 – 1117 Wharf Street  Victoria, BC Canada V8W 1T7

     

    Tel: (250) 381-8130 | Fax: (250) 381-8132 | wrichard@latitudegeo.com

     

    Developers of Geocortex web-based mapping software | www.geocortex.com

     

    An Esri Platinum Business Partner
    0

Please sign in to leave a comment.