Must a numeric array be initialized?

Must a numeric array be initialized?

Post by David Church » Fri, 18 Mar 1994 23:57:04




>In Foxpro 2.0 (DOS), is the default initialization always a character? I can't
>seemed to store any values in an uninitialized array. That's why before I
>use the array, I need to initialize it beforehand using a "for" loop and
>plugging zeros in each subscript. Any feedback on this?

 The default initialization is always a logical (.F.). You can set the
whole array to zero with

 arrayname = 0

 but you shouldn't have to do this; you can store values in an
"uninitialized" array. Could you explain the problem a bit more?

 Dave.
---

 
 
 

1. Must a numeric array be initialized?

: In Foxpro 2.0 (DOS), is the default initialization always a character? I can't
: seemed to store any values in an uninitialized array. That's why before I
: use the array, I need to initialize it beforehand using a "for" loop and
: plugging zeros in each subscript. Any feedback on this?

Check out "SET COMPATIBLE".  If you set it correctly, you can use the
single command  "STORE 0 TO <arrayname>" to initialize ALL elements.

--
David


2. Can publish to VFP ?

3. INITIALIZE DEVICE- -What am I missing???

4. C Callouts

5. What initialize file am I using

6. Query a product where 100's of attributes are null

7. How to initialize an array in PL/SQL?

8. ADO & FoxPro

9. CLOB-array element initializing

10. Initialize Array Of Numbers

11. I am confused as to whether I should use numeric IDs or not

12. Initializing an array!

13. Storing very large numeric arrays in the database (OLE OBJECT Data Type)