Membership program Data delete

HI;
   I am currently doing a project on a membership data base, using pascal, as part of a higher education course.
Everything seems to work apart from the delete.
After entering members details I can delete them from the screen, but when
the program is switched off and turned back on again the deleted information is back in the lists. I suspect that when switching the program off the data is some how saved. I've noticed that when using delete the A:\ drive where the files stored, does not light up.

I'm using pointers, the delete is for membership and competition details ( two different files )

Have used the DISPOSE(.....) to delete, but I have not Assgined them to the 'A' DRIVE, DO I need to do this??

When using POINTERS, if so where ??
As I've said, the file gets removed from the screen while in use, but once the program is turned off it seems to read it back to the 'A' DRIVE. Therefore, when the program is restarted all the removed files are reinstated.
Therefore I would be grateful for some expert help, as I am complete beginner at programming.
Hope to hear from someone soon, best wishes,
        BLACKWOLF.....:)
BlackwolfAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Alisher_NCommented:
be sure that you do Close() on your files before exit from program !
0
bakry99Commented:
Hi
 How did you delete members details ?
You meen you delete a file by using  "Erase" mProcedure or what
 please more information..
  Bakry
0
Alisher_NCommented:
and more details or sources would help also ;-)
0
Why Diversity in Tech Matter

Kesha Williams, certified professional and software developer, explores the imbalance of diversity in the world of technology -- especially when it comes to hiring women. She showcases ways she's making a difference ithrough the Colors of STEM program.

BlackwolfAuthor Commented:
Edited text of question.
0
Alisher_NCommented:
hey man, you are really at the very beginning ;-)

file is a file, it is stored on disk and if you want to change or erase something from it you have to do it explicetly using procedures
open, read, write, blockread, blockwrite, close.... depending of your data and way you working with it

pointer is a variable in memory and not tied to file unless you store or retrive it's value to/from file...

listen, just give us your source and we will fix it, ok ? ;-))
full explanation will take few hours and it's better to get some good book and read.....

0
scrapdogCommented:
dispose doesn't delete anything, and it has nothing to do with the disk

dispose makes the program "forget" something...e.g., if you have a pointer that points to something (in MEMORY, of course), and you dispose of it, the info it pointed to is no longer usable by the program

there is absolutely no relation between this (memory pointers) and files

if you are a complete beginner at programming, my suggestion is just to forget you ever heard the word "pointer" for now...pointers are a confusing thing to grasp when you are first learning, and they can be dangerous (e.g. cause your system to hang) if used incorrectly
0
dbruntonQuid, Me Anxius Sum?Commented:
Generally when you delete a record from a file you do the following:

Find out how far into the original file the record is eg, the 7th record.
Create a new file.
Copy all prior records from original file to new file, in this case the first 6 records.
Increment the record counter in the original file, in this case 7th to 8th.
Copy the 8th record to end of file in the original file to the new file.
Close both files.
Delete original file.
Rename new file to original file name.
Reopen file.

0
bakry99Commented:
or you can delete a record Logicaly by make a boolean field in your file record
 eg "Life" if life is true then the record is active else it's deleted.
  bakry
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
dbruntonQuid, Me Anxius Sum?Commented:
bakry99

Buf file builds up in size and eventually you must do the procedure I have listed.  Some database programs do do what you have stated but even they have to clean out the dead wood eventually.
0
BlackwolfAuthor Commented:
Thank's
             bakry99, I've got it all working fine now.
The whole program ( about 5000 lines of code ) is working, just about finished. Just a few refinements to do.
               Thankyou for your help.
                         Blackwolf.....:)
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Pascal

From novice to tech pro — start learning today.