Adds a new header with the indicated name and value.
[Visual Basic] Overloads Overrides Public Sub Add( _ ByVal name As String, _ ByVal value As String _ ) [C#] public override void Add( string name, string value ); [C++] public: override void Add( String* name, String* value ); [JScript] public override function Add( name : String, value : String );
Exception Type | Condition |
---|---|
ArgumentException | header is a restricted header that should be set with a property setting. |
If the header specified in header is already present, value is concatenated with the existing value.
WebHeaders Class | WebHeaders Members | System.Net Namespace | WebHeaders.Add Overload List