|
Subject:
|
Tring to insert date into SQL server Db
|
|
Posted By:
|
srjordan
|
Post Date:
|
6/24/2005 7:56:04 AM
|
Here is my code: <tr> <td align="right" valign="top" ><B>Date: </B></TD> <TD valign="top"><Input class="text3" input type="text" maxLength="12" id="txteffdt" name="date1" size="9" value="<%= FormatDateTime(now(),2)%>"> <A href="javascript:ShowCalendar(document.myForm.dateimg1,document.myForm.date1,null, '<%= FormatDateTime(DateAdd("yyyy", -1, now()),2)%>', '<%= FormatDateTime(DateAdd("yyyy", 1, now()),2)%>')" onclick=event.cancelBubble=true;> <IMG align=top border=0 height=21 id=dateimg1 src="cal/calendar.gif" style="POSITION: relative" width=34></A></td> </tr>
oCom17.Parameters.Add("@txteffdt", system.Data.SqlDbType.datetime, 12).value = txteffdt.text
I get this error message: BC30456: 'value' is not a member of 'System.Web.UI.WebControls.TextBox'.
If I add runat="server" the popup calander locks up can anyone give me any ideas
|
|
Reply By:
|
Hazzardusa
|
Reply Date:
|
8/15/2005 6:57:36 PM
|
on which line of your posted code does the error tell you to check?
----------------------------------------- Inigo: You have a great gift for rhyme. Fezzik: Yes, yes, some of the time. Vizzini: Enough of that. Inigo: Fezzik, are there rocks ahead? Fezzik: If there are, we'll all be dead. Vizzini: No more rhymes now, I mean it! Fezzik: Anybody want a peanut?
|
|