Open new copy of form

Posted on 2011-04-22
Medium Priority
Last Modified: 2012-05-11
Good afternoon,
Ive written an database application which works fine using the following code to open a form:-
DoCmd.OpenForm "frmFaultLog", acNormal, , "[FaultNo] = " & lisFaults.Value, acFormEdit

Open in new window

However if I then click another calue in my List then the previous opened tab changes its record to the second click (as it should), my question is if possible can I load multiple copies of my for 'frmFaultLog', so I can load multiple jobs up at the same time?

Something like:-
frmNew as new frmFaultLog
frmNew.fliter = "FaultNo=27"

Open in new window

Question by:tonelm54
  • 3
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 35446960
yes, it is possible
in the form's module place this

option compare database
option explicit
dim frmNew as Form

in the click of a btn

private sub btnNewForm_click()

set frmNew = New Form_frmFaultLog

end sub

Expert Comment

ID: 35447094
I tried it out and not able to do so!!! maybe u gotta have 1 output form at a time!!
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 35447208
and, set the hasModule property of the  form to Yes.
you can find this in the Other tab of the form's property sheet.
LVL 120

Accepted Solution

Rey Obrero (Capricorn1) earned 2000 total points
ID: 35447313
see this sample db
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 35464175
<so I can load multiple jobs up at the same time?>
I hope you don't need more that 3 forms open at one time, or the screen could get messy...

Why not just allow for the selection of multiple values (FaultNos) from the listbox
...Then display them all with a click of a button?

Without the need for opening the exact same form multiple times, and using up screen real estate...

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question