Bill Humphrey
Active member
- Joined
- Apr 10, 2008
- Messages
- 35
- Programming Experience
- Beginner
I've just migrated a project from VS 2003 to 2005 and this code is giving me an error:
the error is: variable Olog has been used before it has been assigned a value, a null reference exception could result at runtime.
Regards BH
VB.NET:
Try
Dim oLog As Object
If [COLOR="SeaGreen"]oLog [/COLOR]Is Nothing Then
oLog = New EventLog("CC", System.Environment.MachineName, "CC Application Log")
End If
Regards BH