Basically, I'm wanting to delete a record from an array, I have attempted it but don't think it is the right/proper way. I attached all the java files for anyone in a zip at http://www.guff.org/java.zip [9K] (well commented) - sorry i couldn't paste a snippet of the code, it's just i'm using 3 different classes
...also when you delete the record, let's say record 3 out of a number of 5 records or something, it deletes 3 and keeps 1, 2, 4, 5 instead of moving the list down to 1, 2, 3, 4. see what I mean?
What I'm doing is a printer queue demo, and would really really be grateful if anyone could give me a hand.. preferably edit the one I've got in the zip (to fix it up etc) or show me some code on this.
::post a reply or email me::, which ever you feel best.
What you need to do is create a new array from the old one by adding all elements except the one you are deleting. The new array would be one less in size. Then reassign the new array to the old reference.