To "call" or not to "call"

Discussion in 'ASP General' started by William Morris, May 20, 2004.

  1. So, what's the prevailing opinion regarding the use of the "CALL" keyword?
    I'm working with a third-party ASP application, adapting for our system, and
    the CALL keyword is used everywhere. I've never used it, preferring instead
    to just type the procedure name and parameters so:

    myProcedure parm1, parm2

    Any thoughts on

    call myProcedure(parm1, parm2)

    ...?


    --
    William Morris
    Product Development, Seritas LLC
    Kansas City, Missouri
     
    William Morris, May 20, 2004
    #1
    1. Advertising

  2. It's just different syntax and allows you to use parens around your
    parameters, if you like that style. See http://www.aspfaq.com/2115

    You can see the impact on ByRef/ByVal in http://www.aspfaq.com/2488

    Neither is "better" IMHO, so I'm not sure what you're after.

    --
    Aaron Bertrand
    SQL Server MVP
    http://www.aspfaq.com/




    "William Morris" <> wrote in
    message news:...
    > So, what's the prevailing opinion regarding the use of the "CALL" keyword?
    > I'm working with a third-party ASP application, adapting for our system,

    and
    > the CALL keyword is used everywhere. I've never used it, preferring

    instead
    > to just type the procedure name and parameters so:
    >
    > myProcedure parm1, parm2
    >
    > Any thoughts on
    >
    > call myProcedure(parm1, parm2)
    >
    > ..?
    >
    >
    > --
    > William Morris
    > Product Development, Seritas LLC
    > Kansas City, Missouri
    >
    >
     
    Aaron Bertrand - MVP, May 20, 2004
    #2
    1. Advertising

  3. "Aaron Bertrand - MVP" <> wrote in message
    news:...
    > It's just different syntax and allows you to use parens around your
    > parameters, if you like that style. See http://www.aspfaq.com/2115
    >
    > You can see the impact on ByRef/ByVal in http://www.aspfaq.com/2488
    >
    > Neither is "better" IMHO, so I'm not sure what you're after.
    >
    > --
    > Aaron Bertrand
    > SQL Server MVP
    > http://www.aspfaq.com/


    Not really "after" anything much except opinions. Thanks, Aaron.


    --
    William Morris
    Product Development, Seritas LLC
    Kansas City, Missouri
     
    William Morris, May 20, 2004
    #3
  4. > Not really "after" anything much except opinions. Thanks, Aaron.

    Well, my point was that I don't know what you mean by "better"... faster,
    more accurate, less code, more common...
     
    Aaron Bertrand - MVP, May 20, 2004
    #4
  5. Hey hey hey...I didn't say "better." But, if I had to pose my question more
    specifically, I guess I was asking what's more common. If there just
    happened to be something about the way the parser handles it differently,
    I'd accept that too, but it was really just a request for opinions.


    "Aaron Bertrand - MVP" <> wrote in message
    news:...
    > > Not really "after" anything much except opinions. Thanks, Aaron.

    >
    > Well, my point was that I don't know what you mean by "better"... faster,
    > more accurate, less code, more common...
    >
    >
     
    William Morris, May 20, 2004
    #5
  6. William Morris

    Ray at Guest

    I always use Call subName. I like seeing Call, because it's much more
    obvious as to what's going on than just seeing some random work sitting
    there by itself. I also like to use parentheses.

    Call theThing(arg1, arg2)

    theThing arg1, arg2

    The former looks much better imo.

    Ray at work

    "William Morris" <> wrote in
    message news:...
    > Hey hey hey...I didn't say "better." But, if I had to pose my question

    more
    > specifically, I guess I was asking what's more common. If there just
    > happened to be something about the way the parser handles it differently,
    > I'd accept that too, but it was really just a request for opinions.
    >
    >
    > "Aaron Bertrand - MVP" <> wrote in message
    > news:...
    > > > Not really "after" anything much except opinions. Thanks, Aaron.

    > >
    > > Well, my point was that I don't know what you mean by "better"...

    faster,
    > > more accurate, less code, more common...
    > >
    > >

    >
    >
     
    Ray at, May 20, 2004
    #6
  7. William Morris

    Roland Hall Guest

    "William Morris" wrote in message news:...
    : So, what's the prevailing opinion regarding the use of the "CALL" keyword?
    : I'm working with a third-party ASP application, adapting for our system,
    and
    : the CALL keyword is used everywhere. I've never used it, preferring
    instead
    : to just type the procedure name and parameters so:
    :
    : myProcedure parm1, parm2
    :
    : Any thoughts on
    :
    : call myProcedure(parm1, parm2)
    :
    : ..?

    I never use call unless I'm on my cell phone or unless I'm replying in
    response to a NG post where someone has it in their code.

    --
    Roland Hall
    /* This information is distributed in the hope that it will be useful, but
    without any warranty; without even the implied warranty of merchantability
    or fitness for a particular purpose. */
    Technet Script Center - http://www.microsoft.com/technet/scriptcenter/
    WSH 5.6 Documentation - http://msdn.microsoft.com/downloads/list/webdev.asp
    MSDN Library - http://msdn.microsoft.com/library/default.asp
     
    Roland Hall, May 20, 2004
    #7
  8. William Morris wrote:
    > So, what's the prevailing opinion regarding the use of the "CALL"
    > keyword?


    I don't know about prevailing opinions, but I personally prefer it. It
    simply makes the code more readable, IMO.

    Then again, I use correct capitalization and parentheses for logic when I
    write VBScript, so I'm a bit of a kook.

    FWIW, microsoft.public.scripting.vbscript might represent a better barometer
    for this.


    --
    Dave Anderson

    Unsolicited commercial email will be read at a cost of $500 per message. Use
    of this email address implies consent to these terms. Please do not contact
    me directly or ask me to contact you directly for assistance. If your
    question is worth asking, it's worth posting.
     
    Dave Anderson, May 20, 2004
    #8
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. bill sandner
    Replies:
    1
    Views:
    903
    iksrazal
    Jul 1, 2004
  2. Buu Nguyen

    RMI: remote call or local call

    Buu Nguyen, Sep 9, 2004, in forum: Java
    Replies:
    5
    Views:
    818
    Esmond Pitt
    Sep 17, 2004
  3. hasho

    call by address vs. call by value

    hasho, Feb 10, 2004, in forum: C Programming
    Replies:
    35
    Views:
    3,107
    E. Robert Tisdale
    Feb 11, 2004
  4. Fabio Mastria
    Replies:
    4
    Views:
    752
    Fabio Mastria
    Jan 28, 2008
  5. Replies:
    5
    Views:
    1,654
    Roedy Green
    Jun 20, 2008
Loading...

Share This Page