date range in a query 02-07-08

hello i have the following code in a query 
[forms]![FORM2]!Between [datein] And [datein2]

i am tryng to perform a date range find using the two fields on form2 
[datein] and [datein2] but to no avail any ideas! 
-- 
Thanks Steve
0
Utf
2/7/2008 4:22:01 PM
access.queries 6343 articles. 1 followers. Follow

3 Replies
849 Views

Similar Articles

[PageSpeed] 0

Try this ---
Between [forms]![FORM2]![datein] And [forms]![FORM2]![datein2]

-- 
KARL DEWEY
Build a little - Test a little


"Steve" wrote:

> hello i have the following code in a query 
> [forms]![FORM2]!Between [datein] And [datein2]
> 
> i am tryng to perform a date range find using the two fields on form2 
> [datein] and [datein2] but to no avail any ideas! 
> -- 
> Thanks Steve
0
Utf
2/7/2008 4:50:03 PM
excellent!

whre can i get a brain like your??
-- 
Thanks Steve


"KARL DEWEY" wrote:

> Try this ---
> Between [forms]![FORM2]![datein] And [forms]![FORM2]![datein2]
> 
> -- 
> KARL DEWEY
> Build a little - Test a little
> 
> 
> "Steve" wrote:
> 
> > hello i have the following code in a query 
> > [forms]![FORM2]!Between [datein] And [datein2]
> > 
> > i am tryng to perform a date range find using the two fields on form2 
> > [datein] and [datein2] but to no avail any ideas! 
> > -- 
> > Thanks Steve
0
Utf
2/7/2008 4:58:01 PM
A some trial and lots of errors.
-- 
KARL DEWEY
Build a little - Test a little


"Steve" wrote:

> excellent!
> 
> whre can i get a brain like your??
> -- 
> Thanks Steve
> 
> 
> "KARL DEWEY" wrote:
> 
> > Try this ---
> > Between [forms]![FORM2]![datein] And [forms]![FORM2]![datein2]
> > 
> > -- 
> > KARL DEWEY
> > Build a little - Test a little
> > 
> > 
> > "Steve" wrote:
> > 
> > > hello i have the following code in a query 
> > > [forms]![FORM2]!Between [datein] And [datein2]
> > > 
> > > i am tryng to perform a date range find using the two fields on form2 
> > > [datein] and [datein2] but to no avail any ideas! 
> > > -- 
> > > Thanks Steve
0
Utf
2/7/2008 7:22:01 PM
Reply:

Similar Artilces:

Date construct with DatePart is kicking my.... well, you know.
Private Sub cmdCreatePath_Click() Dim strDateCons As String <bunch of my code that is (surprisingly) working like it should> strDateCons = DatePart(yyyy, Me.txtDateEntered) & "-" & DatePart(mm, Me.txtDateEntered) & _ "-" & DatePart(dd, Me.txtDateEntered) Debug.Print strDateCons End Sub When I click the magic button... nuffin'! I get an error message that states "Compile error: Variable not defined" and it highlights the 'yyyy' part of my first DatePart statement. What I actually wanted it to do was to take the date ...

How do I increase query field length (>20 characters) ?
I want to exclude 3 or 4 variables from a particular query. Using Not "xx"or"yy" is fine, but when excluding more than this, query fails. I think the problem is that the total text characters is quite large (approx 60 characters in total, from four exclusions). Ideas, please ? 60 characters is not the limit. 1024 characters is the limit. POST the SQL of the query that is not working (View: SQL on the menu) or at a minimum post what you are attempting as the criteria. Also "query fails" does not tell us if you get an error (what is it) or the wrong resul...

outlook 2003 02-18-10
Can not send mail from a distribution list created in Outlook 2003 - why? I get an error message that reads - could not be delivered to the following receive 501 5.5.2 RCPT TO syntax error Can someone help me. "pj jakobsen" <pj jakobsen@discussions.microsoft.com> wrote in message news:A0D15814-B5C5-4153-91EF-F3D36CD3F581@microsoft.com... > Can not send mail from a distribution list created in Outlook 2003 - why? > I get an error message that reads - could not be delivered to the following > receive 501 5.5.2 RCPT TO syntax error > Can someone help me. ...

Record Count 10-02-07
Experts, I'm trying to dynamically stored the record count from a subform into a field on my form. Now I have to look at the record count on the subform and manually entered the count into a field on form. There must be a better way. Please help! In the Control Source property of a text box on the main form: =[SubFormControlName].[Form].[recordset].[RecordCount] Where SubFormControlName is the name of the subform control, Not the name of the form that is the Source Object of the subform control. -- Dave Hargis, Microsoft Access MVP "Shiller" wrote: > Experts, >...

test a range for value....
Hi, I have a column of dates, formatted as date dd/mm/yyyy. I would like to have a formula in one cell that will evaluate the entire range to check if all the dates are within a given year. If A1 is 01/01/2008, I can put =year(a1)=2008 in B1 and return a true or false, but I can't seem to get it to work for a range rather than just an individual cell. Any help would be greatly appreciated. TIA. Jim Assuming your dates are in column A, with the search date 01/01/2008 in B1. This formula will count how many dates are not in the same year as B1: =3DSUMPRODUCT(--(YEAR(A1:A1000)=3DYEAR(B...

Query wildcard symbols
Just a heads-up in case this bites you, too. I migrated an application from Access 2002 to Access 2007. I have a search form for the users to enter some criteria ... the form dynamically builds a SQL WHERE clause before opening a "results" form based on an underlying query that includes all the fields available to search on. Once in Access 2007 format, the search form opens empty every time?! When I add selection criteria to the underlying query directly, the result set is empty every time?! Oh wait, I'm using the "*" (anything/everything) wildcard character. W...

Changing a text field to a date field
Hi I know this is a problem for lots of people but I still cant find an answer. I have imported a text file into excel with a number field that displays credit card expiry dates as a 4 digit number. example 0408 so month + year. I have converted the number field to a text field so it doesnt drop off the first zero and now I need to convert it to a date field. Any nice easy simple ideas. Any help would be much appreaciated. Or direction to a question the same. Perhaps =DATE(100+RIGHT(A1,2),LEFT(A1,2),1) format as date -- daddylonglegs --------------------------------------------...

Date and time onto a form
Hi, I am designing a form that my client would like the date and time automatically recorded in a field and stored so that when they refer back it shows when the record was done. The 'NOW' function only shows the current date & time and keeps updating. Is there a way of putting the 'NOW' value into a field, then locking it so it doesn't change when the record is reopened. Hope that makes sense! Kazlou The form stores data in a table. You need to add a date/time field to your table to record the date and time a record was last updated. 1. Open the table in desig...

Naming Ranges #4
Hi, When I name a Range on Sheet1, then make a Copy of Sheet1 to say Sheet2, then access the Define Names dialogbox, I can see the named Range listed twice. One is noted as belonging specifically to Sheet2 and the other appears without a sheet reference. When assiging a name to a Range, can I specify that it belongs to a certain sheet? Also, how would I change this code to assign the sheet name aswell? ActiveWorkbook.Names.Add Name:="myRange", RefersToR1C1:="=Sheet1!R1C1:R10C1" I am trying to assign a the name 'Column_Header_Range' to each sheet in my work...

Combo Box List out of range error.
For I = 1 To 6 Dim Item As String Item = "I" & CStr(I) roomName = Worksheets("Sheet1").Range(Item).Value Worksheets("Sheets1").cmbList.AddItem (roomName) MsgBox (roomName) Next I dont know why this piece of code is throwsing the error. If the line Worksheets("Sheets1").cmbList.AddItem (roomName) is commented out, then the msg box shows all the 6 items there. Which tells me there is some problem with this line of code(combo box). Is there a property that needs to be set for combo box's?Please h...

date #4
Hi All I live in South Africa, and I have an interesting problem that persists in Excel 2003 and 2007. =TEXT(NOW(),"dd mmm yyyy") returns 15 Dec 2006 =month(now()) returns 12 =text(month(now()),"MMMM") returns January =year(now()) returns 2006 =text(year(now()),"yyyy") returns 1905 Why would this be? Thanks Chris Chris, =text(month(now()),"MMMM") should be =text(now(),"MMMM") and =text(year(now()),"yyyy") should be =text(now(),"yyyy") or just =year(now()) Otherwise, you are calcing the month of the 12th day afte...

Date question 01-14-10
Can anyone help with this function: =IF[Date Parts Ordered Completed]+ [Date Part Completed]+[Date Purchasing Completed],not blank,=Date The goal is that is all three fields have a date in them, then put in today's date in the final field. If one of the dates is missing, then the final date is blank. The only problem is if I open up that form I do not want it to change the date to today. I want it to stay the date of the actual completion. Any help is greatly appreciated. Thanks, P-Chu -- Message posted via http://www.accessmonster.com Try this -- Completion_...

How to show the month of the referenced cell (containing a date)
If a cell holds the date "2/1/08", what formula can I use that will give me the following result: "Feb - 08" I tried =Month(a2)......but I just get the number of the month. Thanks. =TEXT(A2,"mmm - yy") Or simply =A2 with the cell custom formatted mmm - yy HTH. Best wishes Harald "Dave K" <fred.sheriff@gmail.com> skrev i melding news:165b03da-19ba-40b8-b9fe-77b17ef045b5@d45g2000hsc.googlegroups.com... > If a cell holds the date "2/1/08", what formula can I use that will > give me the following result: > > "Feb - 08&...

GL Posting date is missing or invalid error message
Hello, When trying to post a Sales order through Sales transactions entry window, we get an error message 'General ledger posting date is invalid or missing' The dates seem correct. The fiscal periods are all set up correctly. This happens whether we try to post an individual transcation or a batch. The batch looks like it is posting, but all the posting reports have zero mamounts in them & the batch still sits there even after posting as if it has never been posted. We are running GP 8.00g34 What is causing this & how do we fix it? Thanks Did you recently change your pos...

Importing a table from Access query
What is the quickest and easiest way to do the above? Thanks in advance. Hi The way I usually do this is run the select query, click on the top-right box (which selects all records) and use Ctrl+C to copy and Ctrl+V to paste into my workbook. An alternative is to right-click on the query in the Database Window and left-click on Export. In the Save As dialog box, select ..xls type. -- Andy. "Trish" <Trish@discussions.microsoft.com> wrote in message news:6BF3DE22-6590-4CAD-9EE1-FC978A3BB63B@microsoft.com... > What is the quickest and easiest way to do the above? >...

named ranges in other workbooks
i have a range of cells whose values are validated from a list determined by a name the name is determined by a formula which references a range of cells in a different workbook (i'm on a office network...) the problem is: if the other workbook is open (on my desktop?) the name is o.k. and the validation is fine... but: if the other workbook is not open, the name results in an error i didn't think that this is the way it's suppose to work... AURGHH Mark, Do you use a full reference such as ='C:\Documents and Settings\Owner\My Documents\Book1.xls'!profit Bernar...

Date range for a report
Hi I am trying to run a query and can't seem to nail down the right code. We use the access database to track files, incoming/outgoing correspondence dates etc. I am trying to run a query that show me files with dates in a follow up field of -60 days to +7 days, so essentially any follow ups missed in the last 2 months and up coming in the next week. This report is run on a weekly basis. Appreciate any help Thanks Assuming that the follow up field is actually a date/time data type, try this in the criteria: Between Date() - 60 and Date() + 7 -- Jerry Whittle, ...

Report Server Error 09-28-07
After uninstalling MSCRM from my server, I tried installing it again. This has led me to the problem of the report server. I'm using the default server name http://<servername>/reportserver and it's still not realizing that it is actually there and fully running. I've checked the Services section of my server and also checked the individual server status. Both are running within normal parameters. Before the uninstall, the report server was running properly and CRM recognised that it was actually there. Any ideas? ....reed Is this SQL Server 2000 or 2005 SRS? 1. Fo...

access forms 12-05-07
how can the minimum value from eight numeric fields be found & displayed displayed on the form, following manual entry? Your only way is through a series of If statements to determine the minimum. Remember, too, that you may need to handle missing data. You can use the Nz function in that case, but you need to be able to assign a reasonable value for comparison purposes if the value is Null. Dim lngMinimum As Long lngMinimum = Nz(Me.Field1, 9999) If Nz(Me.Field2, 9999) < lngMinimum Then lngMinimum = Me.Field2 End If If Nz(Me.Field3, 9999) < lngMinimum Then lngM...

Reading empty query returns
When I open a form that has a bound query as the record source, no data appears (including the control objects of the form) if the query's select statement does not finds records that match the criteria I specify. This causes a problem in my VBA code as the variable I use to check the number of records returned by the query does not seem to be able to read empty query returns, even if I use isnull. So I guess I am asking how can I get Access to read an empty result set in VBA from a SQL select statement that is run??? Here is part of my code for this: DoCmd.OpenForm stDocName2, , ...

Query Flaw???
I need only one value from an aggregate Query - TheStores, which means the Number of Inspections in a "From - To" Timeframe. I use that as part of a calculation. The "Inspections" table contains only a Store and an InspectionDate. It gives me the result I need...but no Join...the Query has several other Fields from "Randy_F_FindFreq", but has been trimmed as an example here. SELECT Randy_F_FindFreq.AAll, Randy_Insp.TheStores, Round([AAll]/[TheStores],4) AS PerAll FROM Randy_F_FindFreq, Randy_Insp; Is this "sound"? TIA - Bob Without a join yo...

Trouble with Expression 02-19-10
This expression counts the number of records where a tick box is YES TxtSoleYes: Count(IIf(txtSole,1,Null)) Why doesn't this work to give me the number of No's TxtSoleYes: Count(IIf(txtSole,0,Null)) Thanks Tony -- Why don't my grey cells communicate with each as fast as they used to? I hate getting old! Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/Forums.aspx/access-queries/201002/1 Tony - Try Sum instead of Count. Count gives the number of non-nulls, and zero is non-null. -- Daryl S "TonyWilliams via AccessMonster.com&...

IF Statement 01-17-08
Hi, I am trying to run a query that has 4 fields: location, type, year, and cost. However I need to increase the cost for the year 2007 for 2 types. The IF statement I entered into the cost field is: TotalCost:IIF([Type]="C" Or "H" And [Year]=2007,[SumCost]/.9,[SumCost]) The issue I am having is that it is increasing the costs for all types. Is there a way to fix this or do i need a new query for C and H and then combine the 2 queries? Thanks for any help you can provide. Actually, you don't need to do it that way. Create a Where clause for the query tha...

Date Formula #3
I am having difficulty with the "NOW" formula. What I would like for it to do is when I enter a value in one cell have it update in another cell the date when the information was entered and that date stay permanenty. What I am having is the date changes to the current date everyday. Is this possible to do? Any help would be appreciated. Thanks. Todd You can do it with the change event of the worksheet This example will place the date/time in the B column if you change a cell in the range A1:A20. Place the code in the Sheet module Right click on a sheet tab and choose ...

calculating quantity on hand based on date-time stamp
Hello: I am always unclear on the proper syntax for pulling date-related data. I need to pull a field in my query, below, based on the field called "IV00118.CHANGEDATE_I". This is the date in which an end user changed the cost of an item. To give you some background, the IV00102 table in my query below is the Item Quantity Master table, while the IV00118 table is the Item Cost Change History table. The field that I want to pull based on that date field is the IV00102.QTYONHND field. This field is the inventory quantity on hand field. How would I format the syntax bel...