473,385 Members | 1,769 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Access VB help

Hello

I have never used VB before but have been asked to look at coding a
button in Microsoft Access. The button currently exits a form and opens
a new form and works great. However, when the new form opens i want it
to open with information about the record i had open in the previous
form.

For example: I am looking at a record for everything to do with invoice
number 50 in the first form. The second form is the invoice print
layout that i open if i need to print the invoice information alone.
When i click on the button in the first form i need to have invoice
number 50 open in the second form.

Ideally i need to store the record number and then have it open in the
next form - if this is possible??!! Alternatively i could store the
stock number or invoice number and then have the button find the record
in the next form. I have tried a few things but they all give errors or
fail to work!

Any help will be greatly appreciated.

Regards, Gareth Jones

Nov 13 '05 #1
3 1588
On 27 Oct 2005 04:05:50 -0700, gj********@volcanomail.com wrote:

The form is opened using DoCmd.OpenForm. This takes an optional
argument named WhereClause. Use it to restrict the form to only those
records where InvoiceNumber=50.

You can see an example of this in the Northwind sample application,
Suppliers form, Review Products button.

-Tom.

Hello

I have never used VB before but have been asked to look at coding a
button in Microsoft Access. The button currently exits a form and opens
a new form and works great. However, when the new form opens i want it
to open with information about the record i had open in the previous
form.

For example: I am looking at a record for everything to do with invoice
number 50 in the first form. The second form is the invoice print
layout that i open if i need to print the invoice information alone.
When i click on the button in the first form i need to have invoice
number 50 open in the second form.

Ideally i need to store the record number and then have it open in the
next form - if this is possible??!! Alternatively i could store the
stock number or invoice number and then have the button find the record
in the next form. I have tried a few things but they all give errors or
fail to work!

Any help will be greatly appreciated.

Regards, Gareth Jones


Nov 13 '05 #2
Hey Tom

Thanks for the reply. The WhereClause is great however the InvoiceNo is
not constant so how would i enter the clause so that it takes the
record number of the form and uses that to display only that record in
the second form?

Thanks again, Gareth

Nov 13 '05 #3
Hello

I have sorted the problem out using a button to open up the form as she
wanted. It was very simple in the end! In the button wizard there is
the option to open a form and find specific data - which is exactly
what i wanted!

Thanks for your help on the matter though, without it i wouldn't have
found this option!

Regards, Gareth

Nov 13 '05 #4

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

Similar topics

11
by: Wolfgang Kaml | last post by:
Hello All, I have been working on this for almost a week now and I haven't anything up my sleeves anymore that I could test in addition or change.... Since I am not sure, if this is a Windows...
2
by: BT Openworld | last post by:
I have just had to upgrade to Access 2003 as Access 97 EMail (SendObject) doesn't work when loaded on Windows XP. I'm finding my way around Access 2003 but my biggest problem is getting...
28
by: Neil Ginsberg | last post by:
I have a client who is using Access 2002/2000 (the database itself is written in 2000), and is considering migrating to Access 2003. Any recommendations on whether Access 2003 is worth the migrate,...
27
by: Bruce Dodds | last post by:
I recently started using Access 2003 for the first time. I wanted to pass on some comments about the Help system to Access MVPs who frequent this board. I'm doing this in the hope that some of...
62
by: Ecohouse | last post by:
I was just wondering if there was any way to use a toolbar in Outlook 2002 in Access 2002? I want to create a custom toolbar in Access similar to the Calendar toolbar in Outlook. Any ideas?
57
by: TC | last post by:
I'd like to open a discussion about the state of the industry. For the past year, I've been unable to find competent Access developers available for hire. I'm worried about that. I think there's...
15
by: Cheryl Langdon | last post by:
Hello everyone, This is my first attempt at getting help in this manner. Please forgive me if this is an inappropriate request. I suddenly find myself in urgent need of instruction on how to...
7
by: Cheryl Langdon | last post by:
Does anyone know if there is a way to globally turn off ALL control tips in Access 2003 using VBA code? Thanks. --- CL
17
by: Mell via AccessMonster.com | last post by:
Is there a way to find out where an application was created from? i.e. - work or home i.e. - if application sits on a (work) server/network, the IT people know the application is sitting...
18
by: surfrat_ | last post by:
Hi, I am having the following problems in getting Microsoft Visual Studio 2005 Professional to link to an Access .mdb database. Please help me to sort this out. Problem 1: The Microsoft...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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,...
0
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...
0
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...

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.