Hi everyone,
last week I installed Visual studio.net on WinXPPro with IIS 5.1. Everything in Visual studio works fine. When I try to browse (IE 6.0) aspx pages with Web forms controls, they just don't display. HTML controls display fine. Please help, I'm going mad out here. "Defeat is not...
Hi,
as I see it you can do 2 things.
1. Add server side code between <head> tags before all your scripts:
<head>
<meta .... other stuff here>
<%if Request.QueryString("rec")="new" then
btnNewEntry_onclick()
end if%>
<script ...>
Sub thisPage_onenter()
if...
Hi,
you can do it without PageObject(I never seem to get it to work properly :-( ). Just send a parameter in your link:
Mypage.asp?rec=new - put whatever makes sense to you and then check the value on server side
Sub thisPage_onenter()
if...
You can do client side or server side validation. I prefer client side, becuse there's no server trip.
A simple example (you have one DTC textbox and one DTC button for saving):
<script language=JavaScript>
function thisPage_onbeforeserverevent(obj,evnt)
{
if (obj=="btnSave"){...
Hi,
I'm sorry. I was in a hurry. Because your recordset is server side you have to refrence it in table like this:
<td><%=rsMydata("field9")%></td>
You won't need DTC's this way.
"Defeat is not the worst of failures. Not to have tried is the true failure."
-George E...
You could make a simple loop between body tags in the place, where you want your table to be:
<body>
...
<% rsMydata.movefirst
Do While NOT rsMydata.EOF %>
<table>
<tr>
<td>header1/header9</td>
<td>header2/header10</td>
<td>header3/header11</td>
//and so on
</tr>
<tr>...
Hi,
I made an asp page with one recordset DTC, 2 Textbox DTC's (one is bound to the recordset) and the above code. When the page is loaded it displays the recorset value. When I correct the value and leave the textbox, the corrected value is displayed in Textbox2, so the code works.
The problem...
Hi,
have you tried Microsoft's
http://support.microsoft.com/default.aspx?scid=kb;en-usQ306345
The ;en-usQ306345 is also part of the link, so just copy the whole thing.
"Defeat is not the worst of failures. Not to have tried is the true failure."
-George E. Woodberry
Hi,
have you tried using Session in Sub UpdateRec(),
<SCRIPT ID=serverEventHandlersVBS LANGUAGE=vbscript RUNAT=Server>
Sub thisPage_onenter()
DataTxtBox1.advise "onblur", "UpdateRec()"
End Sub
</SCRIPT>
<SCRIPT LANGUAGE=vbscript RUNAT=server>
Sub UpdateRec()...
Hi,
for making DTC's visible you have to use
button1.show()
to hide them use
button1.hide().
isVisible() method tells you if an object is visible or hidden.
"Defeat is not the worst of failures. Not to have tried is the true failure."
-George E. Woodberry
Hi,
if I understand correctly you want to hide your button just between server round trip. I don't think this is possible in server side code, did you try hiding or disabling it in client side code in onbeforeserver event.
Or why don't you make a disabled/hidden button and enable/show it in...
Hi Raver1,
you can correct me any time you like :)
I didn't know about the Jscript/JavaScript engine, I only know about the diffrences I have to make in code and I'm happy as long as it works on both browsers.
Metka "Defeat is not the worst of failures. Not to have tried is the true...
Hi,
as far as I know storing the value of the textbox in a session variable or updating a recordset allways requires a server round trip, so your page will allways reload.
Why would you want to do this in the onblur event? "Defeat is not the worst of failures. Not to have tried is the...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.