asp.netÎļþºÍÎļþ¼ÐѹËõ
·¨Ò»£ºµ÷ÓÃwinrar
using Microsoft.Win32;
using System.Diagnostics;
protected void Button1_Click(object sender, EventArgs e)
{
RAR(@"E:\95413594531\GIS", "tmptest", @"E:\95413594531\");
}
/// <summary>
/// ѹËõÎļþ
/// </summary>
/// <param name="DFilePath">ÐèҪѹËõµÄÎļþ¼Ð»òÕßµ¥¸öÎļþ</param>
/// <param name="DRARName">Éú³ÉѹËõÎļþµÄÎļþÃû</param>
/// <param name="DRARPath">Éú³ÉѹËõÎļþ±£´æ·¾¶</param>
/// <returns></returns>
protected bool RAR(string DFilePath, string DRARName,string DRARPath)
{
String the_rar;
RegistryKey the_Reg;
Object the_Obj;
String the_Info;
ProcessStartInfo the_StartInfo;
Process the_Process;
try
{
the_Reg = Registry.ClassesRoot.OpenSubKey(@"Applications\WinRAR.exe\Shell\Open\Command");
the_Obj = the_Reg.GetValue("");
the_rar = the_Obj.ToString();
the_Reg.Close();
the_rar = the_rar.Substring(1, the_rar.Length - 7);
the_Info = " a " + " " + DRARName + " " + DFilePath +" -ep1"; //ÃüÁî + ѹË
Ïà¹ØÎĵµ£º
½üÆÚÓöµ½asp.net mvc »·¾³ÅäÖÃÎÊÌ⣬ËäÈ»¶¼°²×°ÉÏÈ¥ÁË£¬µ«ÊÇÔÚ´´½¨ADO.net ʵÌåÊý¾ÝÄ£ÐÍÍê³Éºó£¬»áÆÈʹvs´°¿Ú¹Ø±Õ£¬µ±ÄãÖØдò¿ªºó·¢ÏÖmodelsÎļþÖÐʲôҲûÓУ¬µ«ÊÇÔÚÏîÄ¿ËùÔÚµÄλÖã¬modelsÖÐÓÐÄã¸Õ½¨µÄʵÌåÊý¾ÝÄ£ÐÍ£¬¿ì°ÑÎÒÓôÃÆËÀÁË£¡Õâµ½µ×ÊÇÔõô»ØÊ£¿
ÎÒÓõÄÊÇVS2008 ¼òÌåÖÐÎÄרҵ°æ
AspNetMVC 1.0
vs2008 s ......
http://hi.baidu.com/%E5%EB%B3%DF%C8%CB%C9%FA/blog/item/58a1540bbf0bb437b1351d9a.html
#region DataGridViewÊý¾ÝÏÔʾµ½Excel
/// <summary>
/// ´ò¿ªExcel²¢½«DataGridView¿Ø¼þÖÐÊý¾Ýµ¼³öµ½Excel
/// </summary>
/// <param name="dgv">DataGridView¶ÔÏó </param>
/// <param na ......
1. Asp.NetÖм¸ÖÖÏàËƵıê¼Ç·ûºÅ: < %=...%>< %#... %>< % %>< %@ %>½âÊͼ°Ó÷¨
´ð: < %#... %>: ÊÇÔڰ󶨿ؼþDataBind()·½·¨Ö´ÐÐʱ±»Ö´ÐУ¬ÓÃÓÚÊý¾Ý°ó¶¨
Èç: < %# Container.DataItem("tit") %>
< %= %>: ÔÚ³ÌÐòÖ´ÐÐʱ±»µ÷Ó㬿ÉÒÔÏÔʾºǫ́±äÁ¿Öµ
Èç:
*.aspxÖУº < %= ......
1¡¢Èç¹ûÕâÖÖÇé¿ö³öÏÖÔÚ±¾»ú£¬ÔòÔÚsql server µÄÆóÒµ¹ÜÀíÆ÷µÄ¿ØÖÆ̨Ŀ¼ÀïÑ¡ÔñÏàÓ¦µÄÊý¾Ý¿â£¬ÔÚÆäϵÄÓû§½ÚµãµãÓÒ¼üн¨Êý¾Ý¿âÓû§£¬½«***\ASPNETÓû§¼ÓÈ룬²¢¸³ÓèpublicȨÏÞ¡£
2¡¢Èç¹û³öÏÖÔÚÆäËûµÄµçÄÔ£¬Ôò¼ì²é ³ÌÐòÁ¬½ÓSQLServerµÄÁ¬½Ó×Ö·û´®ÊDz»ÊÇÓÃÁËwindows¼¯³ÉµÇ½£¬Ò»°ã³öÏÖ´ËÎÊÌâµÄ×´¿ö¶¼ÊÇÒòΪʹÓÃÁËwindows¼¯³Éµ ......
=================================<1>Ò³Ãæ¿ØÖÆ ======================================
<script type ="text/javascript" src="../js/Calendar.js"charset ="gb2312"></script>
<input ID="Text1" type="text" runat="server" onfocus="calendar()"/>
<!- ......