I have a form which has a listbox listing all the letters a student has had sent home. Basically i want to be able to click on a letter in the list box and for a popup form to open with the record details. However it just brings up a blank record.
The list box has a unique field called standardletterID.
the code behind the button to filter was just used through the wizard to open the popup form is:
Dim stDocName As String
Dim stLinkCriteria As String
Need help on a list box issue. Solution is probably real simple, just can't see it with my bleary eyes.
I have a form (INSTLKP) with only a list box (List6) based on a table ((tblPersData) with fields PersdataID; SSN; Last; First; MI) on it. When I open the form up, the listbox does display all records associated withthe table. I would like to doubleclick on a desired SSN in the list box and have that record open up in a form (Perssub1) in edit mode.
And that is where the rub is... I have the following code in the On doubleclick event of List6
I am a newbie in access and would appreciate if someone could help me with a delicate problem i have
I have listbox in formA named "Liste1", this listbox contains a departmentvalue (unique) in the first column shown in the listbox.
What i want to do is open a new form (frmStructureDetails) by doubleclicking on the listbox, and i want the new form to load with filter on that department. Btw the departmentvalue is textformatted.
The result i get is a dialoguebox opening and not seeming to recognize which value to use, if i fill inn the value i clicked on the form loads with the correct data.
What am i doing wrong:
Private Sub Liste1_DblClick(Cancel As Integer) On Error GoTo Err_SearchList_DblClick Dim db As DAO.Database Dim rst As DAO.Recordset
I have a list box that is correctly listing resources from a table (tblResource). I would like to select one of the list box entry and run a query against the tblResource to show the information for that resource in a form. I have tried to use the lstindex with the control (lstResource) in the where clause of a query to accomplish this with no success.
I have a form with a Listbox which lists Customers and a variety of customer information
I also have a table on the form that lists the donations that customers have made.
How can I populate the Table based on the customer that is selected in the Listbox?
There is an ID field that links Customers with Donations
I'm guessing I need some code in the ListBox_CLick() event that triggers the table to query or to Load with a query based on the ListBox.Column(0) which contains the ID?
I use the follwing code to filter a report based on the listbox selection on a form. Below is the code I use, the problem it will error if the results have an apostrophe in the string.
Private Sub FilterDesc_Click() Dim strWhere As String Dim ctl As Control Dim varItem As Variant 'make sure a selection has been made If Me.ListCarrier.ItemsSelected.Count = 0 Then MsgBox "Must select at least 1 Carrier"
I have some code that was written by someone else. I am trying to duplicate this in another database but, can't seem to get it to work. I also don't understand how this code is working as as there is no reference to the combo box in the code behind the print button. But depending on what you select in the combo box the report opens and filters on that selection. The following code is behind the print button. There is a separate combo box, that does not seem to have a connection to the print button. It just has a query behind it for the items to select from.
Public Sub BTNPrint_Project__Job__Numbers_Click() On Error GoTo Err_BTNPrint_Project__Job__Numbers_Click Dim stDocName As String stDocName = "RPTProject Number (Job) Book Year" DoCmd.OpenReport stDocName, acPreview Exit_BTNPrint_Project__Job__Numbers_Clic: Exit Sub Err_BTNPrint_Project__Job__Numbers_Click: MsgBox Err.Description Resume Exit_BTNPrint_Project__Job__Numbers_Clic
My form has a listbox (lstHeatTreatments - Multi-Select disabled) that displays Heat Treatment descriptions and an unbound textbox (txtHTDetails) that I would like to have display the corresponding memo field when a description is selected from the listbox.
This is my code so far:
Code: Private Sub lstHeatTreatments_AfterUpdate() Dim myConnection As ADODB.Connection Dim myRecordSet As New ADODB.Recordset Dim mySQL As String Dim selectedRequirementKey As Long Set myConnection = CurrentProject.AccessConnection Set myRecordSet.ActiveConnection = myConnection
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 ?
Okay then, after much trouble and confusion, I finally realized I need to use an Extended listbox in order to allow for multiple items to be selected from a list on my form (rather than the evil multiple selection combobox!).
However, now I am trying to figure out how to make one listbox (IndustryClassification) only be visible if the item "Industry" is selected in another listbox (TypeOfBusiness). Coding I can use for this in the AfterUpdate event of the listbox?
I have a list box on a form with 10 items to choose from. When a item is chosen I want a form to open (OnOpen or OnLoad Event ??) with a recordsource depending on one of the 10 items chosen in the list box. The recordsource is an sql statement which will change/depend on the item selected The 10 items refer to 10 different tables.
I have a form, with 2 Combo Box's and a List Box. The Combo Box's provide a search criteria and the results are displayed in the list box [searchList].
I want to be able to double click a record in this List box [searchList] and that will open a from [frm_SearchDisplay] with the selected record from that List Box [searchList]
Can someone please point me in the right direction.
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
Is there a way to take a form, select the fields that you want to display on a template(I created the template)? Then the fields that aren't selected grey/disable them? In other words. We perform several tests, ie. test 2006.01 and 2006.02 etc. Each test is based on 1 table. So instead of having to go in each time a new test is needed, can I create a form that has selectable fields(checkboxes), and once I say ok it opens the "new" template it will have the fields that need to be on that test then grey out the ones that aren't going to be used this time around? Sort of new to this....
I have a listbox on a form that show all Files for a particular volunteer. I have an "Edit File" button below the listbox to be able to edit that particular file. Is there a way about opening that form to that specific record without using a query?
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.
I have 2 forms: frmExcEntry and frmItemSearch. frmExcEntry is a data entry form where the associate enters PO#, Item#, Qty, etc. frmItemSearch is a popup form that is used to narrow the search of the Item# from frmExcEntry. Right now, when the associate types the Item# (either PartNo or FactNo)in the txtItemNo control on frmExcEntry, frmItemSearch opens (frmExcEntry remains open) with all potential item #'s associated with the text entered in [txtItemNo]...(there could be multiple FactNo in our inventory system but PartNo is unique and the bound field for the control). frmItemSearch uses an unbound textbox (txtSearch) that populates with the text from frmExcEntry on txtSearch_GotFocus and queries a listbox with the list of possible PartNo to select. I want the associate to be able to double-click the accurate PartNo from the list box which will then update the value initially typed in txtItemNo and copy the PartNo over txtItemNo in the currently open frmExcEntry.
The user will be creating a new project that contains a bunch of releases. The releases have standard names which are stored in a table tbl_ReleaseNames It should be noted that the list of names is not static.
The user selects which of the releases pertains to their project and then based on their selections, new records would be created in tbl_RFP_Release and then a subsequent form would open where it would display each of these newly created releases where they could enter additional information. I thought of creating an unbound checkbox associated with each of the standard names, and then checking to see if the checkbox was checked and then creating the new records followed by opening up the new form.
I have almost completed my database, everything I had originally intended to implement into it has been done, with some extra added features I popped in along the way. There is just one more thing I require assistance with...
My database is used for booking camera kits in and out. On the add booking form the user has to pick a "Camera Type" from a combo box. When they have made their selection, a form pops up with details of all of the components contained within the kits. The user can then check/uncheck the relevant components and close the form.
I have used a command button which prints off the data contained within the current booking form, and also the data contained in the form that pops up when the camera type is selected.
However, as there are more than 1 different types of camera, comprising different components, I need to be able to print off the form relevant to the kit type.
I do not know how I can do this as I have just specified the command button to print the form for the default kit.
I basically need some VB code which will print the form based on my combo selection, as my knowledge of VB is pretty primitive, I was wondering if someone could help me out :)
Greetings! This forum has been most helpful to a rusty Access user.
I'm creating a student group score entry form, having problems with creating the form I want. Say for example we have the following: 1. Three groups: A,B, and C. 2. Group A has 5 students, Group B has 3, and Group C has 20.
I want a form where I can select group A, and a list of the students will populate and enable me to enter scores for all of them on the same page. This will save time not having to re-enter the information for so many students. If anyone has a clue of what I'm talking about or is willing to lend me aid, I would appreciate it.
We have an access database which has a form that has a list box that details particular records. See attach "list box".
What I would like to do is double click on the record and this would look in a powerpoint folder (see attach "path") and open the presentation if there is a match to the value in Listbox Column 5 i.e. Tool Number.
I can get it to open the presentation if I include the tool number in the path but I cannot seem to be able to get it to compare the values and only open if there is a match.