最終更新:2013-03-28 (木) 17:09:34 (4047d)  

My
Top / My

クラス・ライブラリの中でよく使う機能へのショートカットを提供

  • IntelliSenseのとき便利。
    System.IO.Directory.GetCurrentDirectory()
    ↓
    My.Application.CurrentDirectory
  • アプリケーション専用のオブジェクトを自動的に生成する機能
    • My.Settings
      • アプリケーション独自の設定情報を扱うためのもので、大ざっぱにいえば、INIファイルやレジストリの後継に当たるもの
    • My.Resources?

メモ

  • Visual Basic の既定構成では、プロジェクト名がルートの名前空間になっているので、My の名前空間は、正式には、「プロジェクト名.My」という名前です。このことは、プロジェクト単位 (プログラム ファイル単位) で、My の定義が異なることを意味します。よって、1 つのアプリケーションであっても、Windows フォームの EXE ファイルにおける "My.Application" と、その Windows フォームが参照する DLL ファイルにおける "My.Application" は、それぞれ異なる My.MyApplication? クラスであるという点に注意してください。

My

  • My.Application?
    • ApplicationContext?
    • AssemblyInfo?
    • CommandLineArgs?
    • CurrentCulture?
    • CurrentDirecroty?
    • CurrentUICulture
    • Deployment
    • IsNetworkDeployed?
    • Log
    • MainForm?
    • OpenForms?
    • SplashScreen?
  • My.Computer
    • My.Computer.Audio?
    • My.Computer.Clipboard?
    • My.Computer.Clock?
    • My.Computer.FileSystem?
    • My.Computer.Info?
    • My.Computer.Keyboard
    • My.Computer.Mouse?
    • My.Computer.Name?
    • My.Computer.Network
    • My.Computer.Ports?
    • My.Computer.Printers?
    • My.Computer.Registroy?
    • My.Computer.Screen?
  • My.Forms?
  • My.Resources?
  • My.Settings
  • My.User?
  • My.WebServices?

参考