Hi all,
First time posting on here. I'm teaching myself FoxPro and giving myself little tasks to do so I've a better understanding on how VFP works, but unfortunately, I'm stuck on a problem.
I've got a DBF which is like a user list. There's a field listed as "Cardno" that contains a pin number per user. X amount of records have been Marked for deletion which means that the pin number can be given to someone else. I'm trying to generate a quick list of the pin numbers from the deleted records, so I can use the pin numbers again. Preferably, I'd like to view them in a message box.
The code I'm working on at the moment is shown below. It's clearly not giving me the result I'm after. Would anyone mind giving me a hand or a guide where I'm going wrong and what to do, so to speak?
Any help is appreciated.
Many thanks!
[[[[
cd\cashless
SET SAFETY ON
SET EXclusive ON
USE id
COUNT for DELETED() TO Pinlists
MESSAGEBOX("Deleted: " + ALLTRIM(STR(Pinlists,10,0)))
DIMENSION Pins(1,14)
COPY TO ARRAY Pins FIELDS Cardno FOR DELETED() = .T.
MESSAGEBOX("Pin List: " + ALLTRIM(STR(Pins,5,0))
]]]]
p.s. The square brackets are just to seperate the code from the post!
First time posting on here. I'm teaching myself FoxPro and giving myself little tasks to do so I've a better understanding on how VFP works, but unfortunately, I'm stuck on a problem.
I've got a DBF which is like a user list. There's a field listed as "Cardno" that contains a pin number per user. X amount of records have been Marked for deletion which means that the pin number can be given to someone else. I'm trying to generate a quick list of the pin numbers from the deleted records, so I can use the pin numbers again. Preferably, I'd like to view them in a message box.
The code I'm working on at the moment is shown below. It's clearly not giving me the result I'm after. Would anyone mind giving me a hand or a guide where I'm going wrong and what to do, so to speak?
Any help is appreciated.
Many thanks!
[[[[
cd\cashless
SET SAFETY ON
SET EXclusive ON
USE id
COUNT for DELETED() TO Pinlists
MESSAGEBOX("Deleted: " + ALLTRIM(STR(Pinlists,10,0)))
DIMENSION Pins(1,14)
COPY TO ARRAY Pins FIELDS Cardno FOR DELETED() = .T.
MESSAGEBOX("Pin List: " + ALLTRIM(STR(Pins,5,0))
]]]]
p.s. The square brackets are just to seperate the code from the post!