UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Navigation Forms    
 
   
ScorpDevil
post Apr 17 2012, 04:14 PM
Post #1

UtterAccess Guru
Posts: 564
From: Miami, FL



Hi There, - Office 2010

I’m having a hard time running the following SQL

CODE
SELECT qry_none_signal_1.d_Date, qry_none_signal_1.d_By, qry_none_signal_1.FileName, qry_none_signal_1.d_Qiss, qry_none_signal_1.[Claim Id]
FROM qry_none_signal_1
WHERE qry_none_signal_1.strDate Between Forms!frm_claims_main_report!txtDateFrom And Forms!frm_claims_main_report!txtDateTo
ORDER BY CDate(tblFileName.d_Date);


When I run the query with the form loaded by itself it works just fine, but when opened thru Navigation Form seems like the form is not loaded or in some type if state that SQL is not able to obtain the data needed.

Does anybody know how to obtain data from navigation form? (textbox)

This post has been edited by ScorpDevil: Apr 17 2012, 04:15 PM
Go to the top of the page
 
+
theDBguy
post Apr 17 2012, 04:40 PM
Post #2

Access Wiki and Forums Moderator
Posts: 48,022
From: SoCal, USA



Hi,

When you place a form in the Navigation Form, it is treated (or acts) as a Subform. Thus, you will have to modify your form reference in your query to look for a subform.

Just my 2 cents... (IMG:style_emoticons/default/2cents.gif)
Go to the top of the page
 
+
ScorpDevil
post Apr 18 2012, 07:48 AM
Post #3

UtterAccess Guru
Posts: 564
From: Miami, FL



DB,

Thanks a lot my friend.....

Very strange way to go but seems to work.

CODE
SELECT qry_none_signal_1.strDate, qry_none_signal_1.strBy, qry_none_signal_1.FileName, qry_none_signal_1.strQiss, qry_none_signal_1.[Claim Id]
FROM qry_none_signal_1
WHERE qry_none_signal_1.strDate Between [Forms]![frm_claims_main]![NavigationSubform].[Form]![txtDateFrom] And [Forms]![frm_claims_main]![NavigationSubform].[Form]![txtDateTo]
ORDER BY CDate(tblFileName.strDate);
Go to the top of the page
 
+
theDBguy
post Apr 18 2012, 11:46 AM
Post #4

Access Wiki and Forums Moderator
Posts: 48,022
From: SoCal, USA



Hi R,

(IMG:style_emoticons/default/yw.gif)

Good luck with your project.
Go to the top of the page
 
+

Thank you for your support! Reply to this topicStart new topic

Jump To Forum:
 



RSS Go to Top  ·  Lo-Fi Version Time is now: 23rd May 2013 - 09:26 AM