"Header" is a reserved word?

Anything beyond the basics in using the LiveCode language. Share your handlers, functions and magic here.

Moderators: Klaus, FourthWorld, heatherlaine, kevinmiller, robinmiller

Post Reply
dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10517
Joined: Wed May 06, 2009 2:28 pm

"Header" is a reserved word?

Post by dunbarx »

It is for me. I thought, and suspiciously checked, that I could use it as a variable name. It is not in the dictionary.

Nope.

Craig
Emily-Elizabeth
Posts: 231
Joined: Mon Jan 03, 2022 7:10 pm
Contact:

Re: "Header" is a reserved word?

Post by Emily-Elizabeth »

Code: Select all

on MouseUp
   local Header
   put "moo" into Header
   put Header
end MouseUp
I get an error on the line "put Header" - Expression missing factor
bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 4220
Joined: Sun Jan 07, 2007 9:12 pm

Re: "Header" is a reserved word?

Post by bn »

Look for "put header" in the dictionary:
put header
Type command
Syntax
put [ new ] header header

Summary
Replaces or adds a CGI output header to the current list that is
generated the first time any data is output to stdout.
The fact that "header" is colorized in the script editor should be a hint.
Kind regards
Bernd
Post Reply