By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,625 Members | 1,274 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,625 IT Pros & Developers. It's quick & easy.

not all paths return a value

P: n/a
guy
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Private Function CreateFolder(ByVal sFileName As String) As Boolean

On Error GoTo Errors

'Create it if necessary
If Directory.Exists(sFileName) = False Then
Directory.CreateDirectory(sFileName)
End If

'Succeeded in creating a folder
CreateFolder = True

Errors:

End Function
Jan 3 '06 #1
Share this Question
Share on Google+
25 Replies


P: n/a

It is recommended that classic VB6 error handling be replaced
with structured exception handling.

But to answer your specific question: In the code, no specific value
is returned in the (empty) error handler.

Just put a "CreateFolder = False" line after the "Errors:" label.

Note: You can also write "Return <value>" instead of
"<function name> = <value>".

/Joergen Bech

On Tue, 3 Jan 2006 08:30:06 -0800, guy <gu*@discussions.microsoft.com>
wrote:
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Private Function CreateFolder(ByVal sFileName As String) As Boolean

On Error GoTo Errors

'Create it if necessary
If Directory.Exists(sFileName) = False Then
Directory.CreateDirectory(sFileName)
End If

'Succeeded in creating a folder
CreateFolder = True

Errors:

End Function


Jan 3 '06 #2

P: n/a
I dont program in VB.NET - but not all paths return a value because falling
into error before you set createFolder=True would fail to provide a return
value, and you need to return a bool.

Put CreateFolder = False in your error section. Better still - start using
try/catch statements and get rid of the goto
--
Regards

John Timney
Microsoft MVP

"guy" <gu*@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Private Function CreateFolder(ByVal sFileName As String) As Boolean

On Error GoTo Errors

'Create it if necessary
If Directory.Exists(sFileName) = False Then
Directory.CreateDirectory(sFileName)
End If

'Succeeded in creating a folder
CreateFolder = True

Errors:

End Function

Jan 3 '06 #3

P: n/a
John Timney ( MVP ) wrote:
I dont program in VB.NET - but not all paths return a value because
falling into error before you set createFolder=True would fail to
provide a return value, and you need to return a bool.


I'm sure he realises that, the question was as to why he *didn't* get a
compiler warning. I would have expected there to be one too.

--

(O)enone
Jan 3 '06 #4

P: n/a
guy
this will definitely be rewritten, my point was the code as it stands does
NOT warn about a code path that does not return a value

"John Timney ( MVP )" wrote:
I dont program in VB.NET - but not all paths return a value because falling
into error before you set createFolder=True would fail to provide a return
value, and you need to return a bool.

Put CreateFolder = False in your error section. Better still - start using
try/catch statements and get rid of the goto
--
Regards

John Timney
Microsoft MVP

"guy" <gu*@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Private Function CreateFolder(ByVal sFileName As String) As Boolean

On Error GoTo Errors

'Create it if necessary
If Directory.Exists(sFileName) = False Then
Directory.CreateDirectory(sFileName)
End If

'Succeeded in creating a folder
CreateFolder = True

Errors:

End Function


Jan 3 '06 #5

P: n/a
"guy" <gu*@discussions.microsoft.com> schrieb:
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Private Function CreateFolder(ByVal sFileName As String) As Boolean

On Error GoTo Errors

'Create it if necessary
If Directory.Exists(sFileName) = False Then
Directory.CreateDirectory(sFileName)
End If

'Succeeded in creating a folder
CreateFolder = True

Errors:

End Function


To me it seems that they have forgotten to implement the check for 'On Error
GoTo'...

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 3 '06 #6

P: n/a

Whoops. Misread the original post. .Net Reflector to the rescue.

This is what the code is turned into:

---snip---
Private Shared Function CreateFolder(ByVal sFileName As String) As
Boolean
Dim flag1 As Boolean
Dim num2 As Integer
Try
ProjectData.ClearProjectError
Dim num1 As Integer = 2
If Not Directory.Exists(sFileName) Then
Directory.CreateDirectory(sFileName)
End If
flag1 = True
goto Label_0066
Label_0025:
num2 = -1
Select Case num1
Case 0, 1
goto Label_005B
Case 2
goto Label_0066
End Select
Catch obj1 As Object When (?)
ProjectData.SetProjectError(CType(obj1, Exception))
goto Label_0025
End Try
Label_005B:
Throw ProjectData.CreateProjectError(-2146828237)
Label_0066:
If (num2 <> 0) Then
ProjectData.ClearProjectError
End If
Return flag1
End Function
---snip---

Dim flag1 As Boolean means that flag1 is implicitly initialized
to False by .Net.

So all code paths are indeed satisfied.

But it sure is ugly.

Regards,

Joergen Bech

On Tue, 3 Jan 2006 09:02:03 -0800, guy <gu*@discussions.microsoft.com>
wrote:
this will definitely be rewritten, my point was the code as it stands does
NOT warn about a code path that does not return a value

"John Timney ( MVP )" wrote:
I dont program in VB.NET - but not all paths return a value because falling
into error before you set createFolder=True would fail to provide a return
value, and you need to return a bool.

Put CreateFolder = False in your error section. Better still - start using
try/catch statements and get rid of the goto
--
Regards

John Timney
Microsoft MVP

"guy" <gu*@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
>i have inherited the following migrated vb6 code (vb2005)
> but i DONT get the "not all paths return a value" squiggly - is this a
> 'feature' of on error goto?
>
> Private Function CreateFolder(ByVal sFileName As String) As Boolean
>
> On Error GoTo Errors
>
> 'Create it if necessary
> If Directory.Exists(sFileName) = False Then
> Directory.CreateDirectory(sFileName)
> End If
>
> 'Succeeded in creating a folder
> CreateFolder = True
>
> Errors:
>
> End Function
>
>



Jan 3 '06 #7

P: n/a

well it does return a value cause it returns false
as a boolean datatype can`t be nothing or empty

:-)

so what is the point ??

M. Posseth [MCP]
"guy" <gu*@discussions.microsoft.com> schreef in bericht
news:7E**********************************@microsof t.com...
this will definitely be rewritten, my point was the code as it stands does
NOT warn about a code path that does not return a value

"John Timney ( MVP )" wrote:
I dont program in VB.NET - but not all paths return a value because
falling
into error before you set createFolder=True would fail to provide a
return
value, and you need to return a bool.

Put CreateFolder = False in your error section. Better still - start
using
try/catch statements and get rid of the goto
--
Regards

John Timney
Microsoft MVP

"guy" <gu*@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
>i have inherited the following migrated vb6 code (vb2005)
> but i DONT get the "not all paths return a value" squiggly - is this a
> 'feature' of on error goto?
>
> Private Function CreateFolder(ByVal sFileName As String) As Boolean
>
> On Error GoTo Errors
>
> 'Create it if necessary
> If Directory.Exists(sFileName) = False Then
> Directory.CreateDirectory(sFileName)
> End If
>
> 'Succeeded in creating a folder
> CreateFolder = True
>
> Errors:
>
> End Function
>
>


Jan 3 '06 #8

P: n/a
On Tue, 3 Jan 2006 18:31:58 +0100, "Herfried K. Wagner [MVP]"
<hi***************@gmx.at> wrote:
"guy" <gu*@discussions.microsoft.com> schrieb:
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Private Function CreateFolder(ByVal sFileName As String) As Boolean

On Error GoTo Errors

'Create it if necessary
If Directory.Exists(sFileName) = False Then
Directory.CreateDirectory(sFileName)
End If

'Succeeded in creating a folder
CreateFolder = True

Errors:

End Function


To me it seems that they have forgotten to implement the check for 'On Error
GoTo'...


As far as I understand it, the squiggly lines are not based on the
source text you see, but what the parser turns it into. Which in this
case is an entirely different beast. See my other post.

I see no bugs.

/JB

Jan 3 '06 #9

P: n/a

His point is that - on the surface - it does not *explicitly*
return a value.

/JB

On Tue, 3 Jan 2006 18:37:08 +0100, "m.posseth" <po*****@planet.nl>
wrote:

well it does return a value cause it returns false
as a boolean datatype can`t be nothing or empty

:-)

so what is the point ??

M. Posseth [MCP]
"guy" <gu*@discussions.microsoft.com> schreef in bericht
news:7E**********************************@microso ft.com...
this will definitely be rewritten, my point was the code as it stands does
NOT warn about a code path that does not return a value

"John Timney ( MVP )" wrote:
I dont program in VB.NET - but not all paths return a value because
falling
into error before you set createFolder=True would fail to provide a
return
value, and you need to return a bool.

Put CreateFolder = False in your error section. Better still - start
using
try/catch statements and get rid of the goto
--
Regards

John Timney
Microsoft MVP

"guy" <gu*@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
>i have inherited the following migrated vb6 code (vb2005)
> but i DONT get the "not all paths return a value" squiggly - is this a
> 'feature' of on error goto?
>
> Private Function CreateFolder(ByVal sFileName As String) As Boolean
>
> On Error GoTo Errors
>
> 'Create it if necessary
> If Directory.Exists(sFileName) = False Then
> Directory.CreateDirectory(sFileName)
> End If
>
> 'Succeeded in creating a folder
> CreateFolder = True
>
> Errors:
>
> End Function
>
>


Jan 3 '06 #10

P: n/a
Looks like a normal behavior as all paths are likely returning a value as
all paths are ending with end function (and the implicit return value is
false). IMO you have rather this warning when you use the "exit function"
statement ??

--
Patrice

"guy" <gu*@discussions.microsoft.com> a écrit dans le message de
news:5E**********************************@microsof t.com...
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Private Function CreateFolder(ByVal sFileName As String) As Boolean

On Error GoTo Errors

'Create it if necessary
If Directory.Exists(sFileName) = False Then
Directory.CreateDirectory(sFileName)
End If

'Succeeded in creating a folder
CreateFolder = True

Errors:

End Function

Jan 3 '06 #11

P: n/a
A value is still returned even if not explicit so Im' not sure the warning
would be fine here. Let's take the other way round. What kind of code would
create this warning ? (Exit Function ?)

--
Patrice

"Joergen Bech @ post1.tele.dk>" <jbech<NOSPAMNOSPAM> a écrit dans le message
de news:c1********************************@4ax.com...

His point is that - on the surface - it does not *explicitly*
return a value.

/JB

On Tue, 3 Jan 2006 18:37:08 +0100, "m.posseth" <po*****@planet.nl>
wrote:

well it does return a value cause it returns false
as a boolean datatype can`t be nothing or empty

:-)

so what is the point ??

M. Posseth [MCP]
"guy" <gu*@discussions.microsoft.com> schreef in bericht
news:7E**********************************@microso ft.com...
this will definitely be rewritten, my point was the code as it stands does NOT warn about a code path that does not return a value

"John Timney ( MVP )" wrote:

I dont program in VB.NET - but not all paths return a value because
falling
into error before you set createFolder=True would fail to provide a
return
value, and you need to return a bool.

Put CreateFolder = False in your error section. Better still - start
using
try/catch statements and get rid of the goto
--
Regards

John Timney
Microsoft MVP

"guy" <gu*@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
>i have inherited the following migrated vb6 code (vb2005)
> but i DONT get the "not all paths return a value" squiggly - is this a > 'feature' of on error goto?
>
> Private Function CreateFolder(ByVal sFileName As String) As Boolean >
> On Error GoTo Errors
>
> 'Create it if necessary
> If Directory.Exists(sFileName) = False Then
> Directory.CreateDirectory(sFileName)
> End If
>
> 'Succeeded in creating a folder
> CreateFolder = True
>
> Errors:
>
> End Function
>
>

Jan 3 '06 #12

P: n/a
"guy" <gu*@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Errors:

End Function


I've read a few of these answers that state something along the lines of:
Just put a "CreateFolder = False" line after the "Errors:" label.


That should never be required. Since False is the default return value for
any boolean function/variable/whatever, explicitly setting the return =
False should never be required. If it is suddenly required after 30 years of
programming, there should be a huge notice posted on the web somewhere that
says "forget about your existing source code, everything has suddenly
changed for no good reason"

--
Ken Halter - MS-MVP-VB (visiting from VB6 world) - http://www.vbsight.com
Please keep all discussions in the groups..
Jan 3 '06 #13

P: n/a
"Joergen Bech @ post1.tele.dk>" <jbech<NOSPAMNOSPAM> schrieb:
To me it seems that they have forgotten to implement the check for 'On
Error
GoTo'...


As far as I understand it, the squiggly lines are not based on the
source text you see, but what the parser turns it into. Which in this
case is an entirely different beast. See my other post.


The occurance of the warning depends on the return type of the function. So
it's not actually a bug, but I believe the warning could have been
implemented in a way that it is also shown for functions which return a
value type.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 3 '06 #14

P: n/a
"Patrice" <no****@nowhere.com> schrieb:
Looks like a normal behavior as all paths are likely returning a value as
all paths are ending with end function (and the implicit return value is
false). IMO you have rather this warning when you use the "exit function"
statement ??


Consider this sample:

\\\
Public Function Foo() As Object
If True Then
Return "x"
End If
End Function
///

This function implicitly returns 'Nothing' on all code paths too if no
return value is set. So I do not think that this is a big difference to the
scenario the OP described, although the warning is shown for the code above.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 3 '06 #15

P: n/a
Ken,

"Ken Halter" <Ken_Halter@Use_Sparingly_Hotmail.com> schrieb:
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Errors:

End Function


I've read a few of these answers that state something along the lines of:
Just put a "CreateFolder = False" line after the "Errors:" label.


That should never be required. Since False is the default return value for
any boolean function/variable/whatever, explicitly setting the return =
False should never be required. If it is suddenly required after 30 years
of programming, there should be a huge notice posted on the web somewhere
that says "forget about your existing source code, everything has suddenly
changed for no good reason"


You could actually disable the warning. Simply open up the project file in
a text editor and add the warning number (42105) to the 'NoWarn' element.
My main concern is that the warning only occurs at functions which return a
reference type.

The full text of the warning makes this more clear: "[...] A null reference
exception could occur at run time when the result is used". I do not think
that implicitly returning 'Nothing' is a big problem. The main problem is
IMO forgetting to set a return value for a certain code path inside the
function. The same problem applies to BC42104 too. I have summed up my
thoughts on the usefulness of this warning in an article (in German):

Zur Sinnhaftigkeit der Compilerwarnung BC42104
<URL:http://dotnet.mvps.org/dotnet/articles/bc42104/>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 3 '06 #16

P: n/a
Sorry I don"t have 2005 hand. Even with a boolean return value ? What is the
code create for this ? I wonder what is the exact condition that triggres
this warning...

--
Patrice

"Herfried K. Wagner [MVP]" <hi***************@gmx.at> a écrit dans le
message de news:eP**************@TK2MSFTNGP14.phx.gbl...
"Patrice" <no****@nowhere.com> schrieb:
Looks like a normal behavior as all paths are likely returning a value as all paths are ending with end function (and the implicit return value is
false). IMO you have rather this warning when you use the "exit function" statement ??
Consider this sample:

\\\
Public Function Foo() As Object
If True Then
Return "x"
End If
End Function
///

This function implicitly returns 'Nothing' on all code paths too if no
return value is set. So I do not think that this is a big difference to

the scenario the OP described, although the warning is shown for the code above.
--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 3 '06 #17

P: n/a
"Patrice" <no****@nowhere.com> schrieb:
Sorry I don"t have 2005 hand. Even with a boolean return value ? What is
the
code create for this ? I wonder what is the exact condition that triggres
this warning...


The warning will only work if the function's return type is a reference
type.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 3 '06 #18

P: n/a
Thanks for the follow up...

--
Patrice

"Herfried K. Wagner [MVP]" <hi***************@gmx.at> a écrit dans le
message de news:e$*************@tk2msftngp13.phx.gbl...
"Patrice" <no****@nowhere.com> schrieb:
Sorry I don"t have 2005 hand. Even with a boolean return value ? What is
the
code create for this ? I wonder what is the exact condition that triggres this warning...


The warning will only work if the function's return type is a reference
type.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 3 '06 #19

P: n/a
On Tue, 3 Jan 2006 19:21:52 +0100, "Herfried K. Wagner [MVP]"
<hi***************@gmx.at> wrote:
"Joergen Bech @ post1.tele.dk>" <jbech<NOSPAMNOSPAM> schrieb:
To me it seems that they have forgotten to implement the check for 'On
Error
GoTo'...


As far as I understand it, the squiggly lines are not based on the
source text you see, but what the parser turns it into. Which in this
case is an entirely different beast. See my other post.


The occurance of the warning depends on the return type of the function. So
it's not actually a bug, but I believe the warning could have been
implemented in a way that it is also shown for functions which return a
value type.


Care to give me an example that involves On Error Goto?

It is true that the squiggly lines appear for

Public Function ObjectDoesProduceSquiggleLines() As Object
'Do nothing
End Function

but not for

Public Function ValueProducesNoSquiggleLines() As Boolean
Dim b As Boolean = True
End Function

But when the "On Error ..." abomination is used, as in the sample
the original poster provided ...

Check the samples below. None of them produce squiggly lines, even
though I am fairly positive that they cover both objects and value
types as return values. I see no difference in behavior due to
the choice of return types.

If you look at what the compiler turns the samples into, you will
see that something is explicitly returned on all code paths in all
samples.

---snip---
Option Explicit On
Option Strict On
....
Public Function GetString() As String
On Error GoTo someerror
Return ""
SomeError:
End Function

Public Function GetObject() As Object
On Error GoTo SomeError
Return Nothing
SomeError:
End Function

Public Function GetBoolean() As Boolean
On Error GoTo SomeError
Return False
SomeError:
End Function

Public Function GetArrayList() As ArrayList
On Error GoTo SomeError
Return New ArrayList
SomeError:
End Function
---snip---

Regards,

Joergen Bech

Jan 3 '06 #20

P: n/a

---snip---

I've read a few of these answers that state something along the lines of:
Just put a "CreateFolder = False" line after the "Errors:" label.


That should never be required. Since False is the default return value for
any boolean function/variable/whatever, explicitly setting the return =
False should never be required. If it is suddenly required after 30 years of

---snip---

Yes, I know. As I said in another post, I misread the original post.

Sorry.

/JB

Jan 3 '06 #21

P: n/a
"Joergen Bech @ post1.tele.dk>" <jbech<NOSPAMNOSPAM> schrieb:
To me it seems that they have forgotten to implement the check for 'On
Error
GoTo'...

As far as I understand it, the squiggly lines are not based on the
source text you see, but what the parser turns it into. Which in this
case is an entirely different beast. See my other post.
The occurance of the warning depends on the return type of the function.
So
it's not actually a bug, but I believe the warning could have been
implemented in a way that it is also shown for functions which return a
value type.


Care to give me an example that involves On Error Goto?


My bad. I finally didn't test it with 'On Error GoTo'.
But when the "On Error ..." abomination is used, as in the sample
the original poster provided ...

Check the samples below. None of them produce squiggly lines, even
though I am fairly positive that they cover both objects and value
types as return values. I see no difference in behavior due to
the choice of return types.
I believe the warning should at least be shown for those samples involving
reference types, regardless of whether or not they contain 'On Error GoTo'.
Interestingly the warning is shown for this snippet:

\\\
Public Function Foo() As Object
GoTo BailOut
Return 2
BailOut:
End Function
///
If you look at what the compiler turns the samples into, you will
see that something is explicitly returned on all code paths in all
samples.


In VB its granted that any function always returns a value on all code path,
but this is not necessarily done explicitly in the source code. So I don't
think that the decision whether or not to show the warning should be based
on the actual IL the compiler emits.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 3 '06 #22

P: n/a
>> see that something is explicitly returned on all code paths in all
samples.


In VB its granted that any function always returns a value on all code path,
but this is not necessarily done explicitly in the source code. So I don't
think that the decision whether or not to show the warning should be based
on the actual IL the compiler emits.


(last comment for tonight)

ok. I understand what you want.

But "On Error ..." is an abstraction that is turned into
something completely different (and much bigger).

I think what you are asking for would be extremely difficult
to implement - possibly basing the squiggly lines on something
different than what is being used by IntelliSense.

I am not qualified to speculate on how the
parser/compiler/IntelliSense
work their magic, so I'll leave this one alone.

/Joergen Bech

Jan 3 '06 #23

P: n/a
guy
Herfried, totally agree with your comments, i suppose what i was getting at
is that if you start relying on the warning you can be misled into thinking
you are returning a value when you are not exlpicitly doing it. i know
specifying a value type as the return value will always return a value, hut i
would have expected the warning when there is a code path that does not
***explicitly*** return a value.
seems to me this an 'intermittent' warning and can be misleading.

thanks guy

"Herfried K. Wagner [MVP]" wrote:
Ken,

"Ken Halter" <Ken_Halter@Use_Sparingly_Hotmail.com> schrieb:
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?

Errors:

End Function


I've read a few of these answers that state something along the lines of:
Just put a "CreateFolder = False" line after the "Errors:" label.


That should never be required. Since False is the default return value for
any boolean function/variable/whatever, explicitly setting the return =
False should never be required. If it is suddenly required after 30 years
of programming, there should be a huge notice posted on the web somewhere
that says "forget about your existing source code, everything has suddenly
changed for no good reason"


You could actually disable the warning. Simply open up the project file in
a text editor and add the warning number (42105) to the 'NoWarn' element.
My main concern is that the warning only occurs at functions which return a
reference type.

The full text of the warning makes this more clear: "[...] A null reference
exception could occur at run time when the result is used". I do not think
that implicitly returning 'Nothing' is a big problem. The main problem is
IMO forgetting to set a return value for a certain code path inside the
function. The same problem applies to BC42104 too. I have summed up my
thoughts on the usefulness of this warning in an article (in German):

Zur Sinnhaftigkeit der Compilerwarnung BC42104
<URL:http://dotnet.mvps.org/dotnet/articles/bc42104/>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 4 '06 #24

P: n/a
"guy" <gu*@discussions.microsoft.com> schrieb:
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?


Bug report:

<URL:http://lab.msdn.microsoft.com/ProductFeedback/viewFeedback.aspx?FeedbackId=e053a0fc-7d22-4c60-b596-a7b798a48100>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 4 '06 #25

P: n/a
guy
thanks Herfried

"Herfried K. Wagner [MVP]" wrote:
"guy" <gu*@discussions.microsoft.com> schrieb:
i have inherited the following migrated vb6 code (vb2005)
but i DONT get the "not all paths return a value" squiggly - is this a
'feature' of on error goto?


Bug report:

<URL:http://lab.msdn.microsoft.com/ProductFeedback/viewFeedback.aspx?FeedbackId=e053a0fc-7d22-4c60-b596-a7b798a48100>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jan 5 '06 #26

This discussion thread is closed

Replies have been disabled for this discussion.