次の方法で共有


HttpSessionState.StaticObjects プロパティ

ASP.NET アプリケーション ファイル global.asax 内の <object Runat="Server" Scope="Session"/> タグで宣言されているオブジェクトのコレクションを取得します。

Public ReadOnly Property StaticObjects As _
   HttpStaticObjectsCollection
[C#]
public HttpStaticObjectsCollection StaticObjects {get;}
[C++]
public: __property HttpStaticObjectsCollection* get_StaticObjects();
[JScript]
public function get StaticObjects() : HttpStaticObjectsCollection;

プロパティ値

global.asax ファイルで宣言されたオブジェクトが格納されている HttpStaticObjectsCollection

解説

オブジェクトがシリアル化をサポートしない場合、および Mode がプロセスの範囲外にある場合 (SQLServer または StateServer)、オブジェクトは作成されず、このコレクションにも追加されません。

StaticObjects は、ASP の旧バージョンとの互換性のために指定されます。

必要条件

プラットフォーム: Windows 2000, Windows XP Professional, Windows Server 2003 ファミリ

参照

HttpSessionState クラス | HttpSessionState メンバ | System.Web.SessionState 名前空間