Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP 3 Classic ASP Active Server Pages 3.0 > Classic ASP Basics
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old November 22nd, 2004, 01:21 PM
Registered User
 
Join Date: Nov 2004
Location: , , .
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Click on link to open file from .asp

First of all, excuse me if I sound like a fool, I am just getting started at this.

I have an .asp page which is displays a list of the contents of a windows folder. My goal is to be able to click on file name and open it up for viewing, like any other href link.

the code is currently

<tr>
<td class="TableHeader">Client Files</td>
</tr>

<%
If ClientFolderExists Then
%>
<tr>
<td class="Label">Folder: <a href="<%=ClientFolders & ClientFolder%>"> <%=ClientFolder%></a></td>
</tr>
<%
End If
%>
<tr>
<td>
<iframe height=300 frameborder=no src="ClientFiles.asp?FolderName=<%=Server.URLEncod e(ClientFolders & ClientFolder)%>"></iframe>
</td>
</tr>

As the code is now, I can right click on the link, copy the link and paste it into a browser and it will open up the file. However, I want simply to be able to click on the link to open up the file.

here is a sample link which the code creates

file:///c:/inetpub/wwwroot/matis/ClientFolders/Druse,%20III,%20Frank-126/ticket%20and%20agreement.tif

Reply With Quote
  #2 (permalink)  
Old November 22nd, 2004, 02:26 PM
Friend of Wrox
 
Join Date: Jun 2003
Location: Bangalore, KA, India.
Posts: 2,480
Thanks: 0
Thanked 1 Time in 1 Post
Default

Hi,
Quote:
quote:As the code is now, I can right click on the link, copy the link and paste it into a browser and it will open up the file. However, I want simply to be able to click on the link to open up the file.
Right now what do you see on the browser when you browse this page and how does that behave when you simple do a left click?

Cheers!

_________________________
- Vijay G
Strive for Perfection
Reply With Quote
  #3 (permalink)  
Old November 22nd, 2004, 03:02 PM
Registered User
 
Join Date: Nov 2004
Location: , , .
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

When I hover over the link, the cursor turns to a hand and I see the link displayed in the lower left corner of IE, across the bottom.

A simple left click does nothing.

I believe that the code is correctly creating the link, because I can copy and paste into a browser and it works.

Reply With Quote
  #4 (permalink)  
Old November 22nd, 2004, 03:58 PM
Friend of Wrox
 
Join Date: Jun 2003
Location: Bangalore, KA, India.
Posts: 2,480
Thanks: 0
Thanked 1 Time in 1 Post
Default

Not sure what you are missing. But copy/paste of link into browser is similar to clicking the link and that should work if the link is created correctly, as you say.

_________________________
- Vijay G
Strive for Perfection
Reply With Quote
  #5 (permalink)  
Old November 22nd, 2004, 04:18 PM
Registered User
 
Join Date: Nov 2004
Location: , , .
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I guess we are stuck.

By the way, when I cut and paste the page into Front Page, the links work fine

Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Link button click event sarah lee ASP.NET 2.0 Basics 5 May 18th, 2007 09:29 AM
double click to open link thutt Dreamweaver (all versions) 0 February 8th, 2007 05:01 PM
How to open .DOC in MS-Word file thru a link ? sherbir Javascript 10 March 8th, 2006 06:20 AM
Click on link in VB6 Perseus Beginning VB 6 1 August 30th, 2005 05:52 PM
How to open .DOC file with MS-Word thru a link ? sherbir Servlets 0 August 3rd, 2004 07:03 AM



All times are GMT -4. The time now is 12:29 AM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.