BasicHttpBinding Class
[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]
Represents a binding that a Windows Phone client can use to configure endpoints that can communicate with ASMX-based Web services and other services that conform to the WS-I Basic Profile 1.1.
Assembly: System.ServiceModel (in System.ServiceModel.dll)
The BasicHttpBinding type exposes the following members.
| Name | Description | |
|---|---|---|
![]() | BasicHttpBinding() | Initializes a new instance of the BasicHttpBinding class. |
![]() | BasicHttpBinding(BasicHttpSecurityMode) | Initializes a new instance of the BasicHttpBinding class with a specified type of security used by the binding. |
| Name | Description | |
|---|---|---|
![]() | CloseTimeout | Gets or sets the interval of time provided for a connection to close before the transport raises an exception. (Inherited from Binding.) |
![]() | EnableHttpCookieContainer | Gets or sets a value that indicates whether the BasicHttpBinding will include the HttpCookieContainerBindingElement. |
![]() | EnvelopeVersion | Gets the version of SOAP that is used for messages that are processed by this binding. |
![]() | MaxBufferSize | Gets or sets the maximum size for a buffer that receives messages from the channel. |
![]() | MaxReceivedMessageSize | Gets or sets the maximum size for a message that can be received on a channel configured with this binding. |
![]() | MessageVersion | Gets the message version used by clients and services configured with the binding. (Inherited from Binding.) |
![]() | Name | Gets or sets the name of the binding. (Inherited from Binding.) |
![]() | Namespace | Gets or sets the XML namespace of the binding. (Inherited from Binding.) |
![]() | OpenTimeout | Gets or sets the interval of time provided for a connection to open before the transport raises an exception. (Inherited from Binding.) |
![]() | ReceiveTimeout | Gets or sets the interval of time that a connection can remain inactive, during which no application messages are received, before it is dropped. (Inherited from Binding.) |
![]() | Scheme | Gets the URI transport scheme for the channels and listeners that are configured with this binding. (Overrides Binding::Scheme.) |
![]() | Security | Gets the type of security used with this binding. |
![]() | SendTimeout | Gets or sets the interval of time provided for a write operation to complete before the transport raises an exception. (Inherited from Binding.) |
![]() | TextEncoding | Gets or sets the character encoding that is used for the message text. |
| Name | Description | |
|---|---|---|
![]() | BuildChannelFactory<TChannel>(BindingParameterCollection) | Builds the channel factory stack on the client that creates a specified type of channel and that satisfies the features specified by a collection of binding parameters. (Inherited from Binding.) |
![]() | BuildChannelFactory<TChannel>(array<Object>) | Builds the channel factory stack on the client that creates a specified type of channel and that satisfies the features specified by an object array. (Inherited from Binding.) |
![]() | CanBuildChannelFactory<TChannel>(BindingParameterCollection) | Returns a value that indicates whether the current binding can build a channel factory stack on the client that satisfies the collection of binding parameters specified. (Inherited from Binding.) |
![]() | CanBuildChannelFactory<TChannel>(array<Object>) | Returns a value that indicates whether the current binding can build a channel factory stack on the client that satisfies the requirements specified by an object array. (Inherited from Binding.) |
![]() | CreateBindingElements | Returns an ordered collection of binding elements contained in the current binding. (Overrides Binding::CreateBindingElements().) |
![]() | Equals(Object) | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) |
![]() | Finalize | Allows an object to try to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.) |
![]() | GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
![]() | GetProperty<T> | Returns a typed object requested, if present, from the appropriate layer in the binding stack. (Inherited from Binding.) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() | ToString | Returns a string that represents the current object. (Inherited from Object.) |
The BasicHttpBinding uses HTTP as the transport for sending SOAP 1.1 messages. A service can use this binding to expose endpoints that conform to WS-I BP 1.1, such as those that ASMX clients access. Similarly, a client can use the BasicHttpBinding to communicate with services that expose endpoints that conform to WS-I BP 1.1, such as ASMX Web services or Windows Communication Foundation (WCF) services configured with the BasicHttpBinding.
Security is turned off by default, but can be added by setting the BasicHttpSecurityMode to a value other than None in the BasicHttpBinding(BasicHttpSecurityMode) constructor. It uses a "Text" message encoding and UTF-8 text encoding by default.
Capabilities
If you use this API in your app, you must specify the following capabilities in the app manifest. Otherwise, your app might not work correctly or it might exit unexpectedly.
ID_CAP_NETWORKING | Windows Phone 8, Windows Phone OS 7.1 |
For more info, see App capabilities and hardware requirements for Windows Phone 8.


