Page.Session プロパティとは? わかりやすく解説

Page.Session プロパティ

ASP.NET提供している現在の Session オブジェクト取得します

名前空間: System.Web.UI
アセンブリ: System.Web (system.web.dll 内)
構文構文

Public Overridable ReadOnly
 Property Session As HttpSessionState
Dim instance As Page
Dim value As HttpSessionState

value = instance.Session
public virtual HttpSessionState Session { get;
 }
public:
virtual property HttpSessionState^ Session {
    HttpSessionState^ get ();
}
/** @property */
public HttpSessionState get_Session ()
public function get Session
 () : HttpSessionState

プロパティ
現在のセッション状態データ

例外例外
解説解説
使用例使用例

Web フォームページセッション状態格納されているキー取得し、その値を文字列変換する GetStyle 関数作成するコード例次に示します

' Create a private function that obtains
' information stored in session state
' in the application's Global.asax file.
' When this method is called and a key name
' that is stored in session state is passed
' as the parameter, the key is obtained and
' converted to a string.
Function GetStyle(Key As String)
 As String
  Return Session(Key).ToString()
End Function
// Create a private function that obtains
// information stored in Session state
// in the application's Global.asax file.
// When this method is called and a key name
// that is stored in Session state is passed
// as the paramter, the key is obtained and
// converted to a string.
String GetStyle(String key) {
  return Session[key].ToString();       
}
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

「Page.Session プロパティ」の関連用語

Page.Session プロパティのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



Page.Session プロパティのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.

©2025 GRAS Group, Inc.RSS