|
有問題的地方是: Protected Sub InsertButton_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles InsertButton.Click Dim i, u_FileNum, f_FileNum, e_FileNum, s_FileNum As Integer Dim u_FileName As String = "上傳成功:" Dim f_FileName As String = "檔案不存在:" Dim e_FileName As String = "檔名重複:" Dim s_FileName As String = "檔案超過100K:" Dim MsgFind As Label = CType(FindControl("lblMsg"), Label)
上面程式碼其中MsgFind怎麼TRY都是空值(nothing),也就是FindCtrol它找不到"lblMsg",可是"lblMsg"明明是一個控制項啊!! |