In my access form I provide the user a list of locations from various countries in a listbox . But the list is too long so I provide him a combobox for selecting a country. Selecting the country should update the listbox showing only the locations in that specific country.
So my SELECT from the listbox must cover the unselected state and show all entries and when a country is selected it must narrow the selection.
I tried to get this happen with the following SELECT statement containing a variable. Choosing a country in the Combobox results in a change of the variable and in a requery. This works after the first country is selected and for each country change, but the initial list is empty.
VBA in the loadform 'Application.TempVars.Add "varcountryselect", "*" SELECT in the listbox "lstlocationsperproject" SELECT tbllocations.locationID, tbllocations.country, tbllocations.localstreet, tbllocations.localcity FROM tbllocations WHERE ((tbllocations.country) Like [TempVar]![varcountryselect]);
VBA in the combobox Application.TempVars("varcountryselect") = [Form]![kombcountryselect].Column(0) Me.lstlocationsperproject.Requery
The values in [kombcountryselect].Column(0) are texts like "SPAIN", "MEXICO", etc.
Any hints, how I have to use the * for getting the complete list on the initial view ?
I am using MS ListView SP2. While designing the application, I did it in my local drive. Since it is multi-user application, I have put it in a shared folder. The issue that it gives an error that there was an error loading ActiveX control on your form.
Has it to do with reference? Do I have to give reference in all the machines ?
Hi I have placed a ListView on the form. I have written a DblClick event for the ListView. The application is a multi-user one. The issue is that the DblClick event was working for few days and now it does not work for any of them but it is working only in my system.
Is it related to reference ? I developed the tool on my system and placed in a shared folder from which everybody uses. Do I need to give reference in all the system ? Please help. I am stuck with this problem.
I dont know if this is possible but I want to change a yes/no field from a list box.
I can load data in fine I can even loop through it to see what value each item is but, is it possible to allow a user to change a value from a list box?
I have a form (frmHourEnter) with a combo box (Staff_ID) that lists staff members from a table (tblStaff). The table form (frmStaff) has a checkbox (ckEmploy) which indicates if a staff member is still employed. If the checkbox is checked how do I exclude that staff member from the combo box Staff_ID in the form frmHourEnter?
I have created a form with a list view (active-x) to be able to control colors, etc in a list.
When I open my form, it is already information (three rows) in the list view. This despite the fact that I have shut down the access application and even shifted the database to another computer.
I can of course delete the elements with ListItems.Clear when I open the form, but I'd rather like that they did not show up at all.
Where these "default-elements" are stored, so I can remove them from the list view once and for all?
I have some issue when i save list view data in a access table.In form I have a list box(listtotalcount) and one text box(ID). In form load event I run a query on that list box like: "SELECT count(id) FROM table A" and it gave me the correct result. Now I want to store this data on a different table (table b) and I use this code:
Dim db As DAO.Database Dim rst As DAO.Recordset Set db = CurrentDb Set rst = db.OpenRecordset("table b", dbOpenDynaset)
[code]....
But the problem is when I click the save button it store only id not the list box value.
I have a form with a subform that has started a strange behavior... Periodically (no apparent pattern) whenever I leave the form (go to next record, print report, send an email...) the field list (Add Existing Field) box pops up. I always thought that those boxes (property sheet included) displayed or were hidden based on the state the last time it was used in Design View. I have confirmed that all forms and subforms do not have the boxes in display state in Design View.
I can go into Design View, close the box and all is well for awhile. It seems to happen more frequently when I go to print a report based on the data on the current form. My question is - what causes the Field List or Property Sheet to toggle on/off and can I suppress it either on a form or in the VBA code?
Here's a query that the bottom listview in the attached form i.e. a listview representing a table of calls(many) to fims (1 top listview)
Code: SELECT calls.id, calls.firm_id, calls.called, calls.said, calls.spoke_to, calls.next FROM calls WHERE (((calls.firm_id)=[firms].[id])) ORDER BY calls.called DESC , calls.next DESC;
When I run the thing...I get a dialog asking me for firm id.
I want to change this so when I move up and down the firms LV (top)... the bottom LV updates taking firm id from the top LV with focus.
i have two tables, tblgroups and tblrecipes on a frmReview i am displaying the groups in a list box so that user selects a group and sees relevant recipes ( which i am displaying in a subform after quering from lstgroups). Default value for lstgroups is "[lstGroups].[ItemData](0)" so that it always displays first goup recipes... (otherwise subform dont displays anything when i first open the frmReview) is it possible (which i am sure it is) that when i first open frmreview, the subform displays all recipes in all groups (whole database), so that when i select one group in lstgroups then it run query and filters the desired recipes. May be we can put "all" in lstgroups as first item so that i can use the default value..
I do not have the privileges to write code, but can use macros and Expression builder. I have written a bunch of queries and made reports for each of them. What I want to do is to be able to choose from the list of reports and view the chosen one. If that cannot be done without code, then to choose from a list of queries and then view the report made from the query. The user needs to be able to choose.
I have a Form which I have linked correctly to a subform. The Text boxes are showing in the Design view but are not when one switches to the Form View. Labels for Fields are visible in the Form View. Have even created a new subform and that will also not display the Text Boxes.
Why the ability to view the properties of an object within a form is not available when you double click on it in design view?
I was happily working away double clicking on a command button to edit some code when for some reason the next time I tried to edit it did not open up for me.
I was unable to access it even by right clicking on the object & selecting properties as that also appears to be disabled, not greyed out or anything but just does nothing when selected.
Have I inadvertently changed a setting somewhere that prevents the properties from being displayed?
I have seen that in some sample db's rightclicking the mouse showed the menu with an option to check or uncheck the dataview option, unchecked the formview was applied, but when i 'just' import the subform, i cannot find somewhere the possibility to change from dataview to formview.
Maybe someone can help me with this, probably very simple(?), question?
I have a table called NewTransactions_tbl that I have been using for some time. I am trying to add a new field called CustomerProjectNumber. It's not being displayed when I look at the table view. I've attached an image showing the settings for the field. I am probably missing something obvious.
I have 4 tables and around 440 records but can only view up to 417 in the form I have designed. I have been adding new records via form and it has been added to my main table, but when i try to view it in form view - the record is not available to view. What do I need to do to correct this problem?
I have checked that there are no filters, data entry is set to No, Auto deletions, additions and edits are set to yes.
Also to mention it seems that the problem has arisen since I set up some new queries, there is a one to one relationship between the tables!
I want to "zoom" to the underliyng data from pivot view. When in excel someone doubleclicks a field in a pivot table, it automatically creates a table containing all the lines that field were made up from. I want to achieve the same behaviour in Access.I started to think towards a VBA coda, that could be initiated from the form's double click event. It should go to datasheet view with the prpoer filter criterias.
I have a form which is opened with a filter from another form. For some reason it views the form in form view, although it was set up as datasheet view. I even went to the form properties and the default was datasheet and i made it not to allow other views. This still didnt solve it. I want it to be in datasheet view because i want to show multiple records at the same time.
If u kno how i could resolve this please offer ur help
Hi, I am in the process of creating a new database - I am a bit new to this. I have a main form, which also contains two subforms. The record source of the main part of the form is 11 tables, and then each of the subforms is based on one table each (so there are 13 tables altogether).
Everything seems to be linked up ok, and when I add new information to the form (and the subforms), the information gets saved to the tables as it should be. However, I want to be able to view past records in the form view, so that users can regularly update past records using form view. I can't do this. Each time I open the form view, the thing at the botton left says 'record one of one.' THen if I put the curser in (for eg) the box called 'client name' and click on the search button, I get a message saying:
"you can't find or replace now, the fields are not searchable due to: - the fields are controls; - the fields have no data; - there are no fields to search."
well I don't really know what that means. There is definately data in there somewhere, because I can view it in the table view, but I'd like to be able to view and update old records, and search, in the form view.