I've always used DIMENSION a[] to declare an array but I've seen some developers use DECLARE a[]. Is there some subtle difference between te two statements?
Laurie
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html ---
Laurie, I have always (maybe incorrectly) used Dimension when I wanted to pre define the type of the array:
DIMENSION ArrayName1(nRows1 [, nColumns1]) [AS cType]
as opposed to declare which creates a non type defined array.
Dave
-----Original Message----- From: ProFox [mailto:profox-bounces@leafe.com] On Behalf Of Laurie Alvey Sent: 23 July 2017 18:08 To: ProFox Email List ProFox@leafe.com Subject: Array Declaration
I've always used DIMENSION a[] to declare an array but I've seen some developers use DECLARE a[]. Is there some subtle difference between te two statements?
Laurie
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html ---
[excessive quoting removed by server]
From the Help file
DECLARE is identical in operation and similar in syntax to the DIMENSION command. For more information, see DIMENSION Command.
And Local a[nRows, nCols] and Public a[nRows, nCols]
Also, all four methods can optionally take the clause AS Type OF ClassLib
-----Original Message----- From: ProfoxTech [mailto:profoxtech-bounces@leafe.com] On Behalf Of Dave Crozier Sent: 24 July 2017 08:32 To: profoxtech@leafe.com Subject: RE: Array Declaration
Laurie, I have always (maybe incorrectly) used Dimension when I wanted to pre define the type of the array:
DIMENSION ArrayName1(nRows1 [, nColumns1]) [AS cType]
as opposed to declare which creates a non type defined array.
Dave
-----Original Message----- From: ProFox [mailto:profox-bounces@leafe.com] On Behalf Of Laurie Alvey Sent: 23 July 2017 18:08 To: ProFox Email List ProFox@leafe.com Subject: Array Declaration
I've always used DIMENSION a[] to declare an array but I've seen some developers use DECLARE a[]. Is there some subtle difference between te two statements?
Laurie
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html ---
[excessive quoting removed by server]
Paul, Help file, help file.... we don't need no stinkin' help file!
That's cheating.
Dave
-----Original Message----- From: ProFox [mailto:profox-bounces@leafe.com] On Behalf Of Paul Newton Sent: 24 July 2017 08:38 To: profox@leafe.com Subject: RE: Array Declaration
From the Help file
DECLARE is identical in operation and similar in syntax to the DIMENSION command. For more information, see DIMENSION Command.
And Local a[nRows, nCols] and Public a[nRows, nCols]
Also, all four methods can optionally take the clause AS Type OF ClassLib
-----Original Message----- From: ProfoxTech [mailto:profoxtech-bounces@leafe.com] On Behalf Of Dave Crozier Sent: 24 July 2017 08:32 To: profoxtech@leafe.com Subject: RE: Array Declaration
Laurie, I have always (maybe incorrectly) used Dimension when I wanted to pre define the type of the array:
DIMENSION ArrayName1(nRows1 [, nColumns1]) [AS cType]
as opposed to declare which creates a non type defined array.
Dave
-----Original Message----- From: ProFox [mailto:profox-bounces@leafe.com] On Behalf Of Laurie Alvey Sent: 23 July 2017 18:08 To: ProFox Email List ProFox@leafe.com Subject: Array Declaration
I've always used DIMENSION a[] to declare an array but I've seen some developers use DECLARE a[]. Is there some subtle difference between te two statements?
Laurie
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html ---
[excessive quoting removed by server]
Excuse me What is rectifying this reaction?
Op ma 24 jul. 2017 om 09:39 schreef Dave Crozier DaveC@flexipol.co.uk
Paul, Help file, help file.... we don't need no stinkin' help file!
That's cheating.
Dave
-----Original Message----- From: ProFox [mailto:profox-bounces@leafe.com] On Behalf Of Paul Newton Sent: 24 July 2017 08:38 To: profox@leafe.com Subject: RE: Array Declaration
From the Help file
DECLARE is identical in operation and similar in syntax to the DIMENSION command. For more information, see DIMENSION Command.
And Local a[nRows, nCols] and Public a[nRows, nCols]
Also, all four methods can optionally take the clause AS Type OF ClassLib
-----Original Message----- From: ProfoxTech [mailto:profoxtech-bounces@leafe.com] On Behalf Of Dave Crozier Sent: 24 July 2017 08:32 To: profoxtech@leafe.com Subject: RE: Array Declaration
Laurie, I have always (maybe incorrectly) used Dimension when I wanted to pre define the type of the array:
DIMENSION ArrayName1(nRows1 [, nColumns1]) [AS cType]
as opposed to declare which creates a non type defined array.
Dave
-----Original Message----- From: ProFox [mailto:profox-bounces@leafe.com] On Behalf Of Laurie Alvey Sent: 23 July 2017 18:08 To: ProFox Email List ProFox@leafe.com Subject: Array Declaration
I've always used DIMENSION a[] to declare an array but I've seen some developers use DECLARE a[]. Is there some subtle difference between te two statements?
Laurie
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html
[excessive quoting removed by server]
I almost always use LOCAL myArray[] to scope the array locally. DECLARE/DIMENSION creates an array with a private scope. PUBLIC myArray[] is global, of course.
On Sun, Jul 23, 2017 at 1:07 PM, Laurie Alvey trukker41@gmail.com wrote:
I've always used DIMENSION a[] to declare an array but I've seen some developers use DECLARE a[]. Is there some subtle difference between te two statements?
Laurie
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html
[excessive quoting removed by server]
Thanks everyone. I use LOCAL ARRAY in procs, funcs and methods.
Laurie
On 24 July 2017 at 11:20, Ted Roche tedroche@gmail.com wrote:
I almost always use LOCAL myArray[] to scope the array locally. DECLARE/DIMENSION creates an array with a private scope. PUBLIC myArray[] is global, of course.
On Sun, Jul 23, 2017 at 1:07 PM, Laurie Alvey trukker41@gmail.com wrote:
I've always used DIMENSION a[] to declare an array but I've seen some developers use DECLARE a[]. Is there some subtle difference between te
two
statements?
Laurie
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html
[excessive quoting removed by server]
On 2017-07-24 06:20, Ted Roche wrote:
I almost always use LOCAL myArray[] to scope the array locally. DECLARE/DIMENSION creates an array with a private scope. PUBLIC myArray[] is global, of course.
Years ago I switched to LOCAL ARRAY MyArray[1] (...with the ARRAY keyword)
Great tip on the scope, Ted.