Re: Call to subroutine fails to execute - no error or warning

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



FWIW, one could use the Call statement in relation to a Subroutine as
indicated in the VB help files. Why one would do this I have no idea
(expect perhaps if one was obsessed with keeping arguments in parenthesis)
but it is possible.

I did find it interesting however, and I did not know this, that ByVal and
ByRef when used in conjunction with the Call statement can be used only when
calling a DLL procedure. From the VB6 help file:

argumentlist
Optional. Comma-delimited list of variables, arrays, or expressions to pass
to the procedure. Components of argumentlist may include the keywords ByVal
or ByRef to describe how the arguments are treated by the called procedure.
However, ByVal and ByRef can be used with Call only when calling a DLL
procedure.

- Kev

"Jeff Johnson" <i.get@xxxxxxxxxxx> wrote in message
news:uhMy$f2gHHA.4704@xxxxxxxxxxxxxxxxxxxxxxx
| "Kevin Provance" <casey@xxxxxxxxxxx> wrote in message
| news:OFCxjs1gHHA.208@xxxxxxxxxxxxxxxxxxxxxxx
|
| > | . . . you are going to call it with code such as this:
| > |
| > | call mysub (j as string, k as string)
| > |
| > | ?
|
| > No. You're right, that was my bad. My apologies.
|
| Whew! I thought that was something really obscure about VB I didn't know!
|
|


.



Relevant Pages

  • Re: PowerCobol
    ... I can make thi: ... I want to do the same, but calling "text.chm" for help files and ... Regards ...
    (comp.lang.cobol)
  • Re: PowerCobol
    ... > Thanks Frederico, ... > I can make thi: ... > I want to do the same, but calling "text.chm" for help files and ...
    (comp.lang.cobol)
  • figure position
    ... grid; hold on; plot; ... don't "overwrite" each other (suppose I'm calling 4 of them). ... with the help of help files: ...
    (comp.soft-sys.matlab)