473,383 Members | 1,980 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,383 software developers and data experts.

open.window javascript function not working within GridView

Dear all,
I tried to replace the GridView Column's HyperLinkField
"DataNavigateUrlFormatString" property with a java script pop up
window, but wehen i preview the page, the link is REMOVED! Does any one
see any thing wrong in the code below?

<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
DataKeyNames="ITEM_ID"
DataSourceID="SqlDataSource1">
<Columns>
<asp:BoundField DataField="ITEM_ID" HeaderText="Item
ID" ReadOnly="True"
Visible="False" />
<asp:HyperLinkField
DataNavigateUrlFields="ITEM_ID,ITEM_MODEL,ITEM_MAN UFACTURER"
DataTextField="ITEM_MODEL"
HeaderText="Model"
DataNavigateUrlFormatString="javascript:var
w=window.open('../ItemsDetails.aspx?ITEM_ID={0}&ITEM_MODEL={1}&ITEM_ MANUFACTURE={2}',null,'width=600,height=400');"
/>
<asp:BoundField DataField="ITEM_MANUFACTURER"
HeaderText="ITEM_MANUFACTURER"
SortExpression="ITEM_MANUFACTURER" />
</Columns>
</asp:GridView>
<asp:SqlDataSource ID="SqlDataSource1" runat="server"
ConnectionString="<%$ ConnectionStrings:MyDBConnectionString
%>"
ProviderName="<%$
ConnectionStrings:MyDBConnectionString.providerNam e %>"
SelectCommand="SELECT [ITEM_ID], [ITEM_MODEL],
[ITEM_MANUFACTURER] FROM [ITEM]">
</asp:SqlDataSource>

May 5 '06 #1
0 1774

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Paul Eaton | last post by:
Hi I am developing my first asp appication (vbscript). I am storing cheques scans (in pdf format) in the file system along with the db on the server. The following code is working without...
2
by: venkatesh | last post by:
Hi Members, I have used the below mentioned code to open a html page in a new browser. The window size is 200 x 300. In that browser, I've given code to open another browser of the same size....
4
by: Marcello | last post by:
Hello I have a page of 2 frame: menu (menu.php) corpo (corpo.php) In menu.php i have: <script> function selAut(){ aut=autore.selectedIndex; aut=autore.options.value;
10
by: Marshall Dudley | last post by:
When I do the following line in Netscape, the popup loads as it should, but the parent window usually, but not always, reloads as well. <a href="#"...
3
by: NeverLift | last post by:
But, if it's not open, I don't want to open it . . . using window.open will open it if it doesn't exist, even if the url in that open is null (the window is then empty -- but it's open). The...
26
by: yb | last post by:
Hi, Is there a standard for the global 'window' object in browsers? For example, it supports methods such as setInterval and clearInterval, and several others. I know that w3c standardized...
5
by: JNariss | last post by:
Hello, Within a form I created I have placed links that users can click on to view information. I am trying to write a javascript code so it opens in a sized window but I can't seem to figure...
18
by: len.hartley | last post by:
Hi, I am trying to pop-up a window when the user clicks on an image. The problem is that when the user clicks on the image and the window pops up OK, but the window underneath also proceeds to...
6
by: Jeff | last post by:
hey guys, this may not be the right place, but i wanted to give it a shot. i have an if statement, based on the data of a mssql db. if the if is .eof do nothing else
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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...

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.