473,399 Members | 3,038 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

PopUP Window

Hi

Anyone help me.I need a popup window when i click button.


When i click button it show the popup window with employee code from database table.

I used ASP.net(C#) with sqlserver


Pls help me
Its urgent for my project.


Regards
Shalini
May 30 '08 #1
5 1184
Curtis Rutland
3,256 Expert 2GB
Any popups would have to be created with a client side script, not ASP.NET. ASP.NET runs on the server. To get the javascript you need to create a popup window, try here (first google result for javascript popup window).

What you should do is create the page that you want to appear in the popup window. Have it use a querystring (Request.QueryString["key"];) to pass on the key value(s) to select against from your database table.\

Hi

Anyone help me.I need a popup window when i click button.


When i click button it show the popup window with employee code from database table.

I used ASP.net(C#) with sqlserver


Pls help me
Its urgent for my project.


Regards
Shalini
May 30 '08 #2
Thank u very much for ur reply.

I got the window.Onpage load of the popwindow i load employee id.I want to select the id from the pop up window ,based on the id all the details of that particular id will display in lots textbox.


I want to know how to select item from the popup window.

pls help me.
May 30 '08 #3
kunal pawar
297 100+
do you mean, you want to take value from Child window ?
May 30 '08 #4
yes In my child window there is one list box containing employee id.when i select any one employee id from child window,it should display in my parent window.
May 30 '08 #5
Frinavale
9,735 Expert Mod 8TB
Hi

Anyone help me.I need a popup window when i click button.


When i click button it show the popup window with employee code from database table.

I used ASP.net(C#) with sqlserver


Pls help me
Its urgent for my project.


Regards
Shalini
You need to apply JavaScript to the button so that it opens the ASPX page that displays your employee in a new window.

The JavaScript to do this is the following:
Expand|Select|Wrap|Line Numbers
  1. window.open("nameOfAspxPage.aspx","nameOfWindow", "toolbar=yes,menubar=yes, width=980, height=700, resizable=yes,scrollbars=yess")
  2.  

You need to call this JavaScript code on the Client Side onclick event.
So you need to add it to your button's attributes:

VB:
Expand|Select|Wrap|Line Numbers
  1. theButtonThatOpensTheWindow.Attributes.Add("onclick","javascript:window.open("""+"nameOfAspxPage.aspx"""+","""+"nameOfWindow"""+", """+"toolbar=yes,menubar=yes, width=980, height=700, resizable=yes,scrollbars=yes"""+"); return false;")
  2.  
C#:
Expand|Select|Wrap|Line Numbers
  1. theButtonThatOpensTheWindow.Attributes.Add("onclick","javascript:window.open(\"nameOfAspxPage.aspx\",\"nameOfWindow\", \"toolbar=yes,menubar=yes, width=980, height=700, resizable=yes,scrollbars=yes\"); return false;")
  2.  
Please note that I added a "return false" after the window.open() method call. This prevents the ASPX button from posting back to the server.

Cheers

-Frinny
May 30 '08 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Noozer | last post by:
When using the WebBrowser control, is it possible to cause popup windows to appear within the WebBrowser control itself instead of a new window? This is what I've written in the NewWindow2 event,...
2
by: Moon | last post by:
Seems I still haven't got the hang of all those window generating code in Javascript. I've got a page with about 15 photo thumbnails. When you click on a thumbnail a new window pops up which shows...
5
by: Obantec Support | last post by:
Hi i leached some code and strung together a popup i need for a page with 5 help buttons. Now i could use 5 scripts and pre-load the values but i would rather get a better understanding of how...
38
by: Shaun McKinnon | last post by:
HI...Here's my problem...I have a popup window that loads when i want it to, but it's not sized properly. I've set the size, but it doesn't seem to work. I've been on 8 different websites to find...
7
by: E Michael Brandt | last post by:
I have been lurking here for some time, and now would like to ask a question of you clever coders: My JustSo PictureWindow 3 Extension for Dreamweaver has stumbled in the face of the new Opera...
15
by: | last post by:
So many websites can get around my Googlebar's popup blockers. Even Opera 8 can not stop those popups. I looked into the codes, and I can find nothing showing me how it is done. Can anyone help me...
4
by: Davey | last post by:
I have a website which has a popup window (this only opens when the user chooses to open it). In the popup window I have a <select> control which lists a selection of "classes". Each class has a...
3
by: ypress | last post by:
Hi. I have a page that contains this simple function: <script language="javascript"> function openPop(url, name, w, h) { var features = ""; features += "scrollbars=no,"; features +=...
4
by: GrantS | last post by:
I am having a problem closing a popup window opened modally. When I try to close the window (when the user hits save button and the data has been processed), the Popup window opens as a full screen...
7
by: anthony.turcotte | last post by:
Hi, I've looked for a solution to this problem on google, read posts in this newsgroup and I still haven't found anything that could help me. Here's the scenario. 1. User accesses...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.