HttpSessionStateBase.Add(String, Object) 方法

定义

当在派生类中被重写时,向会话状态集合添加一个项。When overridden in a derived class, adds an item to the session-state collection.

public:
 virtual void Add(System::String ^ name, System::Object ^ value);
public virtual void Add (string name, object value);
abstract member Add : string * obj -> unit
override this.Add : string * obj -> unit
Public Overridable Sub Add (name As String, value As Object)

参数

name
String

要添加到会话状态集合的项的名称。The name of the item to add to the session-state collection.

value
Object

要添加到会话状态集合的项的值。The value of the item to add to the session-state collection.

例外

始终。Always.

适用于