当前位置:首页
开发技术指南» 文章正文
    引言:

 ·求sql    »显示摘要«
    摘要: 1. 由于项目完成要交工,客户需要数据库的维护手册给他们的技术人员使用。 但是我不知道格式,框架是怎么样的。请大虾赐教。 2.希望包括以下部分:维护,备份,恢复。这是我知道了几个方面,还有一些请大家增加。 3.最好是项目实际用过的。 4.如果这里不方便,请email to:christian_yan@yahoo.com.cn 感谢!!!! ......
    摘要: 小弟当了delphi8,研究了几天,苦于没有资料,进度较慢。所以希望在此欢迎高手们给点资料。也希望能借此与大家切磋一下学习的经验。 ......


有没有VB.net好书推荐.

我想学vb.net数据库方面的东西.有VB6.0的基础.大家有没有比较好的书推荐推荐,谢谢!

NO.1   作者: youngby

我灌罐~~我灌~~`我灌灌~~~灌得最专业~~  
  不给偶分~~~偶BS你~~不给偶分`~~偶鄙视你,鄙视你~~~  
  ---------------------------  
  Introduction  
  This   is   a   short   introduction   to   opening   an   existing   Microsoft   Excel   spreadsheet   using   Visual   C#   .NET.   The   computer   must   have   Excel   installed   on   the   system   for   this   code   to   run   properly.   The   Excel   assembly   is   used   to   open   and   manipulate   Excel   spreadsheets.  
   
  Code   Explanation    
  First,   the   Excel   assembly   must   be   added   to   the   project.   To   do   this   you   must   add   a   reference   to   the   Excel   10   Object   Library   (Excel   XP)   by   going   to   the   Project   ->   Add   Reference     menu   item.   Go   to   the   COM   tab   of   the   dialog   box   that   pops   up   and   scroll   down   the   Excel   10   Object   Library.   Double   click   on   it   and   press   OK.   This   adds   the   reference   to   your   project.   In   the   "using"   section   of   your   code,   type    
   
          using   Excel;    
  Once   the   assembly   is   added   to   the   project,   a   new   application   needs   to   be   created:  
   
          Excel.Application   excelApp   =   new   Excel.ApplicationClass();  
  If   you   want   to   make   Excel   visible   to   the   user   you   have   to   set   the   Visible   property   to   true,   the   default   is   false.    
   
          excelApp.Visable   =   true;  
  The   code   above   opens   the   Excel   application,   in   order   to   use   the   application,   you   have   to   open   a   workbook   by   creating   a   Workbook   object.   You   can   open   a   new   blank   workbook   by   using   the   following   code:  
   
          Excel.Workbook   newWorkbook   =    
                  excelApp.Workbooks.Add(XlWBATemplate.xlWBATWorksheet);  
   
  The   preceding   code   opens   a   blank   workbook   with   one   sheet.   The   .Add   method   takes   a   template   object,   the   XlWBATemplate.xlWBATWorksheet   object   is   a   built   in   template   for   a   blank   workbook.    
   
  If   you   want   to   open   an   existing   document   for   editing   instead   of   creating   a   new   one,   you   can   use   the   following   code   to   create   a   Workbook   object:  
   
          string   workbookPath   =   "c:/SomeWorkBook.xls";  
          Excel.Workbook   excelWorkbook   =   excelApp.Workbooks.Open(workbookPath,  
                  0,   false,   5,   "",   "",   false,   Excel.XlPlatform.xlWindows,   "",  
                  true,   false,   0,   true,   false,   false);  
  The   preceding   code   may   need   a   little   explanation.   The   workbookPath   is   of   course   the   path   to   the   existing   spreadsheet   that   you   want   to   open.   The   excelApp.Workbooks.open   is   a   little   less   obvious.   The   following   is   the   list   of   parameters   that   are   passed   to   the   function:  
   
  WorkBooks.open(string   Filename,   object   UpdateLinks,   object   ReadOnly,   object   Format,   object   Password,   object   WriteResPassword,   object   ReadOnlyRecommend,   object   Origin,   object   Delimiter,   object   Editable,   object   Notify,   object   Converter,   object   AddToMru,   object   Local,   object   CorruptLoad   )  
  To   view   the   documentation   on   this   function,   follow   the   link   Microsoft’s   website   for   further   explanation   of   the   function   at:    
   
  http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbaxl10/html/xlmthOpen.asp    
   
  Once   the   workbook   is   either   created   or   opened,   you   must   create   a   Sheets   object   that   holds   the   Worksheets   within   the   workbook.   The   following   code   will   get   all   of   the   sheets   in   the   workbook   you   previously   opened.  
   
          Excel.Sheets   excelSheets   =   excelWorkbook.Worksheets;  
  Now   that   you   have   the   collection   of   Worksheets,   you   must   get   an   individual   sheet   edit   data   within.  
   
          string   currentSheet   =   "Sheet1";  
          Excel.Worksheet   excelWorksheet   =    
                  (Excel.Worksheet)excelSheets.get_Item(currentSheet);  
  In   the   preceding   code,   you   have   to   type   cast   the   excelSheets.get_Item(string)   function   because   it   returns   an   object.   Now   that   you   have   the   sheet   you   are   ready   to   access   individual   cells   with   the   following   code:  
   
          Excel.Range   excelCell   =    
                  (Excel.Range)excelWorksheet.get_Range("A1",   "A1");  
  The   get_Range   function   must   take   two   parameters.   If   the   two   parameters   are   equal,   a   single   cell   is   selected;   otherwise   a   range   of   cells   will   be   selected.   Again   you   have   to   type   cast   the   return   value   of   the   function.   Once   you   have   a   cell   object,   your   can   set   its   value   using   the   .Value2   property,   or   use   any   of   the   other   properties   to   manipulate   ranges   of   cells.  
   
  Jeff   Ruys  
   
 


 ·resin+iis中乱码的问题。请帮忙    »显示摘要«
    摘要: 一个人很简的列子, 代码如下: index.jsp <%@ page contenttype = "text/html; charset = gb2312" %> <html> <head> <title>hello </title> </head> <body> <b>&......
» 本期热门文章:

©2000-2007 All Rights Reserved. 最佳浏览:1024X768 MSIE