|
if you know C# in Windows Form instead of Web Form you know that when you want to pass data from one window to another you only have to make something like this :
Dialog2 dlg = new Dialog2();
dlg.label1.Text = this.text1.Text;
now I want to make the same thing but in web form
I have a form login in asp.net and if the user enter the correct username and password I want to access to the main page(the one after the login) and show his name in a label.
how can I do this ??
Source will be appreciate or reference
thanks
|
|
|
|
|
somewhere in your login.aspx page you would redirect user to your main page...
Response.Redirect("main.aspx?name=BLaZiNiX");
... in your main page in Page_Load(...)
label1.Text = Request.QueryString["name"];
Mike M
WinInsider.com
|
|
|
|
|
I have a pop up menu on my site. I have it built and have running. When you click on a menu option a submenu pops up.
What I am having problems with is once the menu is open it will not go away, unless you click another menu option that has a sub-menu. I have found many menu setups on the net, but none seem to address this issue
Is there any way that when I click on the browser window elsewhere it hides the submenu? I thought I saw an onclick event in the tag, but I have not been able to get that to work, or find it any where else.
Don't argue with idiots,
They drag you down to their level,
and beat you with expereince.
|
|
|
|
|
Hmm, I used the onclick event of the body and it worked... Check your code again, it should work. You can try to make a timer also, so menu disapears after some time passed
Philip Patrick
Web-site: www.stpworks.com
"Two beer or not two beer?" Shakesbeer
Need Web-based database administrator? You already have it!
|
|
|
|
|
When I include an onClick event on my body tag, the onClick for the buttons stops working. Thank you for replying. I appreciate the help.
Never argue with idiots,
they drag you down to their level,
and Beat you with Expereince.
|
|
|
|
|
Well, you need to save the previous onclick handler, and then restore it after hiding menu. This way I did as I remember
Philip Patrick
Web-site: www.stpworks.com
"Two beer or not two beer?" Shakesbeer
Need Web-based database administrator? You already have it!
|
|
|
|
|
Hi, I am calling stored procedures from my ASP page. One of the stored procedures has 2 recordsets in it. I can get the second one fine in query analyser, but don't know how to call the field name values out of the second one from my ASP page. Can anyone help please?
Polymorph
|
|
|
|
|
Use the NexRecordset method
Here
|
|
|
|
|
I need to write more than 4000 character in a cookie, how can I do that ? Can I make more than one cookie ? Is there any way to bake larger cookie ?
Thanks
Guillaume Frechette
|
|
|
|
|
Cookies were not meant to store encyclopedia volumes. Find another way or break it into multiple cookies.
|
|
|
|
|
That's exactly what I'm trying to do... I use cookie for saving web-games data... Can i do set different cookie for my different path on the same domain... Example : if I have www.mysite.com/subsite1/main.html and www.mysite.com/subsite2/main.html , can I have two differents cookie file for subsite1 and subsite2...
Thanks
Guillaume Frechette
|
|
|
|
|
Why not use the cookie to store an ID that you can use to retrieve a large amount of data from a persisted storage on the web server?
EG: store the userID in a cookie then get a bunch of data out of a database on the server?
Cheers,
Simon
"Every good work of software starts by scratching a developer's personal itch.", Eric S. Raymond
|
|
|
|
|
I have one a Lan (Client - Server), and I want update file everyday, but I don't know how to copy one file thought Lan
please help me, thanks!!!
|
|
|
|
|
When I access the site free porn,I don't download and save file "dial.exe" but it appeared in my path "C:\dial.exe"
You can tell me why??
what script can do that? (show me this script)
thanks
|
|
|
|
|
Security holes in IE or somebody else have been using your computer
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
J.-C. Gauthier - http://www.grandmenhir.com/
|
|
|
|
|
¿How would a asp.net page could send a instant message to ICQ, Aol, yahoo messenger o microsoft messenger?. I don't even have idea how to do it form a windows form... ¿Any suggestion? ¿Anybody knows where should I look to solve this?...
Reality.sys is corrupted!
Reboot the universe Y/N?
|
|
|
|
|
You would have to download the SDKs for these IM services. I know that MSDN provides the Messenger SDK off of the SDK portion of thier site. However, I don't know about AOL, Yahoo, or ICQ.
David Stone
dstone@newcenturytitle.com
MEEKNESS, n. Uncommon patience in planning a revenge that is worth while.
The Devil's Dictionary, Ambrose Bierce
|
|
|
|
|
Where do you store your db connection strings? I have been placing mine under appSettings in the web.config file and accessing it through ConfigurationSettings.AppSettings.
A recent security breach has left me wondering though. Anyone have thoughts on the matter.
|
|
|
|
|
Mark Nischalke wrote:
I have been placing mine under appSettings in the web.config file and accessing it through ConfigurationSettings.AppSettings
that´s where I put them too...
Mauricio Ritter - Brazil
Sonorking now: 100.13560 Trank
The alcohol is one of the greatest enemys of man, but a man who flee from his enemys is a coward.
|
|
|
|
|
There are several example of this in MSDN. I have now reconsidered this though. My hosting service uninstalled .NET from their servers which left all the files, including the web.config, downloadable by anyone who cared to enter them in the navbar.
I have since created a dll to place the settings in. People can still download it if the site is exposed again, but it will be harder to decompile then reading an xml document.
|
|
|
|
|
I use a system DSN in web.config
<appSettings>
<add key="DsnMyDB" value="Provider=MySQLProv;Data Source='DSN=MyDB'" />
</appSettings>
and then access it from code with
ConfigurationSettings.AppSettings["DsnMyDB"];
<b>Todd Smith</b>
|
|
|
|
|
Several controls on my UserControl have little red exclamation point icons over them. Hovering over them, or clicking them (with either mouse button) tells me nothing about what they mean. When I run my web page, it works fine. Huh???
Thanks in advance for any help.
Jamie Nordmeyer
Portland, Oregon, USA
|
|
|
|
|
Hello!
Is anyone familiar with how to make an ASP template site.
Would this require making an Application for IIS? or no?
Anyone have some advice or ideas?
Thanks,
-Sean
|
|
|
|
|
mrhsean wrote:
Is anyone familiar with how to make an ASP template site.
Would this require making an Application for IIS? or no?
The common way is to use INCLUDE files.
You have your template code in seperate INCLUDE files which are then included into the content pages.
e.g.
Your template files:
header.asp
<html>
<head>
<title><%=strTitle%></title>
</head>
<body>
menu.asp
<table align="left">
<tr>
<td>
<a href="default.asp">Home</a><br>
<a href="about.asp">About</a>
</td>
</tr>
</table>
footer.asp
<p>Copyright Joe Schmoe</p>
</body>
</html>
Now your pages:
default.asp
<%
Dim strTitle
strTitle = "Home"
%>
<!-- #include file="header.asp" -->
<!-- #include file="menu.asp" -->
<h1>Welcome to my page</h1>
<p>Hi, blah blah balhb albhablahb</p>
<!-- #include file="footer.asp" -->
about.asp
<%
Dim strTitle
strTitle = "About"
%>
<!-- #include file="header.asp" -->
<!-- #include file="menu.asp" -->
<h1>About Us</h1>
<p>Hi, blah blah balhb albhablahb some other content</p>
<!-- #include file="footer.asp" -->
The above will have two content pages called about.asp and default.asp. Both use the header.asp, menu.asp and footer.asp template files which wrap around the individual content for each page.
You can then edit the menu.asp file and it will be reflected in both the home and about pages.
Hope that is what you meant by templates
regards,
Paul Watson
Bluegrass
Cape Town, South Africa
The greatest thing you'll ever learn is just to love, and to be loved in return - Moulin Rouge
Tim Smith wrote:
Over here in the third world of humor (a.k.a. BBC America),
peterchen wrote:
We should petition microsoft to a "target=_Paul" attribute.
|
|
|
|
|
I create one TextArea in FrontPage and set it :
...
One
Two
Three
....
I want that, when choose one option and click submit, it will link to my data on my hard disk
help me...
thanks !!
|
|
|
|