|
|
Our Hot Pick: Rising Antivirus 2006 - Certified by TUV & Checkmark! Get 10% discount by entering this coupon code: ONDISCOUNT10
|
|
Not sure what you are are doing with the 3rd part of the statement, but it looks like you have some things wrong there: [Forms]![Date3]!Format([BeginningDate],"#")
This is usually in the form of : [Query Field Name] = Expression
Example:
"StartDate = " & Forms!Date3!BeginningDate
StartDate would be the name of the field in the query, change this if it is different. Often to make Dlookup recognize a date, I put # at the start and end of the date:
"BeginningDate = #" & Forms!Date3!BeginningDate & "#"
"laveshhp via AccessMonster.com" <u26306[ at ]uwe> wrote in message news:663efc7ba2aca[ at ]uwe...
[Quoted Text] > Hi! > > Please help me > > i need data from my query for beginning date which i use in date form > range > and i use below but show me #error > > =DLookUp("[Balance]","Table1 > Query",[Forms]![Date3]!Format([BeginningDate], > "#")) > > thanks > > -- > Message posted via AccessMonster.com > http://www.accessmonster.com/Uwe/Forums.aspx/access-forms/200609/1>
|
|
Eric Heinold wrote:
[Quoted Text] >Not sure what you are are doing with the 3rd part of the statement, but it >looks like you have some things wrong there: > [Forms]![Date3]!Format([BeginningDate],"#") > > This is usually in the form of : > [Query Field Name] = Expression > > Example: > > "StartDate = " & Forms!Date3!BeginningDate > > StartDate would be the name of the field in the query, change this if it >is different. > Often to make Dlookup recognize a date, I put # at the start and end of >the date: > > "BeginningDate = #" & Forms!Date3!BeginningDate & "#" > >> Hi! >> >[quoted text clipped - 9 lines] >> >> thanks
Hi! Eric Thanks for quick reply but i am new in access so can you provide me all formula
date is my query field and i need data only for my beginning date which i put in date3 form
thanks for your help
-- Message posted via http://www.accessmonster.com
|
|
=DLookUp("[Balance]","Table1 Query","Date=[Forms]![Date3]![BeginningDate]")
After looking at the query again and your question again, I think this is how you will need structure it. I usually use Dlookup in code, so I would to it the way I noted below, but for a control source, I think this will work for you. "laveshhp via AccessMonster.com" <u26306[ at ]uwe> wrote in message news:663f6dbb94d68[ at ]uwe...
[Quoted Text] > Eric Heinold wrote: >>Not sure what you are are doing with the 3rd part of the statement, but it >>looks like you have some things wrong there: >> [Forms]![Date3]!Format([BeginningDate],"#") >> >> This is usually in the form of : >> [Query Field Name] = Expression >> >> Example: >> >> "StartDate = " & Forms!Date3!BeginningDate >> >> StartDate would be the name of the field in the query, change this if >> it >>is different. >> Often to make Dlookup recognize a date, I put # at the start and end >> of >>the date: >> >> "BeginningDate = #" & Forms!Date3!BeginningDate & "#" >> >>> Hi! >>> >>[quoted text clipped - 9 lines] >>> >>> thanks > > Hi! Eric > Thanks for quick reply but i am new in access so can you provide me all > formula > > date is my query field and i need data only for my beginning date which i > put > in date3 form > > thanks for your help > > -- > Message posted via http://www.accessmonster.com>
|
|
Eric Heinold wrote:
[Quoted Text] >=DLookUp("[Balance]","Table1 Query","Date=[Forms]![Date3]![BeginningDate]") > >After looking at the query again and your question again, I think this is >how you will need structure it. I usually use Dlookup in code, so I would >to it the way I noted below, but for a control source, I think this will >work for you. >>>Not sure what you are are doing with the 3rd part of the statement, but it >>>looks like you have some things wrong there: >[quoted text clipped - 31 lines] >> >> thanks for your help
Hi!
Still didn't work now i ger #error message
thanks for your help
-- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/Forums.aspx/access-forms/200609/1
|
|
Since there's a space in Table1 Query, it needs to be enclosed in square brackets. You should also take the reference to the form field out of the quotes, make sure it's delimited with #, and that it's in mm/dd/yyyy format (regardless of what your Regional Settings might be). Finally, Date is a reserved word, and shouldn't be used for your own purposes. If you cannot (or will not) change the name, at least use square brackets around it:
=DLookUp("[Balance]","[Table1 Query]","[Date]=" & Format([Forms]![Date3]![BeginningDate], "\#mm\/dd\/yyyy\#"))
-- Doug Steele, Microsoft Access MVP http://I.Am/DougSteele (no e-mails, please!)
"laveshhp via AccessMonster.com" <u26306[ at ]uwe> wrote in message news:665471e3e946a[ at ]uwe...
[Quoted Text] > Eric Heinold wrote: >>=DLookUp("[Balance]","Table1 >>Query","Date=[Forms]![Date3]![BeginningDate]") >> >>After looking at the query again and your question again, I think this is >>how you will need structure it. I usually use Dlookup in code, so I would >>to it the way I noted below, but for a control source, I think this will >>work for you. >>>>Not sure what you are are doing with the 3rd part of the statement, but >>>>it >>>>looks like you have some things wrong there: >>[quoted text clipped - 31 lines] >>> >>> thanks for your help > Hi! > > Still didn't work now i ger #error message > > thanks for your help > > -- > Message posted via AccessMonster.com > http://www.accessmonster.com/Uwe/Forums.aspx/access-forms/200609/1>
|
|
|