Thursday, July 30, 2009

The reason for the error this time is that when the VB 6

The reason for the error this time is that when the VB 6 code was pasted into VB.NET, Intellisense corrected another "error" and added the VB.NET default, ByVal. This doesn't allow the actual value of the argument to be changed, only the copy made for the subroutine. If this is changed to ByRef in the VB.NET program, all is well again. This is one thing the Upgrade Wizard does right, by the way. It's changed to ByRef automatically when the Wizard is run.

No comments:

Post a Comment