K
kimiraikkonen
Hi,
It may a simple question but i needed to verify. I hava a for-next
loop and when an exception occurs, i don't want my program to the jump
out of try-catch block and i want it to retry the operation again.
Here is what i meant:
Try
Dim x as integer
For x=0 to 10
<Codeline1>
Next
Catch
'Error message
<Codeline2>
End Try
'Operation ended
<Codeline3>
At this code when the program processing for example 3rd (x) item in
for-next loop and if an exception is thrown, <Codeline2> is executed
as well, then it jumps to <Codeline3>.
My aim is that when an exception is thrown on any for-next (x) item,
the program must ignore it or notice as messagebox then "continue"
processing operation till it reaches the end of for-next loop (x=10)
instead of jumping outside try-catch block and interrupting operation.
How can i do this?
Thanks!
It may a simple question but i needed to verify. I hava a for-next
loop and when an exception occurs, i don't want my program to the jump
out of try-catch block and i want it to retry the operation again.
Here is what i meant:
Try
Dim x as integer
For x=0 to 10
<Codeline1>
Next
Catch
'Error message
<Codeline2>
End Try
'Operation ended
<Codeline3>
At this code when the program processing for example 3rd (x) item in
for-next loop and if an exception is thrown, <Codeline2> is executed
as well, then it jumps to <Codeline3>.
My aim is that when an exception is thrown on any for-next (x) item,
the program must ignore it or notice as messagebox then "continue"
processing operation till it reaches the end of for-next loop (x=10)
instead of jumping outside try-catch block and interrupting operation.
How can i do this?
Thanks!