Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > ASP code

Reply
Thread Tools

ASP code

 
 
Lion
Guest
Posts: n/a
 
      09-22-2006
Could someone help me please.

I'm using a file called list.aspx to list the content of directories which
works fine. What I need its when the files get listed in the IE I would
like to have a two buttons next to the file name one to SAVE file and the
one to DELETE the file.

Thanks for your help.

This is the code in the file.

<html>

<head>
<meta name="GENERATOR" content="Microsoft FrontPage 6.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252">
<title>New Page 1</title>
</head>

<body>Please read the disclaimer at the bottom of this e-mail



<p><b><font face="Tahoma" color="#66CCFF" size="4">C drive
Stuff</font></b></p>

<%@ Import Namespace="System.IO" %>
<script language="VB" runat="server">
Sub Page_Load(sender as Object, e as EventArgs)
Dim dirInfo as New DirectoryInfo(Server.MapPath(""))

articleList.DataSource = dirInfo.GetFiles("*.pdf")
articleList.DataBind()
End Sub
</script>

<aspataGrid runat="server" id="articleList" Font-Name="Tahoma"
AutoGenerateColumns="False" AlternatingItemStyle-BackColor="#eeeeee"
HeaderStyle-BackColor="#66ccff" HeaderStyle-ForeColor="White"
HeaderStyle-Font-Size="10pt" HeaderStyle-Font-Bold="True">
<Columns>
<asp:HyperLinkColumn DataNavigateUrlField="Name"
DataTextField="Name"
HeaderText="File Name" />

<asp:BoundColumn DataField="LastWriteTime" HeaderText=
"Last Write Date"
ItemStyle-HorizontalAlign="Center " DataFormatString="{0:d}" />

<asp:BoundColumn DataField="LastWriteTime" HeaderText=
"Last Write Time"
ItemStyle-HorizontalAlign="Center " DataFormatString="{0:t}" />

<asp:BoundColumn DataField="Length" HeaderText="File Size"
ItemStyle-HorizontalAlign="Right"
DataFormatString="{0:#,### bytes}" />
</Columns>
</aspataGrid>


 
Reply With Quote
 
 
 
 
Lion
Guest
Posts: n/a
 
      09-25-2006
Thanks for your answer Gaurav,

I really don't know what you mean could you explain please.


Thanks.
"Gaurav Vaish (www.EduJiniOnline.com)"
<(E-Mail Removed)> wrote in message
news:%23BYcEN%(E-Mail Removed)...
>> I'm using a file called list.aspx to list the content of directories
>> which works fine. What I need its when the files get listed in the IE I
>> would like to have a two buttons next to the file name one to SAVE file
>> and the one to DELETE the file.

>
> Add a TemplateColumn to the list of Columns.
>
>
> --
> Happy Hacking,
> Gaurav Vaish | http://www.mastergaurav.com
> http://www.edujinionline.com
> http://articles.edujinionline.com/webservices
> -------------------
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
what is the difference between code inside a <script> tag and code in the code-behind file? keithb ASP .Net 1 03-29-2006 01:00 AM
Call a DLL LIB function in ASP.NET (Code Behind) or VB.NET (The same code is working fine in VB 6.0) Peri ASP .Net 2 07-20-2005 03:13 AM
server side code access the text of <asp:label> changed by client-side javascript code? nick ASP .Net 3 12-15-2004 06:26 PM
HTML code warnings in asp.net html code view Craig Kenisston ASP .Net 3 10-07-2004 04:05 PM
Fire Code behind code AND Javascript code associated to a Button Click Event =?Utf-8?B?Q2FybG8gTWFyY2hlc29uaQ==?= ASP .Net 4 02-11-2004 07:31 AM



Advertisments