Topics Search

Modal right choice for quick filter query form?

Modal right choice for quick filter query form?
Views: 12
Want to provide users a way to choose from a few dropdowns to build a query, show the results in a datasheet, then click save and load the result set into another table.

Questions: can you access form fields on the parent form?
Sponsored Links:

Similar posts...


passing variable from modal form to main form

passing variable from modal form to main form Icon
On my main form, I have a search option that opens a modal form. When the modal form is opened, the main form remains open. The modal form determines a variable. Clicking ok on the modal form, passes the focus back to the main form and closes the modal form. How do I reload the main form based on the variable from the modal form. The modal form is using a global variable

Modal Form

Modal Form Icon
I have a form that has a Frame Yes/No (1/2) question.I have gotten a select code to work that says if Frame is 1 to open my modal form.the modal form will have additional information for the individual to complete based on the Yes answer.the problem I am having is.I have one how do I get the information from my modal to populate in the table, on the record that is active?

Here is the code:
Private Sub Frame24_AfterUpdate()
Select Case Frame24
DoCmd.OpenForm "frm400Q1", acNormal
Case Else
End Select
End Sub
The modal form is after I input the data, it is not carrying over to the table.what I did was for the questions in the modal form I dropped into a separate query and based the record source of the modal on the query

Modal Form Close

Modal Form Close Icon
I have a modal form which has a button on it that when I press it opens a query. how do I get this modal form to hide behind the query when it opens?

I have managed to do it for a report but I dont know where to add vba codes in for a query

Modal Dialog Form

Modal Dialog Form Icon
I am struck with a Modal Dialog Form.
Basically I've got a main form with a datasheet subform which is not editable which has a Primary key and a foreign key columns in it. The only way to add some data to this datasheet view form is by clickin' a cmd Button.

Once I click the button a Modal Dialog form appears and then the user selects or enters the details in it which then gets appended to the table.

I've made this Modal Dialog form to go to new record every time it loads but I am wondering if there is a way to link it to the main form I mean when I click the cmd button I want this modal form to appear but want the foreign key to be selected by default.

I hope I've managed to phrase my query properly

Efficiency in Form/Query

Efficiency in Form/Query Icon
Possibly quick question: Is it more efficient to have my underlying query for a form filter out my records as opposed to doing it in the Filter property of the form?

To break it down further: I have added a function where the user can show the last 30/90/180/all days on split form with the datasheet on the bottom. This function uses the filter property to grab the last month/3 months/6 months/ or all records.

Would it be best to change a variable within the underlying query instead of using the filtering?

I only ask because I am working over a VPN right now and I noticed that the form was slow to load and I was thinking of what would be fastest.

Referencing properties of a modal form in VBA

Referencing properties of a modal form in VBA Icon
How do I reference properties of a modal form in VBA.
e.g. I have a modal form called "DatesForm" and I invoke it as follows:
DoCmd.OpenForm "DatesForm"
How do I reference the modal result and the fields on the form (what syntax do I use) ?
I want to set the value of a text box called CompanyText, on the form.

modal property not working

modal property not working Icon
I have a button on a form that opens a form called itemqueryform2 with this code:
Private Sub lookupitemsbutton_Click()
DoCmd.OpenForm "itemqueryform2", , , , , acDialog
I want it to open in a Dialog window, with the modal property set to No so that my user can switch easily between the dialog and the form she is using underneath.

In the properties panel, I selected Popup YES and Modal NO, but my form still does not allow users to click out of it without closing the form.

Trouble selecting active record in datasheet

Trouble selecting active record in datasheet Icon
Access 2007, not compiled, not split, skill level medium.

The form shows the default MealItems set for production. At the last minute the end user may need to select an alternate meal item, and substitute corn for green beans.

I have it set up so that the end user double clicks on the ItemName field on the data sheet and that opens a modal form with a query behind it.

I want the query behind the modal form to pick up the Meal3ID which is the primary key of the table behind the data sheet. and pull that record from the underlying table Tbl_ScheduledMealItems and display the fields on the modal form.

Everything works fine except:

The double click only calls up the first record in the underlying table. It does not pull up the active record (The one the end user clicked on.)

How can I make my double click on the ItemName field capture the Active Record clicked on and pull up that specific record in my Modal form

Form ComboBox Filter - Select ALL records

Form ComboBox Filter - Select ALL records Icon
I'm trying to filter records on a form with a ComboBox, and I want the option to return ALL records.
My Form is: frmReview
My ComboBox is: cmbGLimpact
The RowSource is: SELECT DISTINCT [GLimpact] FROM Initiatives UNION SELECT Null As AllChoice FROM Initiatives ORDER BY [GLimpact] DESC;
The Query Criteria is: [Forms]![frmReview]![GLimpact]
The field values are: Yes, No & TBD

The filter works fine for Yes, No & TBD, but the blank choice doesn't return all records.

I need to be able to setup several filter ComboBoxes to enable filtering on several different fields. So, depending on which ComboBox filter (field) the user wants to filter on, the otherswill allow all records to be returned.

How to apply a filter on form load

How to apply a filter on form load Icon
The are two properties on a Form property sheet that look like they should allow me to add a filter when the form opens. They are:
1) Filter
2) Filter On Load (I have this one set to YES)
I have a Query defined that I'll like to use as a filter when the form opens. How can I do this. And, no I don't want to change the record source to the form because I'd like to retainthe ability to remove the filter when the form is open to get back to all records.
I'm using Access 2010