|
|||||||||
CSHARP の変更点
C#
* 初期段階[#kd8f9943]
#pre{{
using System.Diagnotics;
using System.IO;
}}
くらいは入れておく
* print デバッグ方式 [#s5d9ee47]
System.Diagnotics.Debug クラスの static 関数で、VisualStudioの右下「出力」ウィンドウにメッセージを出せる。~
Debug.WriteLine("string:" + value );
* ファイルを開くダイアログボックス [#p43b446f]
フィールドにおくもの
- ボタン(button1)
- テキストフィールド(textbox1)
- OpenFileDialog(openFileDialog1)
- button1_Click()
openFileDialog1.ShowDialog();
openFileDialog1.FileName;
で、ファイル選択ダイアログが出る~
もし、拡張子限定等を行いたい場合はプロパティから変更可能。~
結果は FileName メンバーに入る。~
※ 本来ならば DialogResult で OK かどうか、キャンセルかどうか~
の処理を適切に書く必要がある。~
* win32DLLを呼ぶ [#a7efeaff]
http://www.atmarkit.co.jp/fdotnet/dotnettips/024w32api/w32api.html
|
|||||||||