error 3067 (Opening parenthesis missing) on some code which looks correct ...

Started by mraskin, November 12, 2014, 10:08:26 AM

Previous topic - Next topic

mraskin

Hi,

this is with Winbatch 2000c, running in a Windows 7 environment.

At a first glance the error message I am getting is pretty neat :

   3067: Function Syntax : Opening parenthesis missing

the problem is that I cannot see what is wrong in my code. I somehow cut&paste from the fileread example from the Winbatch documentation.

here is an excerpt :

if FileExist(".failed") == @TRUE then
  fi = FileOpen(".failed", "READ")
  message = fileread(fi)
  display(2,'error','%message%')
...
endif

the error message is pointing at the fileread line .

thanks for your help,
M. Raskin.

JTaylor

Message is a function name and can't be used as a variable.   It is complaining because it is expecting parenthesis and parameters for the  message() function.

Jim

mraskin

Indeed!!!

thanks, I did not notice this  :(.
Very good  :) and sorry for this rather basic question but I was wrongly focusing on the fileread function ...

M. Raskin.