Forms :: Open Form From Combo Box

Jun 3, 2014

Im using the below code to open a from depending on what option is selected on a combobox.

Code:

Private Sub DirectPCombo_Click()
Dim cboVal As String
Dim stDocName As String
cboVal = Me.DirectPCombo.Value
Select Case cboVal
Case "One"

[code]....

If you select the first item [One] it will open the correct form [TestOne]. But when you select any of the others an error comes up saying that the name is no a form. So I added

Code:
DoCmd.OpenReport stDocName

But the no items would select.I know If split the reports form the forms and make two comboboxes it would work, but it would be better it both could be in the same combobox.

View Replies


ADVERTISEMENT

Forms :: Open New Form Based On Combo Box Selection

May 26, 2013

I have "donations" form with a cbo called "DonationType".

(frmDonations.DonationType)

General
Employee Match
Employer Match
Angels*
Friends*
Royal Crown*

The last three options need to redirect the user to a different form used for pledged donations.

View 2 Replies View Related

Forms :: Using Combo Box Selection To Open Form And Goto Record

Jan 14, 2014

I have a combo box called Combo9 in form NavigationF, the combo box displays the results of FollowUpQ Query. What I would like to do is when the user selects a row from the combobox is closes NavigationF and opens ContactHistoryF and goes to the record selected in the combo box. I have made sure that the combobox contains CustomerID which is the primary key for my table.

View 4 Replies View Related

Forms :: How To Open Subform By The Selection From Combo Box

Feb 4, 2014

I have a form that contains a form (Contain business data) and a then a sub form that hold the companies history of donations. BUT I also have another forms that hold miscellaneous data that I would like to look at also in the sub form area.

I want to select the sub form by a combo box to show the "sub forms"I want to look at by selecting a menu from a combo box.

I have worked with Access for years but some reason the combo box has always been difficult for me to completely understand.

View 1 Replies View Related

Forms :: Open Combo Box Containing Contents From Table

Aug 8, 2013

I have a combo box containing "ProgramType". If "DDI" is selected from this combo box, I would like it to open up another combo box containing the contents from "tblDDI". Then I would like the selection to be transferred to "ProgramType". Is this possible?

View 5 Replies View Related

Open A Form From A Combo Box

Aug 29, 2005

Hi all,

The title says it all; how can I make a form appear when something is selected from a combo box?

Thanks in advance,

Atholl

View 2 Replies View Related

Forms :: Open Report Based On Combo Box Selection?

Jan 29, 2014

I am struggling to pull out a report based on the combo box selection. I have NOI database and want to pull out a report for a specific customer that how many NOIs are generated by this customer..

I have a separate table of customer and another table of NCRs and the customer information comes from customer table.

I have tried the below statement but gives me an error message:

code for Macro that pulls the report in click event:

[CustomerName]=[forms]![CustName]![combocust1]

do i need to mention the report as well in some where in report ?

View 14 Replies View Related

Open Specific Form From Combo Box

Nov 12, 2005

I have a form with a subform which has a lookup table (combo box) as a field. I want to be able, when I select a certain item in the lookup to have it automatically open a form. e.g. A field called insurance class - I select motor, I want the motor details form to open. If I select Fire, I want it to open the fire form and so on. I have already created the forms. Please help!

View 14 Replies View Related

Open A Form With A Combo Box Selection??

Nov 24, 2005

Hello,

Please help, I am still kind of new to Access. My problem is. I need to be able to open a form from a selection of a combo box. Thank you in advance.

View 3 Replies View Related

How To Open A Form On A Particular Record Using A Combo Box

Aug 1, 2006

Hi,

I have created a combo box that allows the user to select a particular customer from the drop down list. I have managed to type in some code that opens the customer form after the user selects a customer, but how do i get it to open the customer form on that particular record selected by the user????

Thanx

View 1 Replies View Related

Open Form On Two Combo Box Values

Sep 17, 2006

Hi I've tried to find an answer to this but having no luck.

I have a form that has two combo boxes the first box looks up the year from the project table and the second box the project number. I want to open the project details that correspondes to these two input values within the combo boxes by pressing a command box.

I've tried the following but just get a syntax error:

Private Sub cmdOpenJobDetails_Click()
On Error GoTo Err_cmdOpenJobDetails_Click

Dim strDocName As String
Dim strYear As String
Dim strJobno As String
Dim strFilter As String

strYear = Me.cmbYear.Value
strJobno = Me.cmbJobno.Value

strFilter = "Select [tblProjects].[intprojectyear], [tblProjects.[intprojectjobno] FROM [tblProjects]" & _
"WHERE [intprojectyear] = & strYear And [intprojectjobno] & strJobno"

strDocName = "frmProjectDetails"

DoCmd.OpenForm strDocName, , , strFilter

Exit_cmdOpenJobDetails_Click:
Exit Sub

Err_cmdOpenJobDetails_Click:
MsgBox Err.Description
Resume Exit_cmdOpenJobDetails_Click

End Sub

View 2 Replies View Related

Forms :: Run Specific Queries And Open A Report Using Combo Boxes

Jul 30, 2013

I have a form which runs specific queries and opens a report using combo boxes, these work perfectly fine if I just try to run them in the form. I have put the form into a navigation form and if I try to run the same query I get parameter queries popping up instead of just running the query and opening the report.

View 2 Replies View Related

Open Subform Based On Form With Combo Box

Oct 27, 2005

I have a main form (FRMProspects) with a combo box (ComboCoName) that has a query as it's record source to sort the records displayed in it. It is bound by the CustID (autonumber), but displays the CompanyName.

What I want to do is open a sub form FRMNotes, based on the Company name that is selected in the ComboCoName. So for Company XY, I want to click on the Notes command button to open up all the notes for that company only (filtered). FRMNotes is based on a different table, but TBLProspects and TBLNotes are linked by CustID (one to many).

What code do I need for this? I am treading water with VBA!

View 4 Replies View Related

Combo Box Selection To Determine Which Form To Open

Jul 13, 2005

Hi don't know if I'm trying to do something that can't be done but I'll give it a try

I have a combo box which selects a type of incident e.g. report, SIF, Phone call etc

and dependent on what is selected I would like to get access to automatically select which form to open so if report is open when the command button is clicked then the report form would be opened, when SIF is selected the SIF form would be opened etc...

How do I go about this.. I have only ever wrote code in excel, so can I have step by step if it involves code (which I guess it does) including where to put the code and even how to go about it

Thanks in advance to all

View 6 Replies View Related

General :: Open A Form Through Combo Boxes

Sep 19, 2013

I have designed a main form which have buttons for about 30 different companies name to open, each button opens an individual company form. Now the companies list is growing day by day so i want to create a combo box which select the company name and open the relevant company's form.

Do I need to create a table which lists all the companies and then add a combo box on a main screen which select the company name and open the form but i need a VBA code for that.

View 14 Replies View Related

Open Relevant Form Based On 2 Combo Boxes?

Apr 6, 2006

Hey guys, I'm not sure if this is possible, and it is the most challenging thing that I have tried to implement into my database to date.

What I have is a booking form which allows you to Add Bookings for camera kits.

When a customer comes in and would like to book a kit, the form must be filled in with the relevant details, I have 2 combo boxes on this form.

The first is the Kit selection, there are 5 camera kits.
The second is an option to book the full kit out, or just components.

So here's the tricky part...

When the first combo box selection is made (eg. Kit 3) I need the Kit3 table to be active.

Then, when the user selects "Components" from the second combo box, I need a form to open up based on both of the above.

So a form based on tblKit3 would be opened and the user can manually select the components that they require to be booked out.

Any help at all would be appreciated.

View 1 Replies View Related

Forms :: When Open A Form / Want To Open Another From At Same

Jan 14, 2015

when i open a form i want to open another frm at the same time. i have a main form with some buttons in it. when i click on a button and a form opens then i am not able to click on a button to open other forms from the main form.

View 2 Replies View Related

Cascading Combo Boxes - Open A Form And Add Multiple Items To A Table

Mar 12, 2011

I have been trying to modify a sample database to suit what I want to do but I am getting stuck on the very first part cascading combo boxes i want to open a form and add multiple items to a table - first i want to select, from a combo box a department - then select a supplier from all the suppliers/manufacturers related to that department then select a stock item based on the description from all the items available from that supplier

I have attached the database I am using to modify and my database.

View 5 Replies View Related

Forms :: Button In Form To Open Different Form And Chose A Customer Based On Last Form

Mar 26, 2013

Basically I have a Customer Form, which I have a New party button on it,this button opens up the party form to a new party, what I would like it to do is open up a new party but make the new party for the customer I had selected in the previous form.I have tried the GoTo macro's but cannot seem to get it to work.

I am thinking on clicking the button it will need to get the Customer ID, and then open the party form, create new party, and paste in the Customer ID, which then updates the Name - Date - Address - Company Fields.

View 5 Replies View Related

Forms :: Change Record Source Of Combo Box On Form Based On Another Combo Box

Mar 31, 2014

I have a form that currently uses a "catch all" table for listing available equipment to choose from for an equipment field. I call it tblEquipment. What I want to do is to make it so when I type a name in (1 of 35) in one field of the current record, the record source for the equipment field immediately looks at a different table that has equipment available only for that name. To do this I plan on making 35 different tables with limited data originally found in tblEquipment. I would call these tblEquipment1, tblEquipment2, etc. I do not use a sub form, nor do I want to.

So my questions are:

1) can this be done
2)If it can be done, how can I do it?

View 3 Replies View Related

Forms :: Filtering A Combo Box On A Subform From A Combo Box On A Main Form

Apr 27, 2013

I have a Suppliers database which contains a form that will allow me to place orders with Suppliers.The Main form has a combo box that allows me to select the supplier. The combo box is called SupplierID with the following:

Row source: SELECT Suppliers.SupplierID, Suppliers.CompanyName FROM Suppliers ORDER BY Suppliers.CompanyName;

The subform is called Stock Subform witha combo box called ProductID with the following:

Row source: SELECT DISTINCT Products.ProductID, Products.ProductName, Suppliers.CompanyName, Products.Discontinued FROM Suppliers INNER JOIN Products ON Suppliers.SupplierID=Products.SupplierID WHERE (((Products.Discontinued)=0)) ORDER BY Products.ProductName;
Event Procedure - AfterUpdate: Private Sub ProductID_AfterUpdate()
On Error GoTo Err_ProductID_AfterUpdate
Dim strFilter As String
' Evaluate filter before it's passed to DLookup function.
strFilter = "ProductID = " & Me!ProductID

[code]..

The Link fields are done on the Purchase Order ID (PONoID).What I want to achieve is to select the supplier from the combo box (SupplierID) on the main form and then the combo box (ProductID) on the subform to filter to only show products directly supplied by the Supplier selected on the Main Form.

View 11 Replies View Related

Forms :: Open Blank Form Based On Value In Text Field In Main Form

Jun 6, 2013

I have one table containing name of restaurant with its address etc. Then i created another table to list out the restaurant workers names and details. Just as an example,

Table:Restaurant
Restaurant name
Address line 1
Address line 2
Restaurant #
Website

Table:StaffContact
Staff Role
Name
speciality
email
phone

I have the main form that has all the restaurant details only. And i have another form containing the Staff information. Please note the two table have a relation and it works well.

Now to make it user friendly(basically easier for the lazy ones), I dragged the staff contact form on to my main form and displayed it as a datasheet(basically a sub form).

Now, my boss does not want users to add/delete on this sub form(datasheet). So,he wants me to create buttons to open new record of staff for each restaurant(new form)

My issue is with opening a new record to enter a new person to the staff list and give them a role as well in form view.The new form has

So i ran a Macro, with open form with Where condition

Code:
[Staffcontact]![Rest Name]=[Forms]![MainForm]![RestaurantName]

But, it does not work .

View 2 Replies View Related

Forms :: Continuous Form With Command Button On Each Record To Open Another Form

Jul 30, 2014

I have a continuous form in which I put a command button for each record called "detail". I would like to click on the "detail" button and make it open another form containing all (and only) the info on this record.

At first I refused to use an "id" to link both forms, but finally I added the "id" in the table... however still does not work.

continuous form: "04 - GASTOS_BUSQUEDA"
id field on continuous form: "Gastid"

pop-up (details) form: "GASTOS_EDITAR"
id on pop-up (details) form: "editar_id"

This is what I have tried on the "click" properties of the "details" button field (called "btn_editgs"):

1)
DoCmd.OpenForm "GASTOS_EDITAR", acNormal, , "[editar_id] = " & Me.Gastid

2)
DoCmd.OpenForm "GASTOS_EDITAR", , , "[editar_id]=" & Me.Gastid

3)
stLinkCriteria = "[editar_id]=" & Me![Gastid]
DoCmd.OpenForm "GASTOS_EDITAR", , , stLinkCriteria

4)
Private Sub btn_editgs_Click()
On Error GoTo btn_editgs_Click_Err
Dim strWhere As String
strWhere = "[editar_id] = " & Me.Gastid
DoCmd.OpenForm "GASTOS_EDITAR", , , strWhere
btn_editgs_Click_Exit:
Exit Sub
btn_editgs_Click_Err:
MsgBox Error$
Resume btn_editgs_Click_Exit
End Sub

View 9 Replies View Related

Forms :: Navigation Form - BrowseTo Command To Open Up A Form In Built-in Subform Module

May 3, 2013

I'm working on the Navigation Form template in Access 2010, which is new to me. It appears that one needs to use the BrowseTo command to open up a form in the built-in subform module. I'm trying to create a couple of buttons where each button opens a form in a different data mode; one in read-only and one in add mode. Here is the syntax I used for read-only:

DoCmd.BrowseTo acBrowseToForm, "frmSales","frmNavigation.NavigationSubform", , ,acFormReadOnly

frmSales is the Sales form I want both of the buttons to open and frmNavigation is the Navigation form. It seems to be ignoring the data mode part at the end however. It only will open in Edit mode. Is there something I'm doing wrong with this command?

View 3 Replies View Related

Forms :: Double Click Record In One Form To Open New Form?

Jan 27, 2014

I am trying to create a proposal log for my company to make things easier to track. I have made a multiple items form to list the proposals. I want to be able to double click the record to open up another form (that i have already created) that shows the information from the proposal table and the proposal details table. So.....

I want to double click the field named "Proposal Name" and have it open up to form i have called "proposals details form".

View 3 Replies View Related

Forms :: Open New Form With Record Data Sorted From Another Form?

Apr 2, 2014

I have a main form[frmResearchNotes] with combo box controls that filters a query populating [subfrmNotelist] containing several records from the filtered query. From there, I double click on a field within one of the remaining records, [CompanyName] for example, and it opens the new form[frmNoteDetail]. The problem is that second form is not displaying that selected record. The second form's record source has been set to the same query so when it loads, it displays the same info but it's displaying the 1st record out of the entire filtered list, not the record I clicked on in that list.

I figured I could use the strWhere function to copy the record I selected in the event procedure and then open the new form with those details. Not sure how to actually do this with VBA or if it's even the correct approach.

View 14 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved