Novell Home

TID101050 (INTB01) - NetBasic error

From Developer Community

In NetBasic, if you define a macro which requires a parameter, and you place that macro name in a comment, you will receive the error:

malformed parameter list


DETAILED DESCRIPTION

INTRODUCTION: When scripting in NetBasic, you have the ability to create Macros which take parameters as such:

  1. define MYMACRO(x) "This is my "+x

which when called will concat. the parameter onto the string "This is my "

ie. The statement:

Print(MYMACRO("country"))

will print "This is my country"


PROBLEM: If you place the macro name "MYMACRO" anywhere in a comment, your script will not run, terminating with the error:

PreProcessor: Souce File=xxx Line [n][n] malformed parameter list

The two execeptions to this are: 1 - You actually get the syntax correct in the comment, ie. ' I run MYMACRO("HI") 2 - The case differs (it is case sensitive)

Note: This is only a problem with macros which take parameters. Non-parameter macros are not a problem because the preprocessor doesn't need anything more to process them.

intb01.exe

intb01.exe19.1 K2005-04-06

--Benjamin Fjeldsted

Novell® Making IT Work As One

© 2008 Novell, Inc. All Rights Reserved.