Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

copy to array fills it with .f.s if qualified 1

Status
Not open for further replies.

arielap

Technical User
Aug 2, 2003
71
GB
This is part of a security maintenance function which works by restoring a list of people from a MEM file into a cursor which the section head can edit.
Clicking 'Save & Exit' from the form with the editable cursor (in a grid) copies the cursor data to an array, which is then saved to the original .MEM

Problem -: simply issuing a 'copy to array pws' is OK but
'copy to array pws for <anything>' results in an array with the correct structure but all fields '.F.'

The same happens if a record in the cursor is deleted and I try 'copy ... for deleted(), or copy with deleted ON.
 
>>has got nothing to do with SET COMPATIBLE.<<
So I've discovered :)
Perhaps I should have looked at the Help before assuming that 'DBASE compatibility' was meant to ensure that bits of procedural code from the DOS version (like the standalone password section that started this thread) would work without problems in VFP.

>> You (or someone) probably went to Tools / Options /<<

Yes that's exactly what happened. Anyway, now corrected (I'd forgotten to SET as default when I unticked it).
 
>> you saved it as ON at some point <<

Yes, having assumed (not unnaturally) that 'DBASE compatibility' meant I'd avoid any problems like this with FoxDOS code.

and having corrected it, forgot to click Options' Set as default :(

Many thanks again for providing the solution
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top