1: vi /etc/sysconfig/selinux
SELINUX=enforcing 改成 SELINUX=disabled
1: using System;
2: using System.Windows.Forms;
3: using System.IO;
4: 5: namespace WindowsFormsApplication1
6: {7: public partial class Form1 : Form
8: {9: public static string InvalidPath ="1:\\invlid_path.txt";
10: 11: public Form1()
12: { 13: InitializeComponent(); 14: } 15: 16: private void Form1_Load(object sender, EventArgs e)
17: {18: MessageBox.Show("Form1_Load 1");
19: string s = File.ReadAllText(InvalidPath);
20: MessageBox.Show("Form1_Load 2");
21: } 22: 23: private void button1_Click(object sender, EventArgs e)
24: {25: string s = File.ReadAllText(InvalidPath);
26: } 27: } 28: }
【編按】YouTube開始實現以HTML5 的Video標籤播放影片,引起頗大的熱潮。加上iPad不支援Flash,更是讓Adobe頻頻挫折。不過目前使用HTML 5播放影片的網站,除了Apple以外,介面都顯得稍微陽春。但其實HTML 5 Video標籤可以做到相當多的變化,就讓謝子斌老師來告訴我們怎麼使用!(...)One VERY important point is that this issue is only on exceptions raised during the Forms.OnLoad event handler (or methods called from within this event handling).回憶起確實遇過Form_Load階段有錯誤,卻沒被VS2008抓到的經驗,當時很狐疑是否VS2008某個設定沒調好才會這個樣子,但因為不致"卡關",便未深究。
using System;
using System.Windows.Forms;
using System.IO;
namespace WindowsFormsApplication1
{public partial class Form1 : Form
{public static string InvalidPath =
"1:\\invlid_path.txt";
public Form1()
{InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{MessageBox.Show("Form1_Load 1");string s = File.ReadAllText(InvalidPath);
MessageBox.Show("Form1_Load 2");}
private void button1_Click(object sender, EventArgs e)
{string s = File.ReadAllText(InvalidPath);
}
}
}