f



MS Access Primary Field on form lookup

I am creating one of my first databases and definetly my first in
Access 2007.  This might not be possible but here it goes.  I have
several maintenace forms I need to create.  Each of these forms has a
related table with a primary key.  One of these tables is a "Customer"
table with the primary key being the "CustomerCode"

On the form for data entry I would like to have the "CustomerCode"  do
the following
1)  Have a lookup so I can easily go to what ever customer I choose
for editing.
2)  If the user enters a Customer Code that is not in the system then
the form automatically
     knows this is a new record, clears the old data from the form and
allows the user to enter
     the new record.
3)  User enters a Customer Code that does exist then the record is
retrieved for viewing and
     or editing.

Am I asking to much from the system and is this even possible.  Any
help appreciated.

Ray
0
1/25/2011 9:52:26 PM
comp.databases.ms-access 42670 articles. 0 followers. Post Follow

1 Replies
482 Views

Similar Articles

[PageSpeed] 3

The Combo Box Wizard gives you options that do what I think you are asking 
for. In the Controls toolbar be sure you have the "magic wand" icon 
selected, then click on the Combo Box icon, move your cursor to 
approximately where you want it on the Form, and click, then follow the 
instructions in the dialog.

 Larry Linson
 Microsoft Office Access MVP

"eighthman11" <eighthman11@yahoo.com> wrote in message 
news:d5d903bc-1a06-4520-a0ab-641d0509086c@d8g2000yqf.googlegroups.com...
>I am creating one of my first databases and definetly my first in
> Access 2007.  This might not be possible but here it goes.  I have
> several maintenace forms I need to create.  Each of these forms has a
> related table with a primary key.  One of these tables is a "Customer"
> table with the primary key being the "CustomerCode"
>
> On the form for data entry I would like to have the "CustomerCode"  do
> the following
> 1)  Have a lookup so I can easily go to what ever customer I choose
> for editing.
> 2)  If the user enters a Customer Code that is not in the system then
> the form automatically
>     knows this is a new record, clears the old data from the form and
> allows the user to enter
>     the new record.
> 3)  User enters a Customer Code that does exist then the record is
> retrieved for viewing and
>     or editing.
>
> Am I asking to much from the system and is this even possible.  Any
> help appreciated.
>
> Ray 


0
accdevel (436)
1/25/2011 10:49:08 PM
Reply:

Similar Artilces:

Create MS/ACCESS database app for non-ms/access users
Is it possible to create an MS/ACCESS database application and package it for users who do not have MS/ACCESS loaded in their PCs? I was told that this is possible, but I don't know what software is needed. Do you know? If so, please answer this post. Thanks. SueB *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! Per Sue Bricker: >Is it possible to create an MS/ACCESS database application and package >it for users who do not have MS/ACCESS loaded in their PCs? > >I was told that this is possible, but...

Possible to keep MS Access interface and migrate the MS Access to MS SQL Server?
Hello all Would it be possible to migrate the MS Access 2000 to MS SQL Server 2000? My application is using MS Access 2000 as database and as user interface such as forms. Now, I want to migrate the backend database from MS Access 2000 to MS SQL Server 2000. However, I want to keep the MS Access 2000 interface. Would it be possible? If I migrate the MS Access to SQL Server, would the queries, back-end VBA, macro, tables and forms be affected? Do I need to change the MS Access data type to SQL server supported data type? Which tool I can use to do the migration? Upsizing wizard or exporting...

Access MS-ACCESS database on server from client????
I m currently developing a java based application and want to know how can i make client access database located on the server? "HeMan_Speaks" <Lunar20092010@gmail.com> wrote in message news:d71ce567-0434-48b8-b1d2-bb191706ab45@w8g2000prd.googlegroups.com... >I m currently developing a java based application and want to know how > can i make client access database located on the server? I think you're going to have to expand a little bit more in your question here, as is not 100% quite clear what you're trying to do. You might want to make a little bit of a distinction between MS access, the development system that allows you to write code, build forms, and build reports, and that of the database engine that you choose to use with MS access. When you build an application MS access, you then choose your database engine, that might be oracle, SQL server, or perhaps more often leave the default jet database. So when you say make a client access application, are you talking about a piece of software that you plan to install and each computer? The fact that your introducing the issue of java further complicates your question. Perhaps your question is simply you have some java code running on a server, and with to open a mdb file (an access database file). In this situation you're not really using MS access at all here (you using what is called the jet database engine to read that mdb file). For all the trouble in this type of sce...

MATLAB command to access MS Access database
Hi! Is there a MATLAB command which gives access to a .mdb MS Access database or do I need a special driver? Thanks, Andree Hi Andree Ellert, you can use activeXcontrol to interact with MS-Access database. access = actxserver('Access.Application'); returns the handle for Access. set(access, 'Visible', 1); will show the opened Access window. use get(access) and set(access) commands to find the methods available to call. -Vadivelu M =========== http://www.mathworks.com/access/helpdesk/help/toolbox/database/datatool.shtml "Andree Ellert" <ellert@gmx.net/////\\\\\> wrote in message news:eed9874.-1@webx.raydaftYaTP... > Hi! > > Is there a MATLAB command which gives access to a .mdb MS Access > database or do I need a special driver? > > Thanks, > > Andree Andree Ellert wrote: > > > Hi! > > Is there a MATLAB command which gives access to a .mdb MS Access > database or do I need a special driver? > > Thanks, > > Andree <http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=4045&objectType=file> -Hardik ...

request for explanation on access an database in ms access
This is the code that I found on the internet for accessing an ms access database: import java.sql.*; class Test { public static void main(String[] args) { try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); // set this to a MS Access DB you have on your machine String filename = "d:/java/mdbTEST.mdb"; String database = "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};DBQ="; database+= filename.trim() + ";DriverID=22;READONLY=true}"; // add on to the end // now we can get the connection from the DriverManager Connection con = DriverManager.getConnection( database ,"",""); } catch (Exception e) { System.out.println("Error: " + e); } } } What I don't understand is the declaration of database. What I did was putting the database in the same dir as the sourcecode and use "jdbc:odbc:CafeJolt.mdb". But this doesn't work. And the above code does, why is that??? Actually it's not Java question. It's ODBC question. You have to have ODBC connection. Depending of Windows it's usually something like this (for my Windows 2000): Start->Sttings->Control Panel->Administartive Tools->Data Sources(ODBC)-> User DSN -> [Add]-> Driver to Microsoft Access(*.mdb) === And here, finally you can choose file name. ...

Best way to access a remote MS ACCESS database
What is the best way, via the internet, to access a remote Microsoft Access database? I was thinking of using VPN, but I thought that I would check here to see if there is a better way. Any suggestions? Thanks Do you mean remotely controlling an Access database, or linking tables over the internet? The first is doable, the second is a recipe for disaster. Remote Control: If your remote OS is Windows XP, you can use Remote Desktop (although only 1 person can access the PC at a time; this will change in the upcoming Service Pack for XP, but that may not help you now). Otherwise, GoToMyPC offers similar services, as does Terminal Server (a component of a Windows Server machine), PCAnywhere, et al. Linking to remote tables: You will almost certainly encounter severe problems with corruption, and your performance will almost certainly be so poor as to be unworkable. I attempted this once, with a web server in Canada and my machine in Augusta, GA. Even tiny data requests on a very well optimized data structure took waaaay too long to process ... it's simply not workable, IMO. Other alternatives would be covert the app to a web-based and place your data on a web server. Access/Jet isn't really designed for those workloads, but running a small site with minimal transactions and users can be done. Otherwsie, consider switching to a more robust data platform like MySQL, SQL Server, etc. -- Scott McDaniel CS Computer Software Visual Bas...

Accessing a MS Access database across two servers
Hi The technical support guys at my company have set up my system so that the server containing the MS Access database is on one server, while the pages that should access the database are on another server. When the pages and database are on the same server, I usually just connect through ODBC. The problem is that I don't know how to set up an ODBC connection to link from one server to a database in another. Anyone know what I am getting at and know of a possible solution, or a link to a site which may help. thanks in advance Brendan "Singularity" <Brendan.Collins@Sin...

Accessing MS ACCESS database using Data Environment
HI, I have developped a program in Visual Basic 6.0 using MS Access database. I have created all my reports through Data Environment where I have entered the location of my database file (for e.g c:\project\app\test.mdb) in the Connection properties. I have installed my application on another PC using Package & Deployment wizard. When viewing the reports on the other PC, I have to enter everytime the new location of the database. How can I solve this problem, please? nadia wrote: > HI, > I have developped a program in Visual Basic 6.0 using MS Access database. >...

Forms/Subforms in MS Access Database
Why do my Forms/Subforms in my MS Access Database not appear? All I see is the boxes where they should show?! What did I do wrong? Thanks, John zufie wrote: > Why do my Forms/Subforms in my MS Access Database not appear? > > All I see is the boxes where they should show?! > > What did I do wrong? -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Probably there isn't a name of a form in the sub-form's Source Object property. Also, the Link Child Fields and the Link Master Fields properties may be blank - you must enter the names of the link fields, they hold the field names that link the data between the forms. -- MGFoster:::mgf00 <at> earthlink <decimal-point> net Oakland, CA (USA) ** Respond only to this newsgroup. I DO NOT respond to emails ** -----BEGIN PGP SIGNATURE----- Version: PGP for Personal Privacy 5.0 Charset: noconv iQA/AwUBSSsUjoechKqOuFEgEQL+dQCfYUSwXFtPj0RRSZO+q3J8lQCD0/UAniRz JKu0h9AG0BAg8W3wC/0BC7B3 =Kvva -----END PGP SIGNATURE----- On Nov 24, 2:54=A0pm, MGFoster <m...@privacy.com> wrote: > zufie wrote: > > Why do my Forms/Subforms in my MS Access Database not appear? > > > All I see is the boxes where they should show?! > > > What did I do wrong? > > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Probably there isn't a name of a form in the sub-form's Source Object > property. =A0Also, the Link Child Fields and the Link Master Fields > properties...

accessing MS Access database fila via ODBC problem
Hi! I'm trying to connect to a MDB file via ODBC like this: char *DSN = "DRIVER={Microsoft Access Driver (*.mdb)};DBQ=c:\\dev-cpp\\test\\1.mdb"; SQLAllocEnv(&env); SQLAllocConnect(env, &hdbc); SQLBrowseConnect(hdbc, (UCHAR*)DSN, strlen(DSN), (UCHAR*)buf, BUF_SIZE, (SQLSMALLINT*)&rcvlen); The function SQLBrowseConnect fails and SQLGetDiagRec returns "IM001 Driver does not support this function" Can anyone help me? Thanks! David On S...

Accessing 2 tables having same name but different databases ms-access
Hi, I have an application with MS-Access as backend and JSP/ tomcat as frontend/webserver. For getting better response time(as access is very slow compared to other RDBMS's), I have split the main DB into two DB's on different disks on my server for better performance.I have kept the table names same but changed the DB names. How do I access tables from both the DB's? This is what I have done; I made different connection to the respective DB's i.e. con and con2. When I want to access data, I am using 2 result sets for retriving data from the tables, but getting no result. Here is my code: rs2_1=stmt2_1.executeQuery("select * from Requests where Status='Released' AND LoginName='"+login+"' order by Req_No"); rs=stmt.executeQuery("select * from Requests where Status='Released' AND LoginName='"+login+"' AND Req_No> 5500 order by Req_No"); So, rs & stmt are for latest records and rs2_1 & stmt2_1 correspond the records from older DB. I think, I'm forgetting some small thing but cant get it. Please advice. What do you mean "no result"? Does "next()" return false for both rs2_1 an= d rs? If you're really trying to improve response time, you should probably be ru= nning the two queries in separate threads ... but as you acknowledge, Acces= s may not have as high performance as other RDBMSs. You would also see rel= iability adv...

accessing ms access via ODBC without Microsoft Access
Hi, If I have a computer without Microsoft Access installed but with an ODBC connection to a .mdb file - can I still access the 'database' via ODBC? thanks Tim <timasmith@hotmail.com> wrote in message news:1145206985.433826.106120@i40g2000cwc.googlegroups.com... > Hi, > > If I have a computer without Microsoft Access installed but with an > ODBC connection to a .mdb file - can I still access the 'database' via > ODBC? Yes, provided you are running a program prepared in a language that supports ODBC and have installed an ODBC driver on that user'...

Free JDBC driver to access MS Access database from Linux enviroment.
I'm looking for a free JDBC driver that will allow me to acces a MSAccess database that resides on a Windows server from a JSPapplication that resides on a Redhat Linx server.Any suggestions would be appreciated.Thanks,Tim tim@nocomment.com wrote:> I'm looking for a free JDBC driver that will allow me to acces a MS> Access database that resides on a Windows server from a JSP> application that resides on a Redhat Linux server.> Any suggestions would be appreciated.Sounds like RmiJdbc is a solution.See <http://rmijdbc.objectweb.org>-- Thomas...

How to access MS Access from Perl?
Hi, Good day! I am writing some Perl script on the server side for HTML forms that can create/update an MS Access database. Does anyone know of examples how this can be done? Your help is greatly appreciated. -lc Email to luican@yahoo.com bounces. Anyway, try DBI and DBD::ODBC. Or maybe DBD::ADO, but I've never tried it. ---------------------------------------- http://cpan.org http://search.cpan.org/~jurl/DBD-ODBC-1.09/ODBC.pm ... Connect without DSN The ability to connect without a full DSN is introduced in version 0.21. Example (using MS Access): my $DSN = 'driver=Mi...

How to link fields in MS word document to Access database
Anyone have experience in linking fields in an MS Word document to an access database? What I am considering doing is taking an existing fill-in-the fields word document, for which I cannot now save the data, and allow it to be opened with no data, have the fields filled in and then save the data in an Access database. I also want to later select the document (from a file in the database), open the word document and populate the fields from the database. Of course if there are then any updates I want to put them back into the database. Workable? Anyone with sample code? Bob Alston On Jun 10, 6:21=A0pm, Bob Alston <bobalst...@yahoo.com> wrote: > Anyone have experience in linking fields in an MS Word document to an > access database? Hello Bob, Instead of Word documents I use RTF-documents. RTF-documents act just like Word documents in Word. The difference is that RFT-documents are plain text-files, and can easily be processed in Access to find - with the appropriate placeholders - the filled in information. HBInc. > > What I am considering doing is taking an existing fill-in-the fields > word document, for which I cannot now save the data, and allow it to be > opened with no data, have the fields filled in and then save the data in > an Access database. =A0I also want to later select the document (from a > file in the database), open the word document and populate the fields > from the database. =A0Of course if there are then ...

MS-Access, ODBC access with Visual C++ 6.0, and external actions on database
[was redirected here] I have a problem that I can distill down to the following. 1/ A Visual C++ 6.0 program connects to a MS Access database using an ODBC connection and sleeps for a long time. The connection takes all defaults and uses CDatabase::useCursorLib in the OpenEx command. 2/ The database is well over 400MB large with over 200 tables and is compacted. 3/ Another process starts a winzip on that database that takes about 45 to 60 seconds to complete (wzzip -a -ex aaa.zip aaa.mdb). 4/ The Windows Task Manager shows 100s of MBs of available memory being consumed....

Import MS Office Excel Comma Separated Values Files into a MS Access 2003 database
Hi, I have been tasked with Importing MS Office Excel Comma Separated Values Files into a MS Access 2003 database. These files were exported from a DB2 database.I have also been given the DDL code. I have Googled a solution to this task and have tried creating these tables using the DDL code in a query within a blank MS Access database. Is there a more expedient way to achieve this? I noticed, for example, that a field in DB2 has a data type of "decimal" while the same field would have the data type of "number". Thanks, Zuf What follows is the DDL: -------...

How to set Data source in MS Word as MS Access Databases via DDE(*.mdb;*.mde).
How to set Data source in MS Word as MS Access Databases via DDE(*.mdb;*.mde). Everytime i click the command button to merge the data, it gives me item not found and i know that its a problem with my datasource. when i click ok then it opens the word doucment prompting me which datasource you want to use, when i click DDE then it gives me the merged data. Is there anyway i can set it permanantely in my codes below. Private Sub SetQuery(strQueryName As String, strSQL As String) On Error GoTo ErrorHandler 'set the query from which the merge ' document will pull its i...

MS Access databases
Hello, I have been trying to read a simple MSAccess database and show the records on screen but no success so far. I have created a DSN (Data Source Name) in my Win 2k box and the connection goes ok. But when I try to return a ResultSet using a simple SELECT statement, ("SELECT * FROM MyTable") no records appear. Database is Ok. It is a very simple table. I don't get *any* error message but also no records from it. Is there anything special I need to do for accessing it? Does anybody have a simple code for accessing MSAccess databases? (From DSN creation till sample code) Thanks in Advance. Java Newbie. import java.sql.*; public class DataBase { public static void main(String[] args) { String data = "jdbc:odbc:YahooAddrBook"; // data base friendly nam try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); Connection conn = DriverManager.getConnection( data, "", ""); Statement st = conn.createStatement(); String q = "SELECT * " + "FROM yahoo_ab " + // table name "WHERE (\"Last Name\" LIKE '"+ args[0]+"') "+ "ORDER BY (\"First Name\")"; System.out.println(q); ResultSet rec = st.executeQuery(q); while(re...

MS Access database
A client of mine has another 3rd party program which uses MS Access database. They want my to create an additional program which is to read this data. My problem is that the database has a password on it. I know there are cracks available at a cost of USD$45.00+. Does anybody have a free crack to retrieve the database password? Would this be unethical or be a copyright of reverse engineering violation? The data is owned by the client so I recon is would be fine to read the data! Regards, Lance It's your data. As long as you don't sell it or use their data in any software that you...

MS Access 2002 problem: linked form fields in ODBC queries
Ok, my problem is the following: I have very complicated Access 97 databases that link through ODBC to Sybase databases. Now in some of the forms controls I had queries that used as "where clause" parameters form field values; For example: select foo from bar where a_colmun = [forms]![MyForm]![MyField] This worked in Access 97 but fails in Access 2002 (ODBC failure) when the table *bar* is an ODBC Sybase (in my case) linked table. If *bar* were a local Access table, the query would do fine. if i did select foo from bar where a_colmun = (select [forms]![MyForm]![MyFi...

MS Access Database
Interested profiles should be delivered at versatilehr.farook@gmail.com Title: MS Access Database Location-NC Duration-3 months Skills & Experience: MS Access Database experience: Must understand and have experience developing MS Access applications. =95 SQL experience =95 ODBC =95 Importing and exporting excel spreadsheets to and from Access DB =95 Forms development =95 working with DB objects =95 Creating New Databases The Relational Model of Data Storage Creating Relational Database Tables Assigning a Primary Key to a Table =95 Joining tables in Database =95 Queries and Advanced Queries using conditions =95 Macros =95 Reporting =95 Using Datasheets =95 Customizing tool bars Farook Ahmed On 19 May, 19:15, Farook Ahmed <farook.versatil...@gmail.com> wrote: > Interested profiles should be delivered at > versatilehr.far...@gmail.com > > Title: MS Access Database > Location-NC > Duration-3 months > > Skills & Experience: > MS Access Database experience: Must understand and have experience > developing MS Access applications. > =95 SQL experience > =95 ODBC > =95 Importing and exporting excel spreadsheets to and from Access DB > =95 Forms development > =95 working with DB objects > =95 Creating New Databases > =A0The Relational Model of Data Storage > Creating Relational Database Tables > Assigning a Primary Key to a Table > =95 Joining tables in Database > =95 Queries and Advanced Queries using c...

MS Access Database
Hi, I am working on a database to keep track all the caller's info in the database. For example: After the user entered a caller's information in the database, and when that same caller called back again the second time and then some of their information and also the client id automatically appeared on the screen so that the user don't need to retype them again. I want to keep track of each record as new records. The Id and first name will be the same. When I run a report I can link them all together and knowing that this person had called in twice! Any suggesti...

Accessing Oracle Tables from MS Access
How difficult is this? I'm having a tough time getting a simple select to work. I am using MS Access 2002 and Windows XP. What do I have to do to make a simple select statement like this work: select id from emp I have stumbled upon many websites although none straight to the point. Any help in how to get this done, or pointing me in the right direction of a book or website, would be greatly appreciated! berj Yes, I do have the table links working. But I did want to run the select for such things as grabbing the next number off of a sequence. As in: select test.nextval fro...

Web resources about - MS Access Primary Field on form lookup - comp.databases.ms-access

NHS primary care trust - Wikipedia, the free encyclopedia
An NHS primary care trust (PCT) is a type of NHS trust , part of the National Health Service in England . PCTs commission primary, community ...

Giralang Primary School students explore the wonders of space at Cosmic Stars
Giralang Primary School's Cosmic Stars program teaches students about the search for extraterrestrial life.

Armed man on the loose following Beveridge Primary School lockdown
... school is in lockdown after reports of a man with a firearm. Police are still searching for an armed man whose presence outside a primary school ...

Primary Health Care boss keen to know Jangho's intent after swoop
Primary Health Care chief executive Peter Gregg will approach China's Jangho Group, which has seized an 11 per cent stake in the company, to ...

Who's Haitong and what are they doing at Primary Health Care?
What's a full service stockbroker out of Hong Kong and Shanghai doing with a substantial stake in Australia's Primary Health Care?

Republican leaders opposed to Trump are unleashing 100-day campaign beginning with the Wisconsin primary ...
The NYT reports. I'm glad to see that Wisconsin looks important, but I don't understand what these people think they can do. Spend a lot of ...

Which Democratic Primary State Is Most Important? The Badger State Is A Biggie
Bustle Which Democratic Primary State Is Most Important? The Badger State Is A Biggie Bustle Although Hillary Clinton has a healthy delegate ...

Hillary Clinton wins Missouri primary, Bernie Sanders concedes
The Associated Press called the race two days after the primary was held

Hillary Clinton narrowly wins Missouri primary
Presidential candidate Hillary Clinton has won the Democratic Missouri primary. Senator Bernie Sanders will not request a recount. Wolf Blitzer ...

Fixing the Primary System
... blog posts arguing that we need to strengthen democracy . One of my key takeaways from the current US Presidential election is that the primary ...

Resources last updated: 3/20/2016 2:46:13 PM