Hi
How can I make a copy of a record in the same table via code? Is there a
feature like whole record copy & paste?
Thanks
Regards 2 1820
Umm... create a select query that grabs the record you want. Probably
point it to the open form.
Turn that into an append query so that it appends to the same table
that it's looking at.
In your form, bookmark your record (if you want to return to it), shut
off your warnings, run query, then turn warnings on again, and return
to bookmark. (or you could go to the last record...)
Sorry. Access != Excel.
Can I do it without any reference to specific fields, as the fields can
change and I don't want to remember to come back and change the insert query
every time?
Thanks
Regards
<pi********@hot mail.com> wrote in message
news:11******** **************@ g14g2000cwa.goo glegroups.com.. . Umm... create a select query that grabs the record you want. Probably point it to the open form. Turn that into an append query so that it appends to the same table that it's looking at. In your form, bookmark your record (if you want to return to it), shut off your warnings, run query, then turn warnings on again, and return to bookmark. (or you could go to the last record...)
Sorry. Access != Excel. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: pwys |
last post by:
Hello to everyone
WOndering if there anyone could help me with this.
I have a Primary & a secondary table with the unique key (InvoiceNo)
Waht i want is to make duplicate copy of a selected invoice no (both Primary
& secondary) into a new invoice no.
can some one help me in this?
|
by: Robin S. |
last post by:
**Eric and Salad - thank you both for the polite kick in the butt. I hope
I've done a better job of explaining myself below.
I am trying to produce a form to add products to a table (new products).
Tables:
tblCategoryDetails
CategoryID
SpecID
|
by: Josetta |
last post by:
I have found a wealth of information here on how to duplicate records
in forms with subforms.
I have adapted code found here to work with my forms. It works
beautifully the first time I hit the "duplicate" button. It copies the
main form data, the subform data and moves to the new record. Great!
Here's the problem...if I move to another record (or stay on the newly
created record, for that matter), and hit the Duplicate button...
|
by: mavmavv |
last post by:
I have a Form where I have created a duplicate record button, no
problem...
The subform is where my problem lies. The subform displays data
matching the mainform's ID, these two values are linked. The subform
has no primary key, since there are multiple matching entries.
Basically the mainform displays Customer info + order totals, and the
subform displays the products.
When I goto duplicate the record, the ID from the duplicated...
|
by: jpatchak |
last post by:
Hello All,
I am trying to code a command button on a form to create a duplicate record and renumber it. The code I have in the command button currently is;
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 2, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 5, , acMenuVer70 'Paste Append
NumberNewRecord
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, ,...
| |
by: samdev |
last post by:
I have used the wizard to create a Duplicate Record command button on a
form. It works fine for a single duplicate but if I want to duplicate
an additional record I receive an error:
"The command or action 'Paste Append' is not available right now."
I have to close out of the form and reopen to get the button to work
again. A bit of a nuisance.
Any suggestions.
|
by: Kanashii |
last post by:
First off - I want to thank all who respond / try to help out and even those who took a moment to read over my question.
Please be patient as I am -very- new to VB in general and unfortunately I've only had the chance to pick up pieces here-and-there. So keep that in mind when reading my inquiry as I am liable to misuse terminology.
My question, although lengthy, is likely quite basic but I can't seem to find a solution and yes I have...
|
by: kkiger |
last post by:
My problem is this, I can set up a command button to duplicate a record everytime I click on it. What happens is that I get a record but it will be at the end of the table. For example, if I am on record 5 of 10 records and I click on my button I get a new record as number 11, I want the record to be number 6, inserted after the record I click on. I need to have the records in order because the next step is to generate a new number for the...
|
by: ladybug76 |
last post by:
Hi.
I'm working on a database and I though I tinker with Macros and VB, I am not very versed in them. So ANY help would be HUGELY appreciated!!!
(I'm using Access 2003)
What I need to do is, from a form I've created, I need to add a button so the end user can duplicate the record they are viewing, then update either the original or the duplicate record's field from its current value of "Active" to "Inactive".
So, the end...
|
by: Barno77 |
last post by:
Everytime I edit a record, and hit update I get duplicating lines in my Details View. Here's my If statement:
If (Len(e.OldValues("AutoNumber")) > 0) Then
sql = "UPDATE SHIP_LOG SET FileNumber='" & e.NewValues("FileNumber") & "',BOL='" & e.NewValues("BOL") & "',Container='" & e.NewValues("Container") & "',DESTN='" & e.NewValues("DESTN") & "', Comments='" & e.NewValues("Comments") & "' WHERE POD_COMINV='" & e.Keys("POD_COMINV") &...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
| |
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...
|
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...
|
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...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
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...
| |
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |