Hi
Someone replied requesting some samples of failing code:
The following Try..catch statement does not always work:
Try
NNoteId = myNotes.Create(mybizUser, AddString)
NumNotesCon = NumNotesCon + 1
Catch myE As Exception
Try
If myNotes Is Nothing Then
myNotes = New
Microsoft.CRM.Platform.Proxy.CRMNotesManager
myNotes.Credentials =
System.Net.CredentialCache.DefaultCredentials
myNotes.Url = StrDir & "CRMNotesManager.srf"
End If
If RetryCreateUpdate() = True Then
NNoteId = myNotes.Create(mybizUser, AddString)
NumNotesCon = NumNotesCon + 1
etc...
end try
end try
If the original line of code fails I want to catch the error and check and
retry some connections and then try the create function again. However I get
a connection failed popup error which is possible and the reason I want to
trap any error caused by this line. I am not new to ado, I am new to .net
however I can step thru my code and see that the catch statement is not
working or in some cases it is woking however the error still pops up. This
seems to be mostly a problem on win 2003.
Isdbnull sample
isdbnull(myRS.Fields(5).Value)=True then ......
myRS is an ado recordset connecting to an ODBC database and a single table.
The statement simply does not always return the correct true/false value
based on the field value, regardless of the OS.
"Mark Martin" <mm*****@brodie.com> wrote in message
news:ee*************@TK2MSFTNGP10.phx.gbl...
Hi All
I am having a couple problems with VS 2003 VB.net especially when
deploying and running my app on Win 2003 small business server. The app is a simple
but intensive windows form application using ado to retrieve data from an
ODBC database and then populate a MS CRM database using web services.
1. The try... catch statement does not appear to work all the time and
generates an unhandled error even though the line of code causing the
error is in the try statement.
2. IsDBNull does not return the correct value causing runtime errors.
Does anyone know if these are bugs or is there something specific I need
to know for this to work.