Help Needed Creating A Filter Form.

Feb 19, 2005

I need to have a form which has a series of blank text boxes on it.

I then need a subform, that has all of the text boxes as above, in datasheet layout.

I then want to be able to type values into the text boxes on the main form, and have the user then click a button. If any records exist with the values that have been typed in, they should be listed on the sub form.

If the main part of the form had combo boxes then that would also be good.

Finally, I want the user to be able to double click on one of the rows that have been found, and for this data to be loaded into a third form.

Is this possible? Could someone help me out, by maybe linking me to a source that will help me, by explaining how to do it, or maybe by letting me know where i can get a sample database that does this sort of thing.

Thanks very much.

View Replies


ADVERTISEMENT

Creating User Form Filter

Aug 2, 2005

Hi can anyone help me. I need to create a form filter that will allow a user to enter an amount into a text box and then run the filter to match the amount entered. I have tried creating a macro that will execute this but it wont work. any ideas?

Thanks

View 2 Replies View Related

Modules & VBA :: Creating Textbox In Form To Filter Combobox

Sep 16, 2014

I have a subform in datasheet view for tracking calls from clients. The Client Name is a combination of the first and last name. I want to create a text box that allows me to start typing in the client name and it will filter for only those Clients that match. Currently, I have the following code (below) for the textbox, however when I start typing in a client name all the clients disappear from the table. The client name is in a combo box so I don't know if that is making a difference.

Private Sub Text3_Change()
Dim strFilter As String
Me.Refresh

[Code].....

View 3 Replies View Related

Help Needed In Creating A Table Inside Db UsingVBA

Apr 27, 2005

Hi experts. i wrote this code that supposed to create table inside the access db but when i run it i
get this error:

compile error:
user -defined type not defined for Dim db as Database



Itt is a command button that calls CreateDatabase. I be happy if some one help me fix this. Thanks

My code:
Option Compare Database

Public Sub CreateDatabase()
' Routines to create the tables.
CreateTablePlayers
'CreateTablePenalties
' Routine to create relations for the tables.
CreateRefInt
End Sub

Private Sub CreateTablePlayers()
' Local variables
Dim db As Database
Dim tbl As TableDef
Dim fld As Field
Dim idx As Index
Set db = CurrentDb()
Set tbl = db.CreateTableDef("Players")
' Adding fields
Set fld = tbl.CreateField("playerno", dbInteger, 0)
fld.Required = True
tbl.Fields.Append fld
Set fld = tbl.CreateField("name", dbText, 25)
fld.Required = True
tbl.Fields.Append fld

Set fld = tbl.CreateField("initials", dbText, 3)
fld.Required = True
tbl.Fields.Append fld
Set fld = tbl.CreateField("birth_date", dbDate, 0)
fld.Required = False
tbl.Fields.Append fld
Set fld = tbl.CreateField("sex", dbText, 1)
fld.Required = True
tbl.Fields.Append fld
Set fld = tbl.CreateField("joined", dbInteger, 16)
fld.Required = False
tbl.Fields.Append fld
Set fld = tbl.CreateField("leagueno", dbText, 4)
fld.Required = False
tbl.Fields.Append fld

' Adding primary key
Set idx = tbl.CreateIndex("Players_PK")
idx.Primary = True
idx.Unique = True
Set fld = idx.CreateField("playerno")
idx.Fields.Append fld
tbl.Indexes.Append idx

' Add Table to the database
db.TableDefs.Append tbl
End Sub

' Adding Referential Integrity
Private Sub CreateRefInt()
' Local variables
Dim db As Database
Dim fld As Field
Dim rel As Relation
Set db = CurrentDb()
Set rel = db.CreateRelation("PlayersPenaltiesRel", "Players", "Penalties")
rel.Attributes = dbRelationUpdateCascade
Set fld = rel.CreateField("playerno")
fld.ForeignName = "playerno"
rel.Fields.Append fld
db.Relations.Append rel
End Sub

Private Sub Command1_click()
CreateDatabase
End Sub

View 2 Replies View Related

Forms :: Required Field Suddenly Needed During Filter

Feb 25, 2015

I have a form that I have opening in Filter by Form mode. It WAS working flawlessly, at least it was opening in that mode. It IS still requiring me to click on Toggle Fields once data is entered into controls to filter by, but that's another issue (I wrote a recent comment, but haven't gotten any response). Something different is happening suddenly that wasn't happening before. This form is a copy of a form needed to enter data.

Both forms read from a table which has several required fields. Suddenly, when I open the form to find records in ANY mode it's making me enter something into these required fields, even though I'm not searching/filtering by them. The message comes up "You must enter a value in the [Specific Required Field name here] Field." What did I do to make this start happening? How do I stop it? I DO want something to need to be entered in the required fields when new records are being entered and when things are being changed. However, I don't want it to be required during search processes.

View 12 Replies View Related

Creating A Filter Button

Nov 7, 2005

I have a combo box with different department names in it
I have a button in a form called cmdShowDept the caption "Show only one Department"

When I open the form I have the combo box set to not be visible
When the Show only one Department command button is pressed I want the following to happen;
The Department combo box should appear
The button's text should change to "Show all Departments" in red
If the button is clicked when the text is red then:
the original button text should return in Black
the department combo should disappear

After clicking on the button and you click one of the specific departments ie accounting I want it to show only the accounting records in the form.

I'm still learning about access, so thanks for any help anyone can give me pleeeese!!

View 1 Replies View Related

Modules & VBA :: Creating A Filter By Date Range

Oct 2, 2013

I am trying to use VBA to create a filter by date range. the user inputs 2 dates and the database filters all records by dates in between the 2 dates,

Code below

Dim var_CustDate1 As String
Dim var_CustDate2 As String
var_CustDate1 = InputBox("Please enter start date in format DD/MM/YYYY", "Enter Date", Date)
If Not IsDate(var_CustDate1) Then
MsgBox ("not a valid Date")

[Code] ....

I've tried every combination of format for the dates but this is the closest ive got it to work,

if i enter dates 01/09/2013 and 12/09/2013 the filter works for the days in the month but also displays previous years, but if i change the dates to 01/09/2013 and 13/09/2013 it starts displaying all dates for all years in the months September, October, November and December.

View 3 Replies View Related

Forms :: Date Ranges - Using Child / Master Fields For Creating Filter

Oct 7, 2013

I have a form which I am using child/master fields to create a filter (see attached pic)

For the date ranges I need these to be

>= Start Date and <= Actual Finish Date

How can I set the criteria for these two fields, so that when someone picks a date it knows it's from or before the date entered.

View 14 Replies View Related

How To Create Filter Button On Form And Filter Records

Nov 26, 2012

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.

View 3 Replies View Related

Forms :: Filter Button On Form As Filter

Aug 1, 2013

I have placed a filter button on a form as a filter and written the following on-click event procedure:

DoCmd.SetWarnings False
DoCmd.RunCommand acCmdApplyFilterSort
Me.Filter = "ACCOUNT_DO_NOT_EMAIL = 'HS'"
Me.FilterOn = True

When I click the filter button I get a blank message box titled 'Microsoft Access" and an OK button, when closed the filter works perfectly.I have checked this procedure in other forms and it works without showing the blank message box.The only difference with this form is that its control source is a union query.

View 10 Replies View Related

Help Needed With A Form

Apr 18, 2006

Hi,

I have a quick question that i need to get some help with.

In a form, there is two comboboxes and a textbox. The textbox is disabled and locked because nobody is allowed to enter data to it. It contains the value which is from the result of choosing the two comboboxes.

example;
in table "Project"
Name Subject Score
michael IPA32 80
.
.

CB=combo box

from the dropdown, CB1 = "michael", CB2 = "IPA32". Then 80 will appear in textbox. However, there is some cases where the score doesn't exist or null (not found in the table). Is there a way to check on the spot if the textbox is empty or not as soon as CB1 and CB2 have been selected. At the moment, i use the form_beforeupdate to check the textbox. If it is, cancel is true. the whole form disappears which i don't want it to happen.

Your help is greatly appreciated.

Thank you in advance

View 1 Replies View Related

Help Needed With Form

Feb 18, 2005

Apologies if the answers are very simple, I'm a wee bit of an Access newbie!

I have created a form with which I am going to record gym attendances for my members in my members table. When I do this it will update a table 'gymattendance' which stores the information about price paid, date, memberID etc.

My first problem is that despite 'tblgymattendance' being linked to 'tblmembers', when I go to record a gym visit in my form, it will only allow me to enter new members, rather than select current members to record a visit. How do I get around this?

Once I get that sorted, I need the form to then send that record in its entirity to a new table, 'tbltakings,' which stores information on all the gym sessions attended to calculate total moneys taken from those sessions. I have been unable to find a way add records to 'tbltakings.'

If the latter is not possible, would a simple update query work to add to a field of 'totaltakings,' in 'tbltakings' ?

Many thanks in advance this is really starting to get on my nerves!!!

View 3 Replies View Related

Sub-form HELP Needed....

Oct 11, 2006

Please read the attachment, it explains what I'm looking for...

View 2 Replies View Related

Help Needed Getting A Form Onto The Web

Nov 20, 2006

I've developed a pretty simple form with a few combo boxes, text fields etc. I need to put this on the web so that my colleagues can access it logging new forms etc. As this is new to me I've followed the instructions as per my Access for Dummies manual. This advises that you have to save thte form as a data access page...unfortunately it's not working. The form works fine on my desktop. I've saved it as an Access Data Page but the end result seems to have disabled the combo boxes and an autonumbered field. I thought this might be as some fields were unbound so created a new form based on a table but this won't save as an Access Data Page at all and throws up the error message 'MS Access is unable to create the data access page
the file does not exist or you do not have read access to the file'. Clearly the file does exist and as far as I can see I have full administrative rights to it.
What am I doing wrong?? Can I use this method to publish to the web? If not what do I need to do? Is Access indeed the best method?
Any help would be greatly appreciated!

View 1 Replies View Related

Help Needed With Query And Form

Mar 29, 2007

Great forum guys! Just had to join it :)

I've been doing Access for just under 2 weeks now, so far I'm doing ok, but I've just run into 2 problems. I hope someone can help me on them.

The first problem is on a query. I have a Column called "Type" in my query and the choices under Type could be RECEIPT, REJECT, BOTH

(BTW: BOTH should show all records RECEIPT and REJECT)

By using case statements as shown below, i can easily return records for RECEIPT and REJECT, however, i cannot get BOTH to work

The criteria i have set for TYPE in my query is,

[forms]![frm_Vendor]![opta] OR [forms]![frm_Vendor]![opta] Is Null

Case 1
opta.Value = "RECEIPT"
stDocName = "rep_search"
DoCmd.OpenReport stDocName, acPreview

Case 2
opta.Value = "REJECT"
stDocName = "rep_search"
DoCmd.OpenReport stDocName, acPreview
Case 3
opta.Value = " "
stDocName = "rep_search"
DoCmd.OpenReport stDocName, acPreview


Case 3 does not work. with " " . So what do i do here to show Both records?

My second problem is with the reports opened with the above Case code. The search routine (apart from Both) work fine. It finds the records i ask of it and it opens a report to show them, however, there are instances where no records are found, and the report still opens!!. In my search form, what code can i use to test my query for "null" data before
it even gets a chance to open the report?

Thanks in advance for any help.

View 5 Replies View Related

PopUp Form Help Needed...

May 20, 2006

I'm sure this is simple and I searched the forum but I was unable
to find an answer so..please help! (btw, newbie here);)

I have two tables with a 1 to many relationship.
I have two forms based on each table.
Table1 has a key field called ECO.
Table2 has two key fields, ECO and ItemNumber.

When I have form1 open I use a button to 'pop up' form2.
Form2 shows only records that have ECO value = to Form1.ECO value.

When I create a new record on form2 I would like to have form2.ECO
auto filled with form1.ECO value. This is where I'm stuck!:confused:

Btw, I cant use a subform, already have too many!

Thanks!

View 2 Replies View Related

Form--autofill Help Needed!!

Apr 12, 2005

I have a table that containes: Member#, FirstName, LastName, CompanyName, etc. Multiple entries can be in the table for each Member#. On my form when a Member# is entered, if that # is already in the table, I would like for the form to autofill the FirstName, LastName, and CompanyName fields from the table. This is added protection to be sure the Member# typed is correct. If the # is not already in the table, then nothing will autofill. I am not new to Access...but my knowledge is not above "3rd grade". Can someone help with this problem, or can it even be done on the form?

Thanks, Linda

View 3 Replies View Related

Help Needed With Data Corruption On Form

Aug 23, 2005

Some of my collegues have been experiencing this problem with a very simple database i knocked up for them. First off some background. I have a main form (frmproperty) with 3 subforms linked to it(frmroomdata, frmlocation and frmsample). by a property code. Two of these subforms are linked (frmlocation and frmsample) these are linked by location code which is an autonumber.

These are laid out so that you fill in room data first, then location data then finally sample data. However after the location data has been filled out and a user attempts to move to the first combobox on the sample subform a message pops up saying that another user has altered the database and would you like to save changes (Impossible as they are using the database on a local drive). After this happens they reopen the form and in all the frmsample fields is "#deleted"

This doesn't happen every time...infact over the last 2 days i have been entering data myself to try and get this error with no luck. Has anyone else come across this and know how to fix it?

Thanks in advance
Matt Collins

View 3 Replies View Related

Help Needed With Sorting Dates On A Form

Sep 26, 2005

Why won't the dates in the form sort? 9attached) I have tried everything and cannot work out what i am doing wrong - desparate!!

View 1 Replies View Related

Query Help Needed Using Values From Current Form

Mar 13, 2007

Hi i am having problem creating a query that will pull the price of a property into the price field on to a booking order form depending on the values of the start date and property number enter onto the same form.
i have a two tables property price and booking order.

Fields in the property price are property price no, property no, start date, end date and price.

Fields in the booking order table are booking no, property no, start date, end date, cost, no of days, total cost.

When in the booking order form i need the query to get the price from the property price table matching on the property no i've selected on the booking order form and also the start date i've entered on the booking order form needs to be between the start and end date fields in the property price table.

This is the query i have created but doesn't work
SELECT [Property Price].Price
FROM [booking order] INNER JOIN [Property Price] ON [booking order].[Property No] = [Property Price].[Property No]
WHERE ((([forms]![booking order subform]![start date]) Between [property price].[start date] And [property price].[end date]) AND (([Property Price].[Property No])=[forms]![booking order subform]![property no]));

Thanks for your help

View 2 Replies View Related

Help Needed Filtering A Form Using Combo Boxes

Jul 26, 2006

Please help. My inability to achieve this is very frustrating.

I have a tabular form based on a query, which returns a large number of records. I need users to be able to filter the records to display data relating to what they have entered in a number of combo boxes.

For example I have fields showing Product ID, Manufacturer ID, Purchase Order number and due date. Each of these fields has a corresponding unbound combo box where users can select values that appear in the table. I need to be able to filter the form based on what is in these combo boxes. I.e. Filler for a product ID to show all purchase orders numbers and due dates relating to that product ID or filter for a manufacturer ID and due date to show all Product IDs and purchase orders relating to that a manufacturer and date.

Ideally this would be achieved by pressing a command button.

The query, table and combo boxes are all built and work fine but I am unable to get the filter to work, I am using Access 97 and am not very familiar with visual basic. Any help would be appreciated.

Thanks.

View 4 Replies View Related

Help Needed To Change Form Size/resolution

May 2, 2005

I hope I can explain this clearly.
I have a subform that has a lot of information and I was wondering
if there is a way to make the subform appear as if one turned up the
resolution, thus making it's contents smaller, allowing me to pack more info
in it. I would love to leave the size of the main form alone.
I'm using Access 2000.
The sub form is currently displayed as datasheet.

View 1 Replies View Related

Memo Field Punctuation - Form Help Needed

Jun 8, 2005

I have a form set up where user's type in an explanation of how a claim is being appealed and resolved in a memo field.

One problem, for some reason management doesn't want these explanations to end with a period. But the users keep ignoring our request and keep using the period.

Is there a way that you can code this memo field to where it will allow punctuation throughout, except at the end?

View 1 Replies View Related

Listbox Populating Data To Form - Help Needed!

Apr 26, 2006

http://forums.aspfree.com/microsoft-access-help-18/menu-list-values-won-t-pass-to-db-20951.html

Here's a page that shows almost what I am trying to do, but my question is how do I make selecting an item in my listbox pupulate date in multiple field on my form?

For instance, I want to click on a line in a textbox and have the fields "City" "State" and "Zip" all changed on my form, not just "City"

View 4 Replies View Related

Auto Fill Textbox In Seperate Form, Help Needed

Apr 10, 2007

Is it possible to fill an unbound text box in a seperate form with some text "Warning.HIGH RISK" on the click event of a checkbox on a different form?

View 2 Replies View Related

Help Needed With Database Problems; Validation Rule And Image In Form

Apr 17, 2007

Hello Everyone,
I am in the final stages of creating a database for school coursework however I am having a few problems with a few features; any help would be much appreciated.
The database itself is meant to manage / keep are record of utility bills, it consists of two tables: Invoice and Company.

Problem 1.
In the Invoice table there are two fields called Date Due and Date Received the data type is Date/Time, how do I create a validation rule so that Date Due must be after 'Date Received' and vies versa?

Problem 2
I want each record in the database to store an image of a scanned invoice, and the main form called Transaction to show a preview image of the invoice. Much of the code I used is borrowed from the Access Northwind sample database, after some initial success I had to redesign the 'Transaction' form where the picture was shown and now I get the error message:
‘Run-time error 2135, this property is read-only and cannot be set’
I think I know what is causing the error but I have had no luck fixing it, if someone could help me that would be excellent.

Problem 3
Once I get the Transaction form to properly store and display a preview image of an invoice, I want to add a button that opens the image in an external window(ie MSPaint).
Currently my only success has been to add a button on the form that launches MSPaint (you have to manually open the image in MSPaint.)
Again, if someone could help me sort this out it would be excellent.

Sorry if my problems aren’t clear or well explained.

I have spent many hours looking for answers to my problems in forums, Access help files etc…
My computing tutor has little (no) experience with Access so he has been unable to help, hopefully the people on this forum have the expertise.

I am happy to email you my database if you need it to help me with problems 2&3.

Thanks in ALOT advance :)
-Sarge

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved