473,462 Members | 1,333 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Onclick malfunction with a variable hyperlink?



I have files that are created with a dynamic name that I want to have
hyperlinks created. Things work when I have a static name, but give me
the 404 when I throw in the dynamic stuff.

Here's the Onclick code:

<a name="dnbreports"></a>
<p align="center" class="text1">
<a href="#dnbreports" onclick="openWin_onClick1()">Submitted Transaction
Details </a>
</p>
<p align="center" class="text1">
<a href="#dnbreports" onclick="openWin_onClick2()">D and B Report </a>
</p>
<p align="center" class="text1">
<a href="#dnbreports" onclick="openWin_onClick3()">Experian Report 1</a>
</p>
<p align="center" class="text1">
<a href="#dnbreports" onclick="openWin_onClick4()">Experian Report 2</a>
</p>

The onclick calls the functions:
function openWin_onClick1()
open "ReportFiles/" & filename & "tranxn_report.rtf", "tranxn",
"width=660,height=550, menubar, scrollbars=yes, resizable,"
end function

function openWin_onClick2()
open "ReportFiles/" & filename & "dnb_report.rtf", "dnb",
"width=660,height=550, menubar, scrollbars=yes, resizable,"
end function

function openWin_onClick3()
open "ReportFiles/" & filename & "xpn_report1.rtf", "xpn", "width=670,
height=550, menubar, scrollbars=yes, resizable,"
end function

function openWin_onClick4()
open "ReportFiles/xpn_report2.rtf", "xpn2", "width=670, height=550,
menubar, scrollbars=yes, resizable,"
end function
What in the world am I missing or messed up on?

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 22 '05 #1
1 1759
> What in the world am I missing or messed up on?
This is an ASP group, not client-side programming group. Try one of the
client-side scripting groups.

PS - Change this (& filename &) to this (<%=filename%>).

Bob Lehmann

"Micromanaged" <Mi**********@helpmeplease.net> wrote in message
news:O1*************@TK2MSFTNGP12.phx.gbl...


I have files that are created with a dynamic name that I want to have
hyperlinks created. Things work when I have a static name, but give me
the 404 when I throw in the dynamic stuff.

Here's the Onclick code:

<a name="dnbreports"></a>
<p align="center" class="text1">
<a href="#dnbreports" onclick="openWin_onClick1()">Submitted Transaction
Details </a>
</p>
<p align="center" class="text1">
<a href="#dnbreports" onclick="openWin_onClick2()">D and B Report </a>
</p>
<p align="center" class="text1">
<a href="#dnbreports" onclick="openWin_onClick3()">Experian Report 1</a>
</p>
<p align="center" class="text1">
<a href="#dnbreports" onclick="openWin_onClick4()">Experian Report 2</a>
</p>

The onclick calls the functions:
function openWin_onClick1()
open "ReportFiles/" & filename & "tranxn_report.rtf", "tranxn",
"width=660,height=550, menubar, scrollbars=yes, resizable,"
end function

function openWin_onClick2()
open "ReportFiles/" & filename & "dnb_report.rtf", "dnb",
"width=660,height=550, menubar, scrollbars=yes, resizable,"
end function

function openWin_onClick3()
open "ReportFiles/" & filename & "xpn_report1.rtf", "xpn", "width=670,
height=550, menubar, scrollbars=yes, resizable,"
end function

function openWin_onClick4()
open "ReportFiles/xpn_report2.rtf", "xpn2", "width=670, height=550,
menubar, scrollbars=yes, resizable,"
end function
What in the world am I missing or messed up on?

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Jul 22 '05 #2

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

Similar topics

14
by: Erik | last post by:
I need to submit a form using a hyperlink, and I need to pass a variable associated with that hyperlink. Example: I have a page where employees enter event information, and they are supplied a...
5
by: Mike | last post by:
In my previous post, I wrote: > ... > GOAL: (very simple) Provide a hyperlink which, when clicked, > calls a javascript function which opens a new URL. > ... > PROBLEM: The following code...
3
by: Roderik | last post by:
What is preferable? <a href="javascript:my_function();">hyperlink</a> or <a href="#" onClick="my_function();">hyperlink</a> -- http://www.archytas.nl/
4
by: Robert Oschler | last post by:
I have a web page that tracks clicks on certain hyperlinks. I am using attachEvent() to attach to the document onClick handler, for IE browsers. It works fine, except that for about 1 out of every...
3
by: Wayne Wengert | last post by:
I have an application where a session variable is set in an ASPX page, The process calls an ASP page and when in that page the session variable appears to be null. How can I pass a session variable...
0
by: Diane Yocom | last post by:
I'm very new to ASP.Net and probably jumped in a little over my head, but... I'm trying to create a user control that will control navigation through my site. It's sortof like Amazon.com, where...
1
by: Joshua Weir | last post by:
Hi, Is there an onclick event function for hyperlink buttons? I couldnt seem to find one. How else would i do checks at the client side (such as if correct information is displayed in a textbox...
0
by: Amil Hanish | last post by:
I have a GridView with a <asp:HyperLinkinside a <TemplateItem>. I want to add the javascript onclick code to confirm the link click. What is the best way to do this? I can put the onclick=......
2
by: =?Utf-8?B?Uml0YUc=?= | last post by:
I posted this question in the C# discussion group but am posting it here also since ASP is involved. I'm new to C# and need some help regarding an onClick event not firing. I have a data grid...
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
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
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
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

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.