473,660 Members | 2,459 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

opening an other database from a form

Read this from Dev Ashish
http://www.mvps.org/accessfr/forms/frm0034.htm
for opening a form in an other db
This seems useful for my job
I've a db named INVOICING making invoice and a 2nd db name
Mini_D_ASDEV checking debit/payment, without relation between them
Then,
1st : is this /frm0034.htm working with Access 2002 under XP as well?
2nd :
my form OPENED is INVOICE from db INVOICING
the database I want to OPEN is "Mini_D_ASDEV.m bd and
the path is D:\1_Database_D evlt
the form in this db I want to open is 002_CREDIT
The fields I want to transfer from INVOICE form To 002_CREDIT form are
:
LASTNAME > CREDNAME
INVOICEDATE > DATCHECK
INVOICEID > SERVICE
CURRENCY > CURR
AMOUNT > CREDRQST_US
3rd : I would use a button click to transfer
4th : as transferred I would the field "Transferre d" from INVOICING db
set to Yes

What I should write as code for these informations ?
Where I should insert this code in the Dev Ashih application ?
Nov 12 '05 #1
3 2561
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

It seems what you really want to do is transfer data from one db to
another. You can do this with an append query. E.g.:

INSERT INTO OtherTableName In "d:\1_Database_ Devlt\Mini_D_AS DEV.mbd"
(CREDNAME, DATCHECK, SERVICE, CURR, CREDRQST_US)
SELECT LASTNAME, INVOICEDATE, INVOICEID, CURRENCY, AMOUNT
FROM LocalTableName
WHERE ... < your criteria > ...

Or, using VBA in a form:

==
dim strSQL as string
strSQL = "INSERT INTO OtherTableName In " & _
""d:\1_Database _Devlt\Mini_D_A SDEV.mbd"" (CREDNAME, " & _
"DATCHECK, SERVICE, CURR, CREDRQST_US) " & _
"VALUES (" & Me!LASTNAME & ", " & _
Me!INVOICEDATE & ", " & _
Me!INVOICEID & ", " & _
Me!CURRENCY & ", " & _
Me!AMOUNT & ")"

CurrentDB.Execu te strSQL, dbFailOnError
==

Change the table names to suit your table names.

See the Access Help articles on the "In Clause" and the "INSERT INTO
Statement."

- --
MGFoster:::mgf
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBP7qE3YechKq OuFEgEQKU2gCg1u VW/XPSEe+jjTwnTHuf C3EJSu4AoKsc
jTHaThfmYX1Dokg 8nKohCVU0
=NCNe
-----END PGP SIGNATURE-----

tomyboy wrote:
Read this from Dev Ashish
http://www.mvps.org/accessfr/forms/frm0034.htm
for opening a form in an other db
This seems useful for my job
I've a db named INVOICING making invoice and a 2nd db name
Mini_D_ASDEV checking debit/payment, without relation between them
Then,
1st : is this /frm0034.htm working with Access 2002 under XP as well?
2nd :
my form OPENED is INVOICE from db INVOICING
the database I want to OPEN is "Mini_D_ASDEV.m bd and
the path is D:\1_Database_D evlt
the form in this db I want to open is 002_CREDIT
The fields I want to transfer from INVOICE form To 002_CREDIT form are
:
LASTNAME > CREDNAME
INVOICEDATE > DATCHECK
INVOICEID > SERVICE
CURRENCY > CURR
AMOUNT > CREDRQST_US
3rd : I would use a button click to transfer
4th : as transferred I would the field "Transferre d" from INVOICING db
set to Yes

What I should write as code for these informations ?
Where I should insert this code in the Dev Ashih application ?

Nov 12 '05 #2
Hi MGF
1st Thks and hello from Switzerland/Geneva

Reg. my problem
Not only the transfer of value, but I also want this 2nd form
(002_CREDIT) opened after transfer as there are 15 others fields to be
updated manually. The cycle should be : creating an invoice in INVOICE
form, click a button to open 002_CREDIT and transfer the 5 fields,
close INVOICE form, complete the fields of 002_CREDIT manually and
close it.
Keeping in mind that both db have no connections (I'd too many
problems with our servers when backing up in the past and these db are
shared without replicas-I know that's a fragile application but it's
works properly !)
BUT I don't know VBA and my age doesn't push me to learn it. That's
why I take ideas from various english/french MVP's. Anyway many thks
for your coop.Rgds Michel


MGFoster <me@privacy.com > wrote in message news:<xx******* **********@news read2.news.pas. earthlink.net>. ..
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

It seems what you really want to do is transfer data from one db to
another. You can do this with an append query. E.g.:

INSERT INTO OtherTableName In "d:\1_Database_ Devlt\Mini_D_AS DEV.mbd"
(CREDNAME, DATCHECK, SERVICE, CURR, CREDRQST_US)
SELECT LASTNAME, INVOICEDATE, INVOICEID, CURRENCY, AMOUNT
FROM LocalTableName
WHERE ... < your criteria > ...

Or, using VBA in a form:

==
dim strSQL as string
strSQL = "INSERT INTO OtherTableName In " & _
""d:\1_Database _Devlt\Mini_D_A SDEV.mbd"" (CREDNAME, " & _
"DATCHECK, SERVICE, CURR, CREDRQST_US) " & _
"VALUES (" & Me!LASTNAME & ", " & _
Me!INVOICEDATE & ", " & _
Me!INVOICEID & ", " & _
Me!CURRENCY & ", " & _
Me!AMOUNT & ")"

CurrentDB.Execu te strSQL, dbFailOnError
==

Change the table names to suit your table names.

See the Access Help articles on the "In Clause" and the "INSERT INTO
Statement."

- --
MGFoster:::mgf
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBP7qE3YechKq OuFEgEQKU2gCg1u VW/XPSEe+jjTwnTHuf C3EJSu4AoKsc
jTHaThfmYX1Dokg 8nKohCVU0
=NCNe
-----END PGP SIGNATURE-----

tomyboy wrote:
Read this from Dev Ashish
http://www.mvps.org/accessfr/forms/frm0034.htm
for opening a form in an other db
This seems useful for my job
I've a db named INVOICING making invoice and a 2nd db name
Mini_D_ASDEV checking debit/payment, without relation between them
Then,
1st : is this /frm0034.htm working with Access 2002 under XP as well?
2nd :
my form OPENED is INVOICE from db INVOICING
the database I want to OPEN is "Mini_D_ASDEV.m bd and
the path is D:\1_Database_D evlt
the form in this db I want to open is 002_CREDIT
The fields I want to transfer from INVOICE form To 002_CREDIT form are
:
LASTNAME > CREDNAME
INVOICEDATE > DATCHECK
INVOICEID > SERVICE
CURRENCY > CURR
AMOUNT > CREDRQST_US
3rd : I would use a button click to transfer
4th : as transferred I would the field "Transferre d" from INVOICING db
set to Yes

What I should write as code for these informations ?
Where I should insert this code in the Dev Ashih application ?

Nov 12 '05 #3
Hi MGF
1st Thks and hello from Switzerland/Geneva

Reg. my problem
Not only the transfer of value, but I also want this 2nd form
(002_CREDIT) opened after transfer as there are 15 others fields to be
updated manually. The cycle should be : creating an invoice in INVOICE
form, click a button to open 002_CREDIT and transfer the 5 fields,
close INVOICE form, complete the fields of 002_CREDIT manually and
close it.
Keeping in mind that both db have no connections (I'd too many
problems with our servers when backing up in the past and these db are
shared without replicas-I know that's a fragile application but it's
works properly !)
BUT I don't know VBA and my age doesn't push me to learn it. That's
why I take ideas from various english/french MVP's. Anyway many thks
for your coop.Rgds Michel


MGFoster <me@privacy.com > wrote in message news:<xx******* **********@news read2.news.pas. earthlink.net>. ..
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

It seems what you really want to do is transfer data from one db to
another. You can do this with an append query. E.g.:

INSERT INTO OtherTableName In "d:\1_Database_ Devlt\Mini_D_AS DEV.mbd"
(CREDNAME, DATCHECK, SERVICE, CURR, CREDRQST_US)
SELECT LASTNAME, INVOICEDATE, INVOICEID, CURRENCY, AMOUNT
FROM LocalTableName
WHERE ... < your criteria > ...

Or, using VBA in a form:

==
dim strSQL as string
strSQL = "INSERT INTO OtherTableName In " & _
""d:\1_Database _Devlt\Mini_D_A SDEV.mbd"" (CREDNAME, " & _
"DATCHECK, SERVICE, CURR, CREDRQST_US) " & _
"VALUES (" & Me!LASTNAME & ", " & _
Me!INVOICEDATE & ", " & _
Me!INVOICEID & ", " & _
Me!CURRENCY & ", " & _
Me!AMOUNT & ")"

CurrentDB.Execu te strSQL, dbFailOnError
==

Change the table names to suit your table names.

See the Access Help articles on the "In Clause" and the "INSERT INTO
Statement."

- --
MGFoster:::mgf
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBP7qE3YechKq OuFEgEQKU2gCg1u VW/XPSEe+jjTwnTHuf C3EJSu4AoKsc
jTHaThfmYX1Dokg 8nKohCVU0
=NCNe
-----END PGP SIGNATURE-----

tomyboy wrote:
Read this from Dev Ashish
http://www.mvps.org/accessfr/forms/frm0034.htm
for opening a form in an other db
This seems useful for my job
I've a db named INVOICING making invoice and a 2nd db name
Mini_D_ASDEV checking debit/payment, without relation between them
Then,
1st : is this /frm0034.htm working with Access 2002 under XP as well?
2nd :
my form OPENED is INVOICE from db INVOICING
the database I want to OPEN is "Mini_D_ASDEV.m bd and
the path is D:\1_Database_D evlt
the form in this db I want to open is 002_CREDIT
The fields I want to transfer from INVOICE form To 002_CREDIT form are
:
LASTNAME > CREDNAME
INVOICEDATE > DATCHECK
INVOICEID > SERVICE
CURRENCY > CURR
AMOUNT > CREDRQST_US
3rd : I would use a button click to transfer
4th : as transferred I would the field "Transferre d" from INVOICING db
set to Yes

What I should write as code for these informations ?
Where I should insert this code in the Dev Ashih application ?

Nov 12 '05 #4

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

Similar topics

4
1930
by: Niranjan | last post by:
I have an Access XP split application operating on Windows XP. I have a form that opens on Startup that opens the backend database and keeps it open until the application is closed. For the first user to open the application it takes about 30-40 secs which is acceptable. But for the 2nd user onwards it takes about 1.5 - 2 minutes which is not acceptable. What can I do to open the application faster for the second user onwards. I have...
2
19076
by: Ray | last post by:
Stop me if you've heard this, but I am running Access 2002 and all of a sudden, if I design a particular form (it's been working fine for ages), Access crashes rather than open it in design view. Interestingly, it doesn't crash if I run the app and open it in form view! Just if I attempt to design it. If I compact/repair, it allows me to design the form once. On any subsequent attempts to view in design mode, though, it crashes before...
5
1996
by: Andy P via AccessMonster.com | last post by:
I am responsible for maintaining our departmental intranet pages at work. I would like to put a link from our website to a MS Access database which is held on our Network drive. The problem I have is that if Access has the startup properties set to display a form, MS Access doesn't start (it appears in the processes window in task manager but not in applications). If I change the startup properties so that no form is opened and the...
3
2121
by: Rolan | last post by:
I need assistance regarding code needed to prevent someone from opening a form if a table field name(s) has been changed. For example, there is existing code to check for certain data based on DLookup in a table before a form can be opened. If one changes the field name in the table, then the verification check is bypassed. So adding code to DLookup to check for the existence of specific field names first is necessary. Any insight will be...
11
1995
by: MLH | last post by:
My alzheimer moments occur with greater frequency these days, it seems. I sometimes open Access and the same dbase in a second instance and work on items. If I modify a form and discover later that I'm working in a 2nd instance of Access, I close it. The modifications are not present in the first instance of the program and I have to make them again. Is there a setting I can make that will prevent me from inadvertently doing just that?
3
8221
by: frenchy | last post by:
I am getting this error in Adobe after struggling with a 'submit' button on an acrobat form that is in production and all the other appdev people in the office are NOT having a problem with. It submits the form to the web successfully for them, for me the button just clicks and does nothing. So we turned on my javascript debug in Adobe and are getting this? Acrobat EScript Built-in Functions Version 6.0 Acrobat Annotations /...
1
1758
by: coolsidsin | last post by:
I have a apsx form (Form A), which on submiting does a time consuming task. So i want to open a new aspx window (Form B) in which I want do do that time consuming task and show progress to the user and while that task is being completed I want Form A to redirect to Form C. I opened form B in a new javascript window and updated the progress through ajax but Form A doesn't let me redirect to Form C unless Form B's processing is Completed. ...
16
5171
by: Phil Stanton | last post by:
I have a form with a button which is supposed to open an Excel file (With lots of Macros /VBA) in it. The Excel file gets it's data from the Access program Here is the code Private Sub Storage_Click() On Error GoTo Err_Storage_Click
2
3117
by: Samuel | last post by:
I have some questions that are sort of connected. I use Access 2003. Is it possible to set some properties that can make the Access window open at a particular size? Is it possible to make a form open inside the Access window so that it fills the window completely without borders? I have seen some databases that open and there is no outside borders and the forms all work neatly inside. It looks like the database form is
0
8428
marktang
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...
0
8341
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
8751
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
8539
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
8630
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...
0
4176
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...
0
4342
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2759
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1739
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.