473,714 Members | 2,264 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Delete record

Sorry to repost, but am having another look at deleting a record.

I have a form (Member) and have removed all the event procedures associated
with the Form (OnCurrent, OnDelete, OnActivate etc)
When I click on the record bar and press delete it comes up with the correct
message "You are about to delete 1 record ....", the record count drops by 1
and I say "Yes - delete it". Seems OK, record is no longer there.
Than after closing the form and re-opening the record is back and the record
count back to the original number.

Any Ideas?

Thanks

Phil
Apr 25 '07 #1
4 4402
On Apr 25, 5:27 pm, "Phil Stanton" <p...@stantonfa mily.co.ukwrote :
Sorry to repost, but am having another look at deleting a record.

I have a form (Member) and have removed all the event procedures associated
with the Form (OnCurrent, OnDelete, OnActivate etc)
When I click on the record bar and press delete it comes up with the correct
message "You are about to delete 1 record ....", the record count drops by 1
and I say "Yes - delete it". Seems OK, record is no longer there.
Than after closing the form and re-opening the record is back and the record
count back to the original number.

Any Ideas?

Thanks

Phil
Just ideas...
Is there anything in BeforeUpdate, or anything that could possibly
cancel an update in another event or sub? Is the Forms Allow Deletes/
Updates etc. set to true? Do you know that the recordset or underlying
table is not in a read-only state?
Apr 26 '07 #2
It sounds like you intend to allow the deletion, but in fact you are
CANCELing the deletion. Make sure that the value associated with your
'Yes - delete it' button is equal to the vbCancel (object browser)
value.

King Ron of Chi
On Apr 25, 4:27 pm, "Phil Stanton" <p...@stantonfa mily.co.ukwrote :
Sorry to repost, but am having another look at deleting a record.

I have a form (Member) and have removed all the event procedures associated
with the Form (OnCurrent, OnDelete, OnActivate etc)
When I click on the record bar and press delete it comes up with the correct
message "You are about to delete 1 record ....", the record count drops by 1
and I say "Yes - delete it". Seems OK, record is no longer there.
Than after closing the form and re-opening the record is back and the record
count back to the original number.

Any Ideas?

Thanks

Phil

Apr 26 '07 #3
Thanks for thoughts

As I said, have temporarily removed all Form events (but not Control events)
Form is set to allow additions and deletions and as I can amend the record,
I ssume that the tables are not read-only. There is no problem if I go to
the table and delete the record even after deleting it (or more accurately,
failing to delete using the form).

Have had a thought and have tried deleting the record from the query on
which the form is based. Again it appears to delete OK, but close the query
and re-open it, and there is the record again. That eliminates any problem
with the form.

Thanks

Phil

"storrboy" <st******@sympa tico.cawrote in message
news:11******** **************@ t39g2000prd.goo glegroups.com.. .
On Apr 25, 5:27 pm, "Phil Stanton" <p...@stantonfa mily.co.ukwrote :
>Sorry to repost, but am having another look at deleting a record.

I have a form (Member) and have removed all the event procedures
associated
with the Form (OnCurrent, OnDelete, OnActivate etc)
When I click on the record bar and press delete it comes up with the
correct
message "You are about to delete 1 record ....", the record count drops
by 1
and I say "Yes - delete it". Seems OK, record is no longer there.
Than after closing the form and re-opening the record is back and the
record
count back to the original number.

Any Ideas?

Thanks

Phil

Just ideas...
Is there anything in BeforeUpdate, or anything that could possibly
cancel an update in another event or sub? Is the Forms Allow Deletes/
Updates etc. set to true? Do you know that the recordset or underlying
table is not in a read-only state?


Apr 26 '07 #4
Thanks for coming back

Have had a thought and have tried deleting the record from the query on
which the form is based. Again it appears to delete OK, but close the query
and re-open it, and there is the record again. That eliminates any problem
with the form.

Just in case the standard delete message box has become corrupted, If I
press "Yes", the record count stays at the lower value; if I press "No", the
recordcount goes up by 1 to the original value.

Thanks

Phil
"King Ron" <Ki************ ***@covad.netwr ote in message
news:11******** **************@ r30g2000prh.goo glegroups.com.. .
It sounds like you intend to allow the deletion, but in fact you are
CANCELing the deletion. Make sure that the value associated with your
'Yes - delete it' button is equal to the vbCancel (object browser)
value.

King Ron of Chi
On Apr 25, 4:27 pm, "Phil Stanton" <p...@stantonfa mily.co.ukwrote :
>Sorry to repost, but am having another look at deleting a record.

I have a form (Member) and have removed all the event procedures
associated
with the Form (OnCurrent, OnDelete, OnActivate etc)
When I click on the record bar and press delete it comes up with the
correct
message "You are about to delete 1 record ....", the record count drops
by 1
and I say "Yes - delete it". Seems OK, record is no longer there.
Than after closing the form and re-opening the record is back and the
record
count back to the original number.

Any Ideas?

Thanks

Phil


Apr 26 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
4456
by: Someonekicked | last post by:
I have a binary file, and I need to delete a specific number of characters in it. The file contains records, each record has a specific length. So the way I wanna handle deleting is that I will overwrite the record I want to delete with the last record in the file, then actually delete that last record in the file. the problem Im having is how to delete that last record in the file. Suppose each record is of length 43, then I have...
9
10659
by: Robert Schneider | last post by:
Hi to all, I don't understand that: I try to delete a record via JDBC. But I always get the error SQL7008 with the error code 3. It seems that this has something to do with journaling, since the table from which I want to delete has two foreign keys that references two other tables and it is also referenced by another table. But this shouldn't be a problem, since I set the commit mode to none (or *none) at all places where this makes...
8
4064
by: Steve | last post by:
I have several pairs of synchronized subforms in an application. I have a Delete button for each pair that uses the following code or similar to delete a record in the second subform: DoCmd.SetWarnings False DoCmd.RunCommand acCmdDeleteRecord DoCmd.SetWarnings True End If ExitHere: Me!SubName.SetFocus
3
3970
by: Uwe Range | last post by:
Hi to all, I am displaying a list of records in a subform which is embedded in a popup main form (in order to ensure that users close the form when leaving it). It seems to be impossible to delete a record in this subform. When I switched modal off and tried to delete a record from the list, I deleted a record on another form (below the popup form).
3
7822
by: Maria | last post by:
Is there another way to delete the current record in a subform from the main form, another subform or a sub-subform other than setting focus on a field in the subform and using run command acCmdDelete Record? Thanks! Maria
4
7849
by: Susan Bricker | last post by:
I have a command button on a form that is supposed to Delete the record being displayed. The record is displayed one to a form. The form is not a Pop-Up nor is it Modal. Tracing the btnDelete event routine shows that AllowDeletions is TRUE. When the Delete button is clicked (without TRACE ON), I get a 'beep', the recordselector (vertical bar on left of form) gets dark in color, but the record is not deleted. Also, there is no error...
5
4143
by: Bob Bridges | last post by:
Start with two tables, parent records in one and child records in the other, a one-to-many relationship. Create a select statement joining the two. Display the query in datasheet mode. When I delete a row, only the child record is deleted from the source tables; the parent record is still there...which is what I wanted. Now display fields from that query in a continuous form. When I delete a record from that form, one of the child...
4
2581
by: Craggy | last post by:
Hi, I am trying to pop up a yes/no message box so that a user can delete a record in a continuous form. The default delete message is a bit sloppy because it seems to move the continuous form to the position of the record u want to delete. If you then choose to not to delete the record it looks to a user as if it has deleted every record before the one you chose not to delete. To get around this I made a yes/no msgbox pop up and only after...
5
3940
by: sh26 | last post by:
I can Add and Delete (A, CName, MX and TXT) Dns records on the Dns Server using C# code. The problem I am having is if someone manaully creates a TXT record on the Dns Server, I cannot delete that particular record using the same C# code. Here is what I am using to delete the records: public void DeleteRecord(string domain, string recordName, string recordType, string recordData) { try { ...
10
7165
beacon
by: beacon | last post by:
Hi everybody, This is probably going to sound unorthodox, but I have to log records that are deleted...I know, go figure. Anyway, I have a form with a (continuous) subform, and on the subform I have a command button, called cmdDelete, that launches a dialog form, called frmDeleteCurrentRecord, where the user has to enter their name and a reason. I have managed, through a ton of trial and tribulation, found a way to delete the current...
0
8712
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9316
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9177
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9077
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9021
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6637
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4465
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
2524
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2113
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.