Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DateTimePicker from a form page to another using ASP

Status
Not open for further replies.

MisterMo

Programmer
Mar 18, 2002
564
GB
I have a form page that pass parameters to a ASP page to view crystal report which needs Date

Parameters.
I am able to pass virtually everithing I need but I don't know how to extract datepicker value for the date

range. I have the two DatePickers and they work fine, I know that I can do it with Visual Basic but some

how that dosen't work with ASP page.
I have already tried
********************************************************
<%
Dim kwd1
Dim kwd2
Dim kwd3
dim kwd4
kwd1 = Request.Form (&quot;txtMattN&quot;) 'The text ID
kwd2 = Request.Form (&quot;strDate1&quot;) 'Date Range Min
kwd3 = Request.Form (&quot;strDate2&quot;) 'Date Range Max
kwd4 = Request.Form (&quot;bgid&quot;) 'Date Range Page ID
%>
Kwd1 and kwd4 are OK. kwd2 and kwd3 do not pass the values
***********************************************************
I also tried querystring without success.

I would appeciate any help.


************************************************************************
for appDate=cdate(request(&quot;tdat1&quot;)) to cdate(request(&quot;tdat2&quot;)) step 1
response.write appDate & &quot;<br>&quot;
next



Thanks
MisterMo
 
Post the code for the page submiting the information to the above code.
 
kwd1 = Request.Form (&quot;txtMattN&quot;) 'The text ID
kwd2 = Request.Form (&quot;strDate1&quot;) 'Date Range Min
kwd3 = Request.Form (&quot;strDate2&quot;) 'Date Range Max

If your naming convention is consistent shouldn't kwd2 & kwd3 be referencing txtDate1 and txtDate2? What did you name the text boxes the date picker is populating? Check that maybe. I am just guessing, like sarkman said post your submitting page and we'll see if we can find it.

AJ
 
Sorry that was my fault. I didn't explain the problem properly

This is he page containing the two DateTimePicker

************************************************************
<html><head>
<body bgColor=#bdbdfb >
<h1><P align=center>Billing Guide with Date Range </P>
<P align=center>&nbsp;</P></h1>
<form method=&quot;post&quot; action=&quot;Test2.asp&quot; onSubmit=&quot;return validate(this)&quot; id=&quot;form1&quot; name=&quot;form1&quot;>
<P align=center><STRONG>Enter Matter Number</STRONG>

<input id=&quot;txtMattN&quot; name=&quot;txtMattN&quot; size=&quot;15&quot; ><br> </P>
==========================================================
These are the two objects
==========================================================
<P align=center><STRONG>From&nbsp;</STRONG>&nbsp;
<OBJECT id=Cal1 style=&quot;WIDTH: 242px; HEIGHT: 215px&quot;
classid=java:com.ms.wfc.ui.MonthCalendar><PARAM NAME=&quot;strDate1&quot; VALUE=&quot;UEsBAAAIdGFiSW5kZXgFAAAAAAAA&quot;></OBJECT>

<STRONG>to &nbsp; </STRONG>
<OBJECT id=Cal2 style=&quot;WIDTH: 242px; HEIGHT: 215px&quot;
classid=java:com.ms.wfc.ui.MonthCalendar><PARAM NAME=&quot;strDate2&quot; VALUE=&quot;UEsBAAAIdGFiSW5kZXgFAAAAAAAA&quot;></OBJECT>
===========================================================

<input type=hidden name=&quot;bgid&quot; value=&quot;2&quot;>

<P align=center><input type=&quot;submit&quot; value=&quot;Enter&quot; name=&quot;Billing&quot;></P>
</form>
</body>
</html>
*********************************************************

For some reason the two objects (DateTimePicker do not pass the value to the next page.

I have tried to call both the object names and the DateTimePicker names

Thanks again for your help

MisteMo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top