Delete a record?

Gasman

Enthusiastic Amateur
Local time
Today, 15:15
Joined
Sep 21, 2011
Messages
17,524
Hi all,
I have a form that is opened filtered to an ID passed from the calling form.
I have on this form the emulated split form as a subform for easy location of any record, but the subform is locked.

However I cannot delete a record in the main form for some reason.? The Delete option is disabled. the form is based on a table not a query. Even if I set Deletions to Yes in the subform, I still cannot delete in the main form.?

What do I need to do to be able to delete records from this form please.?
For now I have added a delete button, but curious as to why the Delete option is not available in the ribbon.

TIA
 
I never allow record deletions from anything other than a dedicated cmd button, with a confirmation.

In fact a lot of developers don't ever delete records period, just "retire them" gracefully, by setting an archived date or similar.
 
Still using that crap emulator. Its in the making. Even the author cannot find a solution to this emulator.
 
I never allow record deletions from anything other than a dedicated cmd button, with a confirmation.

In fact a lot of developers don't ever delete records period, just "retire them" gracefully, by setting an archived date or similar.

Hi Minty,
Yes I was thinking of that, it was just that this record was created by mistake. Need to rethink that part of the process.
 
Still using that crap emulator. Its in the making. Even the author cannot find a solution to this emulator.

Little unfair there Arne.
It suits my purposes very well. I do not use it for editing, that is what the main form is for, but for location of the record. Combined with a search textbox it works very well.
 
Still using that crap emulator. Its in the making. Even the author cannot find a solution to this emulator.

That was unusually rude of you arnel.
In fact there were several authors with you contributing a small part to one version which has been repeatedly credited as your idea.
Was that also 'crap' to use your own choice of words?
 
Hi Gasman

I have on this form the emulated split form as a subform for easy location of any record, but the subform is locked.

However I cannot delete a record in the main form for some reason.? The Delete option is disabled. the form is based on a table not a query. Even if I set Deletions to Yes in the subform, I still cannot delete in the main form.?

You didn't say which version you were using but from memory the subform was only locked in version 5

Just had another look at the later versions 10A (with subform) & 10S (based on Static's code)

Static's version 10S does have the main form set to allow deletions in the property sheet.
Version 10A was incorrectly set with main form 'Allow additions = No' and 'Allow Deletions = No'. Alter one or both as you wish.

Even so, as you say, delete remains disabled in the ribbon when you select a control in the main form.
However, click the drop down next to Delete and you will see Delete Record is enabled
I've checked & it does delete records in either version

attachment.php
 

Attachments

  • Capture.PNG
    Capture.PNG
    9.8 KB · Views: 271
Last edited:
Colin,

I am just using the method for the ESF. The two/three lines on form open and a locked subform. As mentioned that is all I need (at present) and I feel it works well. I've incorporated the same into my SSAFA database at home and it makes life so much easier. Previously I was using a FindFirst and that was a little clunky as on certain occasions it would stick on a record. This is a breeze to create and use.

I'll check the delete on Monday, as it was disabled I *thought* that I could not delete. Not aware if the dropdown is enabled or not, but will check on Monday.

Hi Gasman



You didn't say which version you were using but from memory the subform was only locked in version 5

Just had another look at the later versions 10A (with subform) & 10S (based on Static's code)

Static's version 10S does have the main form set to allow deletions in the property sheet.
Version 10A was incorrectly set with main form 'Allow additions = No' and 'Allow Deletions = No'. Alter one or both as you wish.

Even so, as you say, delete remains disabled in the ribbon when you select a control in the main form.
However, click the drop down next to Delete and you will see Delete Record is enabled
I've checked & it does delete records in either version

attachment.php
 

Users who are viewing this thread

Back
Top Bottom