Hi,
I have a requirement to filter some queries periodically on the date field.
What I want to do is create a form that lets you choose which query to use and filter and not create alot of single forms.
The filter will be only be applied whilst the form is open.
I would like to set up a query that uses two tables. One of the tables, the 'main table', wil be used every time the query is run. Each time a new record is created in the main table a 'new table' is created containing a subset of data - the name of this table uses a ref ID from the main table. I would like to be able to select which 'new table' to use in the query as part of a parameter query.
eg. Main table record 1 has a field JID of J0001 and a corresponding 'new table' titled J0001. record 2 in main table has JID J0002 and creates a 'new table' J0002 etc
so I would like to set the query up such that when a record is chosen in 'main table' the query knows the name of the 'new table' corresponds to the JID of the record in 'main table' ....
Have seen the same question asked but no answer - is this possible ?
Hello, i was wondering if you could help. I want to run an update query, taht updates prices in a table. But i would like to be able to choose the criteria when the query runs, for example a message box appears, that will allow me to enter a certain amount for the prices to change by. Could someone guide me on how to do this? thankyou, its much appreciated
I want to have users be able to choose query "x" "y" or "z" from a listbox. Upon selection of query "x" "y" or "z" from the listbox, I want the query to run? I want to run this query from form "RunQueries" Does anyone know how I can do this? Thank you in advance for any suggestions, I appreciate all the help I can get
I have an option group that lists a variety of categories which I want to query on.
I know that the option group only returns values.
In the Option Group, On Time = 1, Over Due =2 ,,,,
I am using a Choose function in my query. That is working fine. But ... I would like to have a last choice called "All" such that when selected all data is shown (i.e., On Time, Over Due, ....).
I am using the following:
Choose ([optiongrpStatus],"On Time", "Over Due", .... ,???) as my query criteria.
Have not figured what I can put in the last choice to get all data.
Tried "Is Not Null", tried "On Time or Over Due" - know these don't make sense -just wanted to try.
I'll start by saying that I'm not sure which sub-forum to choose, as my question(s) covers several areas, so I have tried with this one first.
I'm currently making a database, which among other things contains a 'Port of Call list' table. I have a form, where I can add data to this table, meaning, that whenever a vessel has left its port, user can update following: Port name, security level, arrival date and departure date.
What I need is two things (it might be more or less the same):
1. When user click a "Generate" button on a form, the 10 latest port calls from the table, should be shown. I'm not sure what kind of control is the best to should the list on the form. Code is also needed.
2. I would also need to be able to print the list. It should be part of a report. Again which controls/which code to be used is needed.
I hope that someone are able to assist, as I have no clue what to do.
I have a form that has a bunch of check boxes on it. The user selects specific check boxes My code then has a few If then statements to test which ones were selected. With each one that is selected a query is run to select specific records in a table. (querying out the values from an email field) The user then hits a button to send the email. Microsoft Outlook opens and the emails list is added to the "To" in the email.
Everything works great...But I have a slight issue. If a user has permissions on more than one account when they go to send an email they have the ability to choose a "From" (thus specifying which account to send from)
The user can currently select which one they want but I want this to be more automatic.
CAN i specify which account to send from automatically when the email opens. BUT Just for this application...
Does that Make any sense?
THanks in Advance
Code:Private Sub Command23_Click()' This section is Calling seperate Subs that verify if a Radio Button is selected' If selected it builds the string needed for the email.Call TestCheck3Call TestCheck5Call TestCheck7Call TestCheck9Call TestCheck11Call TestCheck13Call TestCheck15Call TestCheck17Call TestCheck19Call TestCheck21Call TestCheck24Call TestCheck26Call TestCheck39Call TestCheck41Call TestCheck43' This part concatenates the email string being build andDim FinalEmailString As StringFinalEmailString = ""FinalEmailString = Test03 + Test05 + Test07 + Test09 + Test11 + Test13 + Test15 + Test17 + Test19 + Test21 + Test24 + Test26 + Test39 + Test41 + Test43' THIS SECTION TESTS THE CONCANTENATED STRING TO SEE IF IT IS NULL' IT THEN GIVE THE USER THE CHOICE TO CONTINUE WITHOUT ADDING EMAIL' ADDRESSES OR TO STOP AND MAKE A SELECTION.If FinalEmailString = "" Then Answer = MsgBox("You must first select a Group to email, if you wish to continue without adding an email list just hit No", vbQuestion + vbYesNo, "???") If Answer = vbYes Then Exit Sub Else ' This part sends the string to the email and opens the email DoCmd.SendObject acSendNoObject, , , , , FinalEmailString, "Alert Group", , True End IfElse ' This part sends the string to the email and opens the email DoCmd.SendObject acSendNoObject, , , , , FinalEmailString, "Alert Group", , TrueEnd IfEnd Sub' EXAMPLE OF ONE OF THE QUERIES BASED ON THE CHECK BOXESPublic Sub TestCheck3()Test03 = ""If Check3 = True Then Dim dbs As Database Dim rs As DAO.Recordset Set dbs = CurrentDb Set rs = dbs.OpenRecordset("Select * From tbl_Business_Name WHERE TYPE = 'APARTMENTS'", dbOpenDynaset) Dim strTO3 As String strTO3 = "" Do Until rs.EOF strTO3 = rs!EMAIL & ";" rs.MoveNext Test03 = Test03 + strTO3 Loop rs.Close 'Close what you opened. Set rs = Nothing Set dbs = NothingEnd IfEnd Sub
Any way to automatically choose next in sequence via form entry in Access 2007.We currently have an excel spreadsheet tracking who attends review meetings for new products. There are 12 people who are eligible to attend the meeting, and the next person in the sequence should be chosen when a new meeting is scheduled. I'll be adding this to an existing database with an "associate" table- where each associate name is assigned a numeric value, if this can even be done.
The problem is that the logical order may not always be followed. Associate 8 might be up next but be on vacation, so Associate 9 is sent in their place. We can't skip over Assoc. 8 completely so we'll go back to them once they're back in the office, but we don't want 9 being sent to the next one after that again. Or the manager might determine one associate has more knowledge in the area of the new product being presented and send them out of order. In Excel it's easy to see who is up or who has been skipped, but in single-form data entry in Access the pattern won't be visible.
I'm making updates for the front end then i send it to 10 pc's in the office then i should change the backend location via linked table manager for every pc
So is there any way to let the user choose the backend location when he open the database nad then it will automatically update the tables link
Is it possible to have a form designate which FIELDS to include in a selection query? I know that I can determine criteria and such, but i want the user to be able to generate a report based on the query select a, b, c from blah, or if they wish, just select a, b from blah...
Hello, I am wondering if it is possible to have several combo "boxes" in one form. The form is based on one table. In the table there are several fields which use a look-up (combo) drop down box to choose from: Type, Description, Manufacturer and Location.
In the form I want a combo box for Type, to bring up specific records in a subform, then I want a combo box for Description to bring up another set of records (within that Type of equipment) and a third combo box for Location to bring up all equipment within that location.
When I have tried to set this up - it changes some of the data in the in the subform - which changes it in the underlying table. If it set the form to open in New Record, then nothing shows up in the drop down box. Is there some If, THen code I could use to make it look first in the Type, then in the Description field, then close those out and look for the set of records that match in the location field?
Does that make sense?
I know how to manipulate in MSAccess templates, etc., but I don't know much about the underlying codes.
Does anyone know how to create a form with a listbox that lets u choose reports and preview or print at the click of a button. I know you can do it wil tables and queries but I need it to do it for reports.
Including check boxes (representing the query fields) in an interactive access form, in order to decide which fields should be visible.
I think the solution is building an invent in VBA for each check box, however I'm not an expert in Access VBA and don't know how to write the code.
In the example that I've uploaded, in the Form1, when I run the query, all fields are displayed, i.e. VENDOR, REGION, CUSTOMER and MATERIAL are displayed. How can I manage it in the form with a listbox to display only the REGION or MATERIAL for instance.
I created a form that allows the user to choose the criteria that they want to see on a report using =Forms!formname!controlname in my query. It works great but I want to also allow the user to choose nothing and return all records instead of limiting them to choose just one type of record. Is this possible? Before I created the form my query had the [Enter parameter] on one criteria line and [Enter parameter] Is Null on the next criteria line and that was working great for my use but I need to create a simple form for other users.
Is there a way to automatically choose a value such as 0 if the expression goes to a negative number?
E.g. I have a query that will subtract a numeric field from 10. If 10 - [numericfield] is less than 0, then I only want it to display 0. Otherwise, it can display the value if it is positive.
I am looking for some help with a particular problem. I have a report based on a query and at the moment it is ordered by a particular column.
What I want to be able to happen is that the user chooses what they want the query (and subsequently) the report to be ordered by before they run the report by means of a combo box or something like that.
I am setting up an Access database for a small school. The database contains a record per person. When we get a duplicate lastname field we set a family_id field to lastname followed by a number.
So for example the first Smith family needs to family_id. But the second Smith family gets a family_id of smith1. To select an ordered list of Families I need a query that will use the family_id if it is set and if not use the the lastname to collect family members.
My query uses a presorted table, CurStuByGrdTbl , of current students to produce the families directory by grade and alphabetized.
The WellSchoolCommunityAll table is the entire database. So if the student entry has a valid family_id, matching pattern "*#" then
I perform a Like with family.id otherwise I perform a Like with lastname.
This query gets me nothing, no records.
IIf(([CurStuByGrdTbl].[family_id]="*#"),[CurStuByGrdTbl].[family_id] Like [WellSchoolCommunityAll].[family_id],[CurStuByGrdTbl].[lastname] Like [WellSchoolCommunityAll].[lastname])
I am building a database that calculates freight costs for shipments.
I have one table that has order data with fields such as [Order Number], [Origin], [Destination], [Service Level], [Weight].
The service level is one of 4 values: PRE 9, PRE 12, NEXT DAY, NEXT DAY +1.
The origin and destination use country codes such as BE, AT, CZ, PL for Belgium, Austria, Czech, and Poland respectively.
I also have rate sheets from carriers such as DHL and UPS and they provide their rates in the following format (numbers are made-up as real rates are confidential): [Origin], [Destination], [Service Level], [0 to 0.5 kg], [0.5 to 1.0kg], [1.0 to 1.5kg], [1.5 to 2.0kg], etc all the way up to 30kg. The rate is then in the appropriate column and the row gives the origin-destination-service level combination.
(sample freight rate table uploaded as zipped excel sheet in attachment)
I need to return the rate from the appropriate row based on the [Origin], [Destination] and [Service Level] fields (easy enough), which is easy enough.
The hard part is selecting the correct field to return. I tried usign a Choose expression but Access rejected it saying it was too complex (maybe because too many choices?).
So I'm stuck. And working towards a deadline... :-)
I built a db for tracking and entering sales info but I'm having a problem with one of my combo boxes. To make entering data easier, I created a combo box that you can select a sales persons name from, then based on who is selected, their Title and Office location also populated.
The problem I have is when I want to manually type in the Name and other info for a temporary sales person. How can I allow users to choose from the drop down or just type it in if that person is not in the list?
Can anyone create a form with a combobox where you can select a form and this form will display in an static area. Then you can choose another form in the combobox and it will display in the same spot. the forms that will be displayed are exactly the same size.
I'm trying to create a pop up form that asks userto select months for a report to preview. I've writtent he query and done the report. I can do the command button to get the selectmonth form to pop up, but not sure how I pass the selected months into query for the reports. Any tutorials on this or can someone help. I've been looking around but nothing quite fits. Quite new VB also, but have a good understanding programming generally.
UMMonth1: Choose([Enter Qtr],[OperationsAuditData]![1],[OperationsAuditData]![4],[OperationsAuditData]![7],[OperationsAuditData]![10]).But I keep getting an error message "You tried to execute a query that does not include
I have Access 2013 but am new to Access and am learning as I go along!I am making a database of song lyrics so have made a table of the title of the songs with the lyrics for each verse as different fields. I want to be able to choose multiple songs by their title to then show the full lyrics on a report.
I am new to access. What I want to do is to set up a button in where the value that I typed in a text box besides it, be transferred to the corresponding cell type.
Let's say I typed 100, and then I click Income or Expense, If I press Income it will be sent over to the cell containing the incomes and etc. A check box works too.
Next thing that I want is to create a sub category.
If I have a large categories list like in the personal account ledger template, I want to be able to select a main category and if it has a sub category, give me a drop down box to select the corresponding one.
I enter my value, choose whether its income or expense, date and etc, then if I choose the "Home" category, I want it to allow me to also select whether its "Phone", "Water" and so on.
name/ score/ peronal best) -> logic if participant has only one score - this remains his/her first best; if more than 1 scores - then the lowest gets 1st best, second lowest - 2nd best, etc....