this is a re-post - can anyone help? I think this is an easy one for the experts out there!
I have a form called frmTshtExp which is bound to a query called qryTshtExpenses. Most of the fileds in the form are combos and text boxes bound to the fields in the queries.
However, the first combo is unbound. It is called cboProjectSelect and it filters the second combo called cboWorkstreamExp. This is done using a query called qryTshtWorkstreamExp which has workstreamID, workstream and projectID as fields.
The filter works fine. The trouble is that selecting a project from the first combo filters workstreams from the second combo for ALL records that are entered. In other words, no matter how many rows are entered in the datasheet on the form, they all have to have a workstream belonging to just ONE project. I want to be able to enter different workstreams belonging to DIFFERENT projects on each row.
I hope you can help. I've put in a reduced version of my db in the following location:
unfortunately, I didn't know how to disable the securities I've set up, so you need to log use the shortcut (after modifying the target location in it's properties) and use the word "forum" as username and password.
hi all, another quick question (last one for awhile I promise) but is there a way to add an option to a combo box (Filter by Selection) and Remove/Filter sort without right clicking on it? cheers, Andrew
My form has a combo box which is bound to a query that selects a list of member numbers. The value selected the goes onto filter a list driven by an SQL statement.
Code: Private Function PopulateADO(qpMemberNo As Long) Dim cnn As ADODB.Connection Dim rst As ADODB.Recordset Set cnn = CurrentProject.Connection Set rst = New ADODB.Recordset
[Code] .....
This works fine when a single member is selected from the combo. But obviously i want a "select all" or * wildcard option.
Question is 2 parts. 1. How do i add the all or wildcard option to the bound combo? 2. How do i code the all or wildcard option into the SQL statement? Is it something like is not null ?
Hi every body. I got bounded form as picture below. Initially the form loads all the recod. I want add a feture to this form so that when i make 4 combo box selection it goes and load those records that matches that crieteria only . All my controles are in the main form. I am not using form and subform.I be happy if some one show me how i can switch from show all mode to filtered mode.(an example higly appretiated)Thanks
http://i5.photobucket.com/albums/y180/method007/comboboxfilter.jpg ( form pic)
I have a form where you enter a Case number (Primary key) and EmployeeID (foreign Key), the employeeID must match a employeeID held in the employee table. Within this Case form, I have a subform called Account which has an autonumber Primary key called accountID. Each of these accounts will have a questionnaire. So I created the questions in the same table (account). So Q1, Q2, Q3 etc. which are Questions relating to each AccountID, one accountID can have one questionnaire.
What is working fine is I can enter an account NUMBER which is a field in my account table (which creates a new AccountID(autonumber)) and can happily check the checkbox, fill out the text fields move to the next record and the checkbox is unticked and text boxes are blank (default state) which is great as I want them to ready for new input (new accountnumber/id).
My problem is assume I create my very first account number which would be say AccountID(0), I want all textboxes for the three questions disabled until the checkbox is ticked. So thats ok, I can put the default value of chkbox to FALSE, and in VBA I can do the on_checkbox_click, if chkbox.value = true then textbox1.enabled = true else textbox1.enabled = false. I can do that for the other two textboxes in the Chkbox click event.
When I Tick the checkbox it enables the textboxes, which is good, but when I create/move to the next record, instead of these textboxes being disabled as default, they are enabled because i ticked the chkbox for the first record. I dont want the manipulation of one AccountsIDs questionnaire to affects the other records. If I add an unbound textbox which I want to display a message if the chkbox is ticked, then if I tick it on one record, it has the displayed message on all records. How can this be if each questionnaire is independently i.e each questionnaire is for ONE accountID.
It seems the textboxes etc are not unique to each accountID but they should be because they are in the Account table and when I enter values and use the checkboxes without doing the disabling or showing a textbox comment, they are separate and work great, but when I use my code to manipulate the flow of a questionnaire for each account i.e enabling textbox/showing textbox comment, it changes the formatting on the other records questionnaire which I don't want as each questionnaire will be different, so a chkbox may enable a question on one ID but not on another as it wont be relevant, so at the moment I only have ONE truly working questionnaire which works for ONE account , but I want it to work uniquely for each account.
I have a strange problem that has me beaten. I open an Access 2003 table, sort on field "Job Number", click the Find button and enter a job number. I expect to find 30 records, but Find only hits 8 of them. If I over-type the Job Number (with the same numerics), Find is then able to return this record. If I place my cursor in ANY of the 30 records and click Filter by Selection, all 30 records are included. I thought there may be a non-printable character or a space hidden at the end of the field, but I expect both Filter and Find would return the same records. Even more strangely, when my client zips the MDB file and emails it to me, this behaviour does not occur on my PC. Has anyone else comes across this behaviour? If so, can you please point me in the direction that will help me find a solution. cheers, Mark Chimes
I have been building a database for use in a charity shop and am struggling with an issue regarding one of the forms.
I currently have a form which displays all expenses from the shop. I have added a combo box to the top of this form which allows users to filter records based on an expense ID Code. It all works fine but I would like to be able to add a start date and end date box to the form also so that records can be shown between two dates.
I have tried adding parameter boxes to the query which runs the form (which works) but the issue I am having is that when a new id is selected from the combo box the parameter boxes pop up again asking me for start date and end date again. This happens every time a new combo box id is selected.
I think the way resolve this issue may be to add a start date and end date box to the form but I don't know how to implement this.
Please see the attached files for images of what I currently have. The forum won't let me post images directly here until I have 10 posts so I have had to attach the files instead.:
Query running the form - Attachment 1
The Form itself - Attachment 2
Combo Box - Attachment 3
Bound Column on combo box - Attachment 4
Code in Combo Boxes after update event - Attachment 5
I have seen a few articles here and there on using a combo box to filter records in a sub-form and to filter records in another combo box, but I am not getting anywhere. I hope someone can belp
Exercise 1
For this exercise, I have the following tables:
tblClients containing client names tblProjects containing some project details
I want to set up a simple form, so that the user can select a client name from a combo box on the main form which filters the project detail records in the Projects sub-form. Once the user enters project details, I want this info as well as the selected ClientID to be fed back to tblProjects.
Exercise 2
I have the following tables:
tblProjects as above tblWorkstream containiig names of workstreams and some other details.
Every project has one or more workstreams
I have a form where users will enter hours worked on each workstream. They will first select Project from a combo box on the main form. This should then filter records to be displayed in the Workstream Combo box, before they can then enter hours.
Please let me know if you need me to explain any part of this better.
Thanks in advance.
ps. I am a novice, so I'm hoping to do the above using default MS stuff, not with complex programming!!!
I have a combo box located on one of my forms, that is getting its information from a field in a table.This table has all its records displayed in a subform. I would like the combo box to basically requery the subform to only show records where the name matches what is in the combo box.
It is basically a list of customers, so if I was to select Person1 in the combo box, I would only want to see records for Person1 in the subform.I would also need a way of clearing the search results, in order to get the subform to display all records again.
I am using combo box to filter records from a form. The data source for the form is from a query.
I use the combo box within the query to filter the data, I would like the form to refresh/ run the query again every time a new selection is made from the combo box.
i have a combo box, which looks up a list of school names from my main table. The user selects the desired school, then clicks the button underneath, which opens a report. What i want the report to show is the next 31 (that is how many fit on one page) schools AFTER the school that the user selects - the underlying query for the report has them in alphabetical order. There are ~250 schools in the list.Even if i can get it just to display the records after the selected one on the form, that would be fine.
I have a table with the following 5 fields. (Service Type), (Valve Name),(Size),(Rating),(Description).
I want to do two thing:
First: I want to select the required information from the first 4 fields using combo boxes and get the last field (description) based on the selected 4 fields. In other words, i want the record to be filtered using first 4 fields to give me the last field info.
Second: I want to store the filtered record (all 5 fields) in another table.
I want to filter the records in a combo box (cboSupplier) using the In() function.
On the form I have an unbound control called "intFilter". It contains the following string: 23, 58
The SQL statement for the combo box is
Code: SELECT SupplierID, SupplierName FROM tblSupplier ORDER BY SupplierName;
In the criteria for field SupplierId I want to use the In() function so that the only records returned by the combo box are those in "intFilter". I have tried
Code: In (Forms![frmSupplierReport]![intFilter]
but this does not work.
If I put: In (23, 58) in the criteria it works, but I cannot hard code it because the string in "intFilter" will change on the fly!
could anyone point me in the right direction? i am trying to create a filter text box where i type in a name and if the name is in the field of my form, it will autofill and then when i press enter, it will select that particular item. for example; i start to type my name ( Nigel ). as i start Ni, it fills in my name and then after pressing enter, loads my information.
another option was to have a pop up form with a combo box offering the names to select and then by pressing go, loads the info onto my main form but not quite sure how feasible that is. any help appreciated.
I have serached for the answer but can not seem to find it.
I have a combo box that when a value is selected it finds the record.
I have four fields with one hidden. The fourth selects the lookup in another table and only shows the value. I am unsure how to have it show the project name instead of the id.
I have two combo boxes on the same form bound to a table. I want the contents of the next combo box to change based on the previous combo selection e.g
cboContinent cboCountry Africa Zambia Africa Congo Africa South africa Europe England Europe Holland
If I choose Africa in cboContinent, I want to see only Zambia, South Africa and Congo under cboCountry and if I choose Europe I want to see only England and Holland
I'm have quite a difficult time getting a form in Access 2010 to perform the way I would like it to. I have multiple tables that I've created, and a query that contains the data from the various tables. I then ran the form wizard to select the data from the query that I wanted to populate in my form and I've added 2 combo boxes.
What I want to do: 1. I want users to be able to select a category in combo box #1 (example: "Bag") 2. I want users to be able to select a detail in combo box #2 based on the category they selected in combo box #1 (example: Combo box #1, "bag" would populate the following selections for combo box #2: "sandwich" and "tool") 3. I want users to then receive a list of suppliers that provide the product they have selected, either "Bag: Sandwich" or "Bag: Tool"
I have combo box #1 populating a list of categories already. However, I am not able to get combo box #2 to provide choices based on the selection chosen for combo box #1.
Hi, I am trying to find code that will let me put a command button on a search form. When it is clicked I want the command filter by selection to filter the records. Basically copying the command when you click the button on the toolbar :rolleyes:
I would like to place a "Print Report" button on my primary form that allows a Filter By Selection (OR Filter By Form) first, then when selecting the button will view or print my already-created primary report but only for the records that were selected by the filter.
I looked and looked, but am not sure even what to search for in the forum. I know this has to be simple.
Form is called PrimaryForm. Report is called PrimaryReport.
I am currently working on a form for my users to look at budget data. I have several listboxes for them to filter queries by. What I was wondering is, if it is possible to have data in one list box be filtered by the preceeding listbox?
For example: Three list boxes: Report_Period, Budget, Dept.
Each list contains all the values possible. This data is all in a filter table (and the listboxes created using SELECT DISTINCT queries to that table for the specific field). So, if I select Budget XYZ, could I filter the Dept listbox to only show the dept.'s associated with that budget? These are all multi-select listboxes by the way, so budget ABC and XYZ would only show the departments associated as well.
I'm trying to hash two scripts I've found into 1 functioning filter, however I'm still relatively new to vba and can't figure out how to get this working.
I'm trying to use Allen Browne's Search Criteria:
with another snippete of code I found here:
Code: 'Purpose: This module illustrates how to create a search form, _ where the user can enter as many or few criteria as they wish, _ and results are shown one per line.
[Code]....
It's the date part I'm having trouble with, the rest of the search criteria work fine without the date, but I can't get it working when I try to modify and merge the date sections of each code.
Also I'm using a listbox for the "Yesterday";"Last 4 days";"Last 9 days" and not a combo box.
I have a query that gives field values like name, age, department, etc for all the staff members in our company. These fields are obtained from many other tables and queries. Now I am planning to generate a report, which would display the results of this query. The catch is I am trying to do it in such a way that I want the user to have the option to select for which staff members he wants to run the report. Example: if I have 10 staff members, the user should be able to select staff3, staff6, staff7 and run the report such that it displays all the field values from the query related ONLY to these 3 staff members.
I could put up some labels and checkboxes for each staff on the form, and then select some checkboxes and get the report to read which checkbox is selected, and then display the concerned results through the report.
I have a simple dbase that shows names in a table as "Smith, John" for example. My query links two tables, and should show all names in the aforementioned table. However, certain names are missing. Here's where it get's weird - if I change the spelling of their name (Smith, J for example), suddenly they will show with the correct data. There are no common strings to the missing names, but on each, when I change the spelling, each missing name appears. I have made sure the relationship is joined to show all data in the "Names" dbase.
How can I create a "Filter Button" on a form and filter my records? I create a textbox on a form and a filter button on the right. Then I click the filter futton, the filter function will search/match the content in the box through the datasheet. And then the results of the filtering will be pop up on the split form datasheet.
I'm trying to get one combo box control what tables are available from another combo box. Example, combo box (a) includes numbers 1-5. Selecting (1) makes the data in combo box (b) specific to that selection. Selecting (2) makes the data in combo box (b) something different (pulls data from a different table).