Prompting For A Date?

Feb 17, 2005

Can I get my query to prompt for a specific date somehow?

Or....I am running a report off my query, can I get my report to prompt for a specific date?

View Replies


ADVERTISEMENT

Prompting For Parameter - Why?

Dec 12, 2005

Hello,

I have a table which contains:

InvNo - Autonumber (invoice number)
AccNo - Clients account number
Amount - Amount of invoice

I also have this data (minus the InvNo) in a linked spreadsheet. I would like to keep the spreadsheet as it is all set up for the printing of multiple copies etc.

The idea is, I want to import the data from the spreadsheet into the database, which will then apply an invoice number (because it is an autonumber), and then get that invoice number back into excel.

I have done it all, but cannot get it to give me the invoice number assigned to it.

I thought I would have a simple query that looks for records in the table that are the same account number, and amount (plus a few others I havn't included here), and then it could return the InvNo.

But, whenever I run the query, it asks me to specify the parameter, it doesn't seem to be able to read from the linked spreadsheet (it is openable, I can open it in access just fine).

In the query I have put (under criteria): "[LinkedSpreadsheet]![AccNo]" (and similar for the other fields I want to match).

What is wrong?

Thank you!

View 1 Replies View Related

Prompting A Crosstab

Nov 14, 2007

I have a crosstab query and I want to prompt users for certain colunms is this possible. If so how, I want to prompt the users to enter month.

View 2 Replies View Related

Prompting For Specific Dates

Aug 16, 2005

Hi all
Im wanting to open a sales report, but I want to be prompted to enter dates FROM and TO so that I can get specific sales.

Example

"Enter start date" here i'd enter 1/8/05
"Enter end date" here i'd enter 31/8/05

that way i'd get all sales throughtout august. Then when september comes round I could enter new dates and save me having to go in and change the filter.

Can anyone help?

Thanks

View 3 Replies View Related

Reports :: Expr1 In Query Keeps Prompting

Oct 24, 2013

I have a for form with a button to run a report. The report runs a query. The query reads data on the form to feed the report. The data that is from the table works fine but data from a text box on the form will not. It prompts for EXPR1.

In my query I have the following:

EXPR1: [Cnum]

[Forms]![FRM-Customer]![Cnum]

where FRM-Customer is the form with the button to run the report and Cnum in the text box data that I want to pass to the report. Every time I run it it prompts Cnum?

View 5 Replies View Related

Parameter Prompting Multiple Times?

Aug 15, 2011

I have a report with a subreport. I have added a parameter to the query to prompt for [manager] or is null to get all managers. However, on the report when I enter a manager my count on the subreport still returns the count for all. So, I added the same prompt to the query for the subreport. It returns the right count, however, it prompts for the manager multiple times. How do I get it to prompt only once yet get the right total?

View 1 Replies View Related

Prompting Save Message Before Moving To New Record

Oct 25, 2005

Hi all,

I Have a form bound to a table.

The form will be used by poor experienced users so to avoid problems i would like whenever we move to a new record(or changing the contents of a stored one) a save record message to appear refering to the one we are just leaving.
Generally i would like a solution which will restrict users from entering data by mistake using scroll mouse or ctr+page down.
If i could design it ,i would choose that nothing in the form is saved until a save all button is clicked.This means that the user will enter virtually as much data as he likes but they will be stored in the table only when the button is clicked,but i don't know if this is possible since my form is bound to table.
Thank you all in advance,
black ailouros

View 1 Replies View Related

VBA OnClick -- Prompting User For More Than One Required Field

Jun 21, 2005

I'm using VBA to prompt users for two required fields. One I can do, but with more than one I get into issues like only 1 message box appearing at a time. If both fields are blank I want both messages to appear. Here's my code, it's in an On click function:

If IsNull(req_file_num) = True Then
MsgBox "Required field: File #. The appropriate file number must be entered before this PO's status can be changed to Filed."
GoTo Err_Command_158_Click2
End If

If Not [req_filed_date] Then
[req_process_status_rec_id] = 8

MsgBox "Your changes have been processed. This purchase order now has a status of Filed."
DoCmd.Close acForm, "frm_req_file"
GoTo Err_Command_158_Click2
Else: MsgBox "Required field: File Date. The appropriate date must be entered before this PO's status can be changed to Filed."
GoTo Err_Command_158_Click2

End If

Err_Command_158_Click2:
End Sub


I realize that it only shows one message box because I have the GoTo Err_Command_158_Click2 command, but I couldn't figure out how else to keep it from continuing through the code. If both "req_file_num" and "req_filed_date" are null, then I don't want the "req_process_status_rec_id" to change to 8 and have the form close.

Thanks for your help!

View 2 Replies View Related

Modules & VBA :: Prompting User To Select Answer

Aug 7, 2013

I'm trying do a Select Case on a form control where the user is prompted for information depending on the value in the control.

Here's a generic example:

If field1 = "Vegatable" then
Select 1 for Brocolli
Select 2 for Lettuce
Select 3 for tomato

If field1 = "Fruit" then
select 1 for "Banana"
select 2 for "Apple"
select 3 for "Peach"

View 9 Replies View Related

Prompting User To Accept Or Decline Potential Duplicates While Importing Excel Table?

Jun 28, 2013

I have a database table to which I will be adding multiple records from various other contributors. I would like to build a simple, import-friendly excel table that I can mail out to others, so that they can fill it out and send it back to me. Then I will save import steps as a macro or something similar, so that I can easily import their data.

The hard part is that I would like a way for Access to compare the new records with the existing records, identify potential duplicate records by predetermined criteria (in other words, 'wild-carded' to some level of specificity, since duplicates could be off by just a few characters), and then prompt me to examine each record to be imported alongside however many existing records that have been identified as potential duplicates. Then I as the user could:

1. accept the import record as a new record

2. decline importing that record since it is a duplicate of an existing record, or

3. edit by hand an existing record that is a duplicate of the proposed import, but may require additional information, and then decline to import the new one.After each prompt, I would like the import process to continue to the next potential duplicate, and when there are no duplicates, to complete the import and display a message box that says "Import complete".

View 6 Replies View Related

Queries :: Date / Time Query - Return All Records Of Specified Date Or Date Range

Aug 19, 2015

I have a table that has entries recorded with date and time in one field, and I want to have a query that returns all records of a specified date or date range, regardless of the time in the field.

I have tried

Code:
Between [StartDate:] And [EndDate:]

And

Code:
Between [StartDate:] & "00:00" And [EndDate:] & "23:59"

Neither of which work ....

View 13 Replies View Related

Modules & VBA :: Date Field To AutoPopulate Other Date Fields To Future Date

Oct 24, 2013

I'm trying to get my "IncidentDate" field to autopopulate two other date fields to a few days from the "IncidentDate". The other two date fields are "ContainDueDate" and "RootDueDate". I'm trying to accomplish this on my "Test CAP Form"

I tried using the following in the BeforeUpdate of "ContainDueDate" and received a complier error: expected =

Code : DateAdd(d,2,[IncidentDate])

so I removed the parenthesis and nothing happened

Code : DateAdd d,2,[IncidentDate]

I even tried redoing it in the AfterUpdate of "IncidentDate" and nothing happened either

Code : DateAdd d,2,[ContainDueDate]

I'm not sure if I'm even using the right function to get what I want.

View 4 Replies View Related

Year To Date Totals, Month To Date, Week To Date

Oct 9, 2005

Can someone tell me how to get year to date totals, month to date totals, week to dates in a query? I need to get all three for three different fields.

I was not able to get the totals with the formulas given. I received the totals for each day instead. Are there any other suggestions? I am trying to different formulas, but they are not working either. I did try doing different queries with the formulas to see if that would work.

View 9 Replies View Related

Date Formatting (General Date To Short Date)

Aug 5, 2005

I am creating an online post, similar to a guestbook. When a user submits an entry, I am storing the date and time in a column titled "Timestamp", which is formatted 8/4/2005 9:16:58 ("General Date"). I am running the table through a query which is then posted on the web.

What I would like to do is this: I would like to use Timestamp to display the date that the entry was submitted, but not the time (basically, "Short Date"). Can I exclude the time using a query without changing the actual data stored in each record of the table? I understand that the time stored is completely different than the time displayed, even in the table. How can I do this?

View 2 Replies View Related

Modules & VBA :: Set Datatype As Date / Time In The Form - Update Table With Null Date

Mar 12, 2014

I have a form with Date of Death (DOD) field. I would like update DOD from a table dbo_patient into Z_Patients table.

I have set the datatype as Date/Time in the form for Date of Death.

Code:
Private Sub Update_DOD()
Dim rcMain As New ADODB.Recordset, rcLocalDOD As New ADODB.Recordset
Dim DOD As String
rcMain.Open "select distinct PatientKey from Z_Patients", CurrentProject.Connection

[Code] ....

However I am getting some error Run-time error '-2147217913 Date type mismatch in criteria expression in section below.

Code:
CurrentProject.Connection.Execute "update Z_MAIN_Processed_Patients set DateOfDeath = '" & rcLocalDOD!date_of_death & "' where PatientKey = " & !PatientKey

View 5 Replies View Related

Forms :: Date Format - Force User To Only Choose Month End Date?

Sep 20, 2013

Using access 2010; i have a form that includes a date field. Is there a way to force the user to only choose a month end date? When the user clicks the date from the popup, they may use 9/1/2013 when the mgr. want them to use only 8/31/2013. I am thinking validation field to put a msg but want to be able to force it not the option.

View 2 Replies View Related

Reports :: Showing Date Field Differently Depending On Current Date

Nov 23, 2013

I have a report that displays simple date fields. One of the fields is "lease execution". On the report, I want "lease execution" to display differently depending on the date the report was run.

So:

- If the "lease execution" date is more than 120 days away from today, I want it to display as Q YYYY.
- If the "lease execution" date is between 120 and 90 days away from today, I want it to display as MM/YYYY
- If the "lease execution" date is 90 days or less away, I want it to display the normal date MM/DD/YYYY

I was thinking I would need to do DateDiff() to figure out an amount of days that's between Now() and [Lease_Execution]. Then based on that amount make the report show it differently. Pseudocode would be: if DateDiff() = 40, then display [lease_execution] as MM/DD/YYYY

View 9 Replies View Related

General :: Deduct Quantities Based On Date - Start From Lowest Date

Sep 9, 2014

I have attached a sample of a database.

Table 1 has all the items I am trying to sell with sell by date after which I cannot sell this item. Then in Table 2 I have forecasted sales. So now I am trying to calculate stock consumption to see if I will be left with any stock that I cannot sell.

So now somehow I need to deduct sales forecast from my stock holding but it needs to go by date i.e. consume all stock for Item 1 with date 16/09 before moving to Item 1 with sale by date 23/09.

So based on the attached example, I can see that on 16/09 I will consume only 5 cases from sell by date 16/09 and another sale is 18/09. So that would give me information that I will be left with 95 items dated 16/09, which I cannot sell because they will be out of date.

Ideally I would like also to include the logic that if Item is out of date it would move to the next sell by date.

So in this case sale of Item 1 forecasted for 18/09 (94) would consume the whole stock (50) with date 23/09 and another 44 from date 01/10

For Item 2 I can see that units with Sell by date 30/09 will be consumed on 25/09 and I will start taking stock from next sell by date which is 14/10.

View 8 Replies View Related

Forms :: Auto Age Calculate From Birth Date To Selected Entry Date

May 11, 2013

I create a database through ms access and there have a birth date box and admission date. Another box for Age.I want to see the age in month or year figure in to the age box when I go next field. Which will be calculate from admission date to birth date.

View 1 Replies View Related

Modules & VBA :: Add 7 Days To Todays Date To Store Target Date In Table

Dec 9, 2014

How can I add 7 days in todays date to store target date in the table?

Code:
ssql = "Insert into tblUpdate([Update_ID],[Date],Username,Status,Target_Date) values('" & j & "',#" & Format(Date, "mm/dd/yyyy") & "#,'" & k & "','Open')"
CurrentDb.Execute ssql, dbFailOnError

View 3 Replies View Related

Display Fields As Column Showing Date One Month After The Date In Field Above

Jun 2, 2015

I am creating a repayment schedule (as a report) and I want to display a series of fields as a column which return (show) a date one month after the date in the field above.

The first repayment date field (Line 1) will show a date one month after the loan was paid out. the Next field below will show the date one month later.

I can't simply insert the "Date + 30" because that would get out of since over the year. If the loan was issued on say the 15th of January, I need the first field to display 15th February and the next would be .... 15th March.... Yes - You've got it!

Now I could do that in Excel, but I don't know how to get Access to do it.

View 4 Replies View Related

Calculate Final Date Based On Begin Date And Number Of Days

Jun 30, 2015

I need to calculate the final date based on the begin date and the number of days.

The name of the fields are: sdatainicio; diasatribuidos; sdatafim.

View 7 Replies View Related

Find Max Random Date In Tbl1 Before Active Record Date In Tbl2

Jul 9, 2013

I'm reworking a db to make it web compatible. Right now I'm working on my Price and Sales tables.There are about 900 Sales records, 450 Price records (for about 45 Items).

I have re-done my Price table with an Autonumber Key field. (It had a multi-key which I understand web db does not support.) Each autonumber key represents a Date with new Price for a Company/Item. The Price change Dates are random.

I have put a Foreign Field in my Sales table for the Price key field.

My dilemma is matching the Sales with the Prices.

When the Price Date and Sales Date do not match (at least half of them don't match), I need to look back in the Price table to the max Date BEFORE the Sales Date in the Sales table for that Company/Item in order to select the correct Price key.

View 2 Replies View Related

Auto Fill Field In A Table By Comparing A Given Date Against Current Date?

Aug 18, 2015

I am building a database to track contract of employees so that I can know which contracts are valid and which are expired.

My table has the following fields:

ID (Primary key)
Employee ID (Foreign key to link to the employee table)
Start_Date
End_Date
Status (Either valid or expired)
Challenge

I want when I enter the end date, the system checks the end date against the current date and fills in the status field with either valid or expired as appropriate. For instance if the contract end date is March 10,2016, the status must be filled in the word valid.

View 3 Replies View Related

Forms :: Form Auto-populates Date Field - Want To Add Check Box To Enter Alternate DATE

Nov 1, 2013

We use access to enter our service tickets in at work.What we have are three date fields.

Call Date
Start Date
End Date

We are 24/7 operation.Currently all 3 just autopopulate with the current date.What i would like to do is ADD a CHECKBOX next to each Date Field.And make it work like this.

1. let them autopopulate as they are currently
2. if you end the call AFTER MIDNIGHT (the next day). CHECKING the box would automatically populate yesterdays date in each of the fields that has the check box CHECKED

View 3 Replies View Related

Print Date Range On A Report Based On A Non-date Field

Aug 7, 2005

Is there a way to show the earliest and latest dates of a report generated by a non-date field?

E.g. I generate a report based on Food, and it'll list the days that this food is associated with. Is there a way to show the first and last day that appears in this report (i.e. the range of dates that the report shows based on the food selected)

View 2 Replies View Related







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