1. 程式人生 > >一些操作記錄備查

一些操作記錄備查

 

行號顯示------------------------------

Private Sub GridView1_CustomDrawRowIndicator(sender As Object, e As RowIndicatorCustomDrawEventArgs) Handles GridView1.CustomDrawRowIndicator
'行號
If e.Info.IsRowIndicator And e.RowHandle >= 0 Then
e.Info.DisplayText = e.RowHandle + 1
End If
End Sub

判斷NULL------------------------------

判斷在資料庫中取出的欄位是否是 NULL 用 ISDBNULL

如:If IsDBNull(objData) Then

判斷一個物件是否存在,是否被初始化用 Nothing

如:If dsData Is Nothing Then

------------------------------------------