摘要:
注意:本篇为博主原创,若要转载请注明出处,谢谢合作!前台:<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/Include/Admin_Main.master" AutoEventWireup="true" CodeFile="c.aspx.cs" Inherits="Test_file_c" StylesheetTheme="A... 阅读全文
摘要:
using System.Web;public class JScript{ /// <summary> /// 弹出JavaScript小窗口 /// </summary> public static void Alert(string message) { string js = "<script language='JavaScript'>alert('{... 阅读全文
摘要:
public static void FindFile(string dirPath) //参数dirPath为指定的目录 { //在指定目录及子目录下查找文件,在listBox1中列出子目录及文件 DirectoryInfo Dir = new DirectoryInfo(dirPath); try { foreach (DirectoryInfo d in Dir.GetDirectories... 阅读全文
摘要:
/**************************************** * 函数名称:GetFoldAll(string Path) * 功能说明:获取指定文件夹下所有子目录及文件(树形) * 参 数:Path:详细路径 * 调用示列: * string strDirlist = Server.MapPath("templates"); * this.Literal1.Te... 阅读全文
摘要:
//将虚拟目录转换成DataTable public static DataTable DirToDataTable(string strDir) { try { DataTable FileTable = new DataTable(); FileTable.Columns.Add(new DataColumn("name", typeof(String))); FileTable.Column... 阅读全文
摘要:
public static string fileUpladPost(string spath) { HttpFileCollection files = HttpContext.Current.Request.Files; StringBuilder strMsg = new StringBuilder(); for (int i = 0; i < files.Count; i++) { ... 阅读全文