| 订阅 | 在线投稿
分享
 
 
当前位置: 王朝网络 >> vb >> Excel-VBA wen jian cao zuo

Excel-VBA wen jian cao zuo

2008-08-22 06:50:28 编辑來源:互联网 评论
 
 
 
本文为【Excel-VBA文件操作】的拼音翻译版
  zai wo men ri chang shi yong Excel de shi hou , bu jin hui yong dao dang qian Excel wen jian de shu ju , huan jing chang xu yao fang wen qi ta de shu ju wen jian 。 zhe xie shu ju wen jian ke neng shi Excel wen jian 、 wen ben wen jian huo shu ju ku wen jian deng 。 jing chang you peng you hui wen ru he zai vba dai ma li cao zuo zhe xie shu ju wen jian ? ben wen jiu xi tong di jie shao yi xia zai Excel zhong ying yong VBA cao zuo shu ju wen jian de fang fa 。
  ben wen zhu yao jie shao si zhong chang yong de fang fa :
  1、 li yong Excel dui xiang lai chu li wen jian ;
  2、 li yong VBA wen jian chu li yu ju lai chu li wen jian ;
  3、 li yong FileSystemObject dui xiang lai chu li wen jian ;
  4、 li yong API han shu lai chu li wen jian 。
  dang ran dui yu shu ju ku wen jian , huan ke yi li yong ADO+SQL de fang fa cao zuo , bu guo lun tan yi jing you qian bei xiang xi jie shao guo ci lei fang fa , ben wen jiu bu zai chong fu le 。
  yi 、 li yong Excel dui xiang lai chu li wen jian
  li yong Excel dui xiang zi dai de fang fa lai cao zuo wen jian shi zui fang bian , ye shi zui jian dan de 。
  wo men zhu yao li yong Workbooks ji he he Workbook dui xiang de fang fa lai cao zuo wen jian 。
  1、 da kai Excel wen jian
  wo men ke yi yong Workbooks.Open fang fa da kai yi ge Excel gong zuo bao 。
  Workbooks.Open(FileName, UpdateLinks, ReadOnly, Format, Password, WriteResPassword, IgnoreReadOnlyRecommended, Origin, Delimiter, Editable, Notify, Converter, AddToMru, Local, CorruptLoad)
   qi zhong FileName shi bi xuan de shen shu , biao shi yao da kai de gong zuo bao ming , ru guo mei you zhi ding lu jing , ze dai biao dang qian lu jing 。 ling wai 14 ge shi ke xuan shen shu , chu le mi ma shen shu , qi ta de yi ban hen shao yong 。 ju ti de han yi ke yi shen kan VBA de bang zhu 。
  li :
   Workbooks.Open "F:\test.xls"
  ke yi da kai F pan de test.xls wen jian 。
  2、 da kai wen ben wen jian
   shi yong Open fang fa ye ke yi da kai wen ben wen jian , dan jian yi shi yong OpenText fang fa 。 ci fang fa shi zai ru yi ge wen ben wen jian , bing jiang qi zuo wei bao han dan ge gong zuo biao de gong zuo bao jin xing fen lie chu li , ran hou zai ci gong zuo biao zhong fang ru jing guo fen lie chu li de wen ben wen jian shu ju 。 wan zheng yu fa ru xia :
  Workbooks.OpenText(FileName, Origin, StartRow, DataType, TextQualifier, ConsecutiveDelimiter, Tab, Semicolon, Comma, Space, Other, OtherChar, FieldInfo, TextVisualLayout, DecimalSeparator, ThousandsSeparator, TrailingMinusNumbers, Local)
  guan yu yi shang shen shu de ju ti han yi ke yi shen kan VBA de bang zhu , zhe li jiu bu chong fu le 。 zai shi ji de bian cheng zhong , yi ban wu xu dui zhe xie fu duo de shen shu jin xing chu li 。 ke yi tong guo lu zhi hong lai de dao da kai yi ge wen ben wen jian de VBA dai ma 。 ju ti fang fa jiu shi xuan ze “ wen jian —— da kai ”, ran hou xuan ze da kai wen ben wen jian , jiu hui chu xian wen ben dao ru xiang dao , yi bu yi bu zhi xing wan , zhi dao wen ben da kai hou , ting zhi lu zhi 。
  yi xia shi lu zhi hong de dao de dai ma :
  Sub Macro1()
  '
  ' Macro1 Macro
  ' hong you MC SYSTEM lu zhi , shi jian : 2007-3-29
  '
  '
   Workbooks.OpenText Filename:="F:\CallWindowProc.txt", Origin:=xlWindows, _
   StartRow:=1, DataType:=xlDelimited, TextQualifier:=xlDoubleQuote, _
   ConsecutiveDelimiter:=False, Tab:=True, Semicolon:=False, Comma:=False _
   , Space:=False, Other:=False, FieldInfo:=Array(1, 1), _
   TrailingMinusNumbers:=True
  End Sub
  zai shi ji bian cheng zhong zhi yao zuo xiang ying de xiu gai jiu ke yi shi yong le 。
  3、 da kai qi ta wen jian
  li yong Excel dui xiang huan ke yi da kai XML wen jian he yi xie shu ju ku ( ru Access) wen jian , dui ying XML wen jian , xu yao Excel2003 yi shang de ban ben 。
  OpenXML fang fa de yu fa ru xia :
  Workbooks.OpenXML(Filename, Stylesheets, LoadOption)
  FileName String lei xing , bi xu 。 yao da kai de wen jian ming 。
  Stylesheets Variant lei xing , ke xuan 。 dan ge zhi huo zhi de shu zu , yong yu zhi ding yao ying yong na xie XSL zhuan huan (XSLT) yang shi biao chu li zhi ling 。
  LoadOption Variant lei xing , zhuan huan 。 zhi ding Excel da kai XML shu ju wen jian de fang shi 。 ke wei XlXmlLoadOption chang liang zhi yi 。
  XlXmlLoadOption ke wei yi xia XlXmlLoadOption chang liang zhi yi :
  xlXmlLoadImportToList jiang XML shu ju wen jian de nei rong zhi yu XML lie biao zhong 。
  xlXmlLoadMapXml zai “XML jie gou ” ren wu chuang ge zhong xian shi XML shu ju wen jian de jia gou 。
  xlXmlLoadOpenXml da kai XML shu ju wen jian 。 wen jian de nei rong jiang zhan kai 。
  xlXmlLoadPromptUser ti shi yong hu xuan ze da kai wen jian de fang shi 。
  shi li
  xia mian de dai ma da kai le XML shu ju wen jian “customers.xml” bing zai XML lie biao zhong xian shi le ci wen jian de nei rong 。
  Sub UseOpenXML()
   Application.Workbooks.OpenXML _
   Filename:="customers.xml", _
   LoadOption:=xlXmlLoadImportToList
  End Sub
  OpenDatabase fang fa yu fa ru xia :
  Workbooks.OpenDatabase(FileName, CommandText, CommandType, BackgroundQuery, ImportDataAs)
  FileName String lei xing , bi xu 。 lian jie zi fu chuan 。
  CommandText Variant lei xing , ke xuan 。 cha xun de ming ling wen ben 。
  CommandType Variant lei xing , ke xuan 。 cha xun de ming ling lei xing 。 yi xia shi ke yong de ming ling lei xing :Default、SQL he Table。
  BackgroundQuery Variant lei xing , ke xuan 。 cha xun de bei jing 。
  ImportDataAs Variant lei xing , ke xuan 。 que ding cha xun de ge shi 。
  shi li
  ben shi li zhong ,Excel da kai le “northwind.mdb” wen jian 。
  Sub OpenDatabase()
  Workbooks.OpenDatabase FileName:="C:\northwind.mdb"
  End Sub
  4、 bao cun wen jian
  wen jian de bao cun shi yong Workbook dui xiang de Save huo SaveAs fang fa 。
  Save fang fa shi yong jian dan , yu fa wei
  expression.Save,expression shi mou ge Workbook dui xiang 。
  ru :ActiveWorkbook.Save
  ji bao cun dang qian huo dong gong zuo bao 。
  ru guo shi di yi ci bao cun gong zuo bao huo yao ling cun wei , qing shi yong SaveAs fang fa wei gai wen jian zhi ding wen jian ming 。
  qi yu fa wei :
  expression.SaveAs(FileName, FileFormat, Password, WriteResPassword, ReadOnlyRecommended, CreateBackup, AccessMode, ConflictResolution, AddToMru, TextCodepage, TextVisualLayout, Local)
  ju ti shen shu han yi ke shen kan VBA bang zhu , shi yong dou bi jiao jian dan 。
  shi li
  ben shi li xin jian yi ge gong zuo bao , ti shi yong hu shu ru wen jian ming , ran hou bao cun gai gong zuo bao 。
  Set NewBook = Workbooks.Add
  Do
   fName = Application.GetSaveAsFilename
  Loop Until fName <> False
  NewBook.SaveAs Filename:=fName
  Application.GetSaveAsFilename wei tiao chu biao zhun de “ ling cun wei ” dui hua kuang , huo qu yong hu wen jian ming , dan bing bu zhen zheng bao cun ren he wen jian , ran hou shi yong dai ma bao cun wen jian 。 huan you Application.GetOpenFileName ke yi tiao chu biao zhun de “ da kai ” dui hua kuang 。
  5、 guan bi wen jian
  guan bi wen jian ke yi shi yong Workbooks ji he huo Workbook dui xiang de Close fang fa 。 qian zhe shi guan bi suo you da kai de gong zuo bao , hou zhe guan bi te ding de gong zuo bao 。
  Workbook dui xiang de Close fang fa yu fa wei :
  expression.Close(SaveChanges, Filename, RouteWorkbook)
  SaveChanges shen shu biao shi shi fou bao cun geng gai , dui xu duo bu xu yao geng gai de cao zuo , ke she zhi wei False yi mian tan chu bao cun geng gai ti shi de dui hua kuang 。
  FileName ke xuan 。 yi ci wen jian ming bao cun suo zuo de geng gai 。
  RouteWorkbook ke xuan 。 ru guo zhi ding gong zuo bao bu xu yao chuan song gei xia yi ge shou jian ren ( mei you chuan song ming dan huo yi jing chuan song ), ze hu lue gai shen shu 。
  shi li
  ben shi li guan bi Book1.xls, bing fang qi suo you dui ci gong zuo bao de geng gai 。
  Workbooks("BOOK1.XLS").Close SaveChanges:=False
  ben shi li guan bi suo you da kai de gong zuo bao 。 ru guo mou ge da kai de gong zuo bao you gai bian ,Microsoft Excel jiang xian shi xun wen shi fou bao cun geng gai de dui hua kuang he xiang ying ti shi 。
  Workbooks.Close
  6、 zong he shi li
  jia ru F pan you yi ge Excel wen jian test.xls, xian zai you ling yi ge Excel wen jian yao fang wen test.xls de shu ju , wo men lai kan yong VBA dai ma ru he cao zuo 。 dai ma ru xia :
  Public Sub test()
  Application.ScreenUpdating = False
  Workbooks.Open "f:\test.xls"
  ThisWorkbook.Sheets(1).Range("b1") = ActiveWorkbook.Sheets(1).Range("a2")
  ActiveWorkbook.Close
  Application.ScreenUpdating = True
  End Sub
  shou xian guan bi ping mu shua xin , shi wei le fang zhi test.xls zai da kai shi bei kan jian ( you shi hou huan shi kan de jian )。 da kai hou , jian test.xls de Sheet1 de dan yuan ge A2 zhong de zhi fu gei dang qian gong zuo bao de Sheet1 de dan yuan ge B2, ran hou guan bi test.xls。
  dang yao da kai de gong zuo bao bu que ding de shi hou , ke yi tong guo tiao yong da kai dui hua kuang lai rang yong hu zi ji xuan ze 。
  ke gai wei ru xia :
  Public Sub test()
  Application.ScreenUpdating = False
  Dim Filename as String
  Filename = Application.GetOpenFileName
  Workbooks.Open Filename
  ThisWorkbook.Sheets(1).Range("b1") = ActiveWorkbook.Sheets(1).Range("a2")
  ActiveWorkbook.Close
  Application.ScreenUpdating = True
  End Sub
  7、 zong jie
  li yong Excel dui xiang de fang fa jin xing wen jian cao zuo shi zui jian dan , ye shi zui fang bian de , shi he chu xue zhe 。 dui yu Excel wen jian ge shi , ru guo wo men jin jin shi du qu qi biao ge zhong de nei rong , zhe zhong fang fa ye shi shou xuan 。 dui yu wen ben wen jian de cao zuo , shi yong di er zhong fang fa bi jiao fang bian , ruo yao jiang wen ben zhuan huan cheng biao ge , na me shi yong ci fang fa ye shi he shi de 。【原文】【汉音对照
 
 
 
 
 
 
 
 
 
日版宠物情人插曲《Winding Road》歌词

日版宠物情人2017的插曲,很带节奏感,日语的,女生唱的。 最后听见是在第8集的时候女主手割伤了,然后男主用嘴帮她吸了一下,插曲就出来了。 歌手:Def...

兄弟共妻,我成了他们夜里的美食

老钟家的两个儿子很特别,就是跟其他的人不太一样,魔一般的执着。兄弟俩都到了要结婚的年龄了,不管自家老爹怎么磨破嘴皮子,兄弟俩说不娶就不娶,老父母为兄弟两操碎了心...

如何磨出破洞牛仔裤?牛仔裤怎么剪破洞?

把牛仔裤磨出有线的破洞 1、具体工具就是磨脚石,下面垫一个硬物,然后用磨脚石一直磨一直磨,到把那块磨薄了,用手撕开就好了。出来的洞啊很自然的。需要猫须的话调几...

我就是扫描下图得到了敬业福和爱国福

先来看下敬业福和爱国福 今年春节,支付宝再次推出了“五福红包”活动,表示要“把欠大家的敬业福都还给大家”。 今天该活动正式启动,和去年一样,需要收集“五福”...

冰箱异味产生的原因和臭味去除的方法

有时候我们打开冰箱就会闻到一股异味,冰箱里的这种异味是因为一些物质发出的气味的混合体,闻起来让人恶心。 产生这些异味的主要原因有以下几点。 1、很多人有这种习...

 
 
zai wo men ri chang shi yong Excel de shi hou , bu jin hui yong dao dang qian Excel wen jian de shu ju , huan jing chang xu yao fang wen qi ta de shu ju wen jian 。 zhe xie shu ju wen jian ke neng shi Excel wen jian 、 wen ben wen jian huo shu ju ku wen jian deng 。 jing chang you peng you hui wen ru he zai vba dai ma li cao zuo zhe xie shu ju wen jian ? ben wen jiu xi tong di jie shao yi xia zai Excel zhong ying yong VBA cao zuo shu ju wen jian de fang fa 。 ben wen zhu yao jie shao si zhong chang yong de fang fa : 1、 li yong Excel dui xiang lai chu li wen jian ; 2、 li yong VBA wen jian chu li yu ju lai chu li wen jian ; 3、 li yong FileSystemObject dui xiang lai chu li wen jian ; 4、 li yong API han shu lai chu li wen jian 。 dang ran dui yu shu ju ku wen jian , huan ke yi li yong ADO+SQL de fang fa cao zuo , bu guo lun tan yi jing you qian bei xiang xi jie shao guo ci lei fang fa , ben wen jiu bu zai chong fu le 。 yi 、 li yong Excel dui xiang lai chu li wen jian li yong Excel dui xiang zi dai de fang fa lai cao zuo wen jian shi zui fang bian , ye shi zui jian dan de 。 wo men zhu yao li yong Workbooks ji he he Workbook dui xiang de fang fa lai cao zuo wen jian 。 1、 da kai Excel wen jian wo men ke yi yong Workbooks.Open fang fa da kai yi ge Excel gong zuo bao 。 Workbooks.Open(FileName, UpdateLinks, ReadOnly, Format, Password, WriteResPassword, IgnoreReadOnlyRecommended, Origin, Delimiter, Editable, Notify, Converter, AddToMru, Local, CorruptLoad) qi zhong FileName shi bi xuan de shen shu , biao shi yao da kai de gong zuo bao ming , ru guo mei you zhi ding lu jing , ze dai biao dang qian lu jing 。 ling wai 14 ge shi ke xuan shen shu , chu le mi ma shen shu , qi ta de yi ban hen shao yong 。 ju ti de han yi ke yi shen kan VBA de bang zhu 。 li : Workbooks.Open "F:\test.xls" ke yi da kai F pan de test.xls wen jian 。 2、 da kai wen ben wen jian shi yong Open fang fa ye ke yi da kai wen ben wen jian , dan jian yi shi yong OpenText fang fa 。 ci fang fa shi zai ru yi ge wen ben wen jian , bing jiang qi zuo wei bao han dan ge gong zuo biao de gong zuo bao jin xing fen lie chu li , ran hou zai ci gong zuo biao zhong fang ru jing guo fen lie chu li de wen ben wen jian shu ju 。 wan zheng yu fa ru xia : Workbooks.OpenText(FileName, Origin, StartRow, DataType, TextQualifier, ConsecutiveDelimiter, Tab, Semicolon, Comma, Space, Other, OtherChar, FieldInfo, TextVisualLayout, DecimalSeparator, ThousandsSeparator, TrailingMinusNumbers, Local) guan yu yi shang shen shu de ju ti han yi ke yi shen kan VBA de bang zhu , zhe li jiu bu chong fu le 。 zai shi ji de bian cheng zhong , yi ban wu xu dui zhe xie fu duo de shen shu jin xing chu li 。 ke yi tong guo lu zhi hong lai de dao da kai yi ge wen ben wen jian de VBA dai ma 。 ju ti fang fa jiu shi xuan ze “ wen jian —— da kai ”, ran hou xuan ze da kai wen ben wen jian , jiu hui chu xian wen ben dao ru xiang dao , yi bu yi bu zhi xing wan , zhi dao wen ben da kai hou , ting zhi lu zhi 。 yi xia shi lu zhi hong de dao de dai ma : Sub Macro1() ' ' Macro1 Macro ' hong you MC SYSTEM lu zhi , shi jian : 2007-3-29 ' ' Workbooks.OpenText Filename:="F:\CallWindowProc.txt", Origin:=xlWindows, _ StartRow:=1, DataType:=xlDelimited, TextQualifier:=xlDoubleQuote, _ ConsecutiveDelimiter:=False, Tab:=True, Semicolon:=False, Comma:=False _ , Space:=False, Other:=False, FieldInfo:=Array(1, 1), _ TrailingMinusNumbers:=True End Sub zai shi ji bian cheng zhong zhi yao zuo xiang ying de xiu gai jiu ke yi shi yong le 。 3、 da kai qi ta wen jian li yong Excel dui xiang huan ke yi da kai XML wen jian he yi xie shu ju ku ( ru Access) wen jian , dui ying XML wen jian , xu yao Excel2003 yi shang de ban ben 。 OpenXML fang fa de yu fa ru xia : Workbooks.OpenXML(Filename, Stylesheets, LoadOption) FileName String lei xing , bi xu 。 yao da kai de wen jian ming 。 Stylesheets Variant lei xing , ke xuan 。 dan ge zhi huo zhi de shu zu , yong yu zhi ding yao ying yong na xie XSL zhuan huan (XSLT) yang shi biao chu li zhi ling 。 LoadOption Variant lei xing , zhuan huan 。 zhi ding Excel da kai XML shu ju wen jian de fang shi 。 ke wei XlXmlLoadOption chang liang zhi yi 。 XlXmlLoadOption ke wei yi xia XlXmlLoadOption chang liang zhi yi : xlXmlLoadImportToList jiang XML shu ju wen jian de nei rong zhi yu XML lie biao zhong 。 xlXmlLoadMapXml zai “XML jie gou ” ren wu chuang ge zhong xian shi XML shu ju wen jian de jia gou 。 xlXmlLoadOpenXml da kai XML shu ju wen jian 。 wen jian de nei rong jiang zhan kai 。 xlXmlLoadPromptUser ti shi yong hu xuan ze da kai wen jian de fang shi 。 shi li xia mian de dai ma da kai le XML shu ju wen jian “customers.xml” bing zai XML lie biao zhong xian shi le ci wen jian de nei rong 。 Sub UseOpenXML() Application.Workbooks.OpenXML _ Filename:="customers.xml", _ LoadOption:=xlXmlLoadImportToList End Sub OpenDatabase fang fa yu fa ru xia : Workbooks.OpenDatabase(FileName, CommandText, CommandType, BackgroundQuery, ImportDataAs) FileName String lei xing , bi xu 。 lian jie zi fu chuan 。 CommandText Variant lei xing , ke xuan 。 cha xun de ming ling wen ben 。 CommandType Variant lei xing , ke xuan 。 cha xun de ming ling lei xing 。 yi xia shi ke yong de ming ling lei xing :Default、SQL he Table。 BackgroundQuery Variant lei xing , ke xuan 。 cha xun de bei jing 。 ImportDataAs Variant lei xing , ke xuan 。 que ding cha xun de ge shi 。 shi li ben shi li zhong ,Excel da kai le “northwind.mdb” wen jian 。 Sub OpenDatabase() Workbooks.OpenDatabase FileName:="C:\northwind.mdb" End Sub 4、 bao cun wen jian wen jian de bao cun shi yong Workbook dui xiang de Save huo SaveAs fang fa 。 Save fang fa shi yong jian dan , yu fa wei expression.Save,expression shi mou ge Workbook dui xiang 。 ru :ActiveWorkbook.Save ji bao cun dang qian huo dong gong zuo bao 。 ru guo shi di yi ci bao cun gong zuo bao huo yao ling cun wei , qing shi yong SaveAs fang fa wei gai wen jian zhi ding wen jian ming 。 qi yu fa wei : expression.SaveAs(FileName, FileFormat, Password, WriteResPassword, ReadOnlyRecommended, CreateBackup, AccessMode, ConflictResolution, AddToMru, TextCodepage, TextVisualLayout, Local) ju ti shen shu han yi ke shen kan VBA bang zhu , shi yong dou bi jiao jian dan 。 shi li ben shi li xin jian yi ge gong zuo bao , ti shi yong hu shu ru wen jian ming , ran hou bao cun gai gong zuo bao 。 Set NewBook = Workbooks.Add Do fName = Application.GetSaveAsFilename Loop Until fName <> False NewBook.SaveAs Filename:=fName Application.GetSaveAsFilename wei tiao chu biao zhun de “ ling cun wei ” dui hua kuang , huo qu yong hu wen jian ming , dan bing bu zhen zheng bao cun ren he wen jian , ran hou shi yong dai ma bao cun wen jian 。 huan you Application.GetOpenFileName ke yi tiao chu biao zhun de “ da kai ” dui hua kuang 。 5、 guan bi wen jian guan bi wen jian ke yi shi yong Workbooks ji he huo Workbook dui xiang de Close fang fa 。 qian zhe shi guan bi suo you da kai de gong zuo bao , hou zhe guan bi te ding de gong zuo bao 。 Workbook dui xiang de Close fang fa yu fa wei : expression.Close(SaveChanges, Filename, RouteWorkbook) SaveChanges shen shu biao shi shi fou bao cun geng gai , dui xu duo bu xu yao geng gai de cao zuo , ke she zhi wei False yi mian tan chu bao cun geng gai ti shi de dui hua kuang 。 FileName ke xuan 。 yi ci wen jian ming bao cun suo zuo de geng gai 。 RouteWorkbook ke xuan 。 ru guo zhi ding gong zuo bao bu xu yao chuan song gei xia yi ge shou jian ren ( mei you chuan song ming dan huo yi jing chuan song ), ze hu lue gai shen shu 。 shi li ben shi li guan bi Book1.xls, bing fang qi suo you dui ci gong zuo bao de geng gai 。 Workbooks("BOOK1.XLS").Close SaveChanges:=False ben shi li guan bi suo you da kai de gong zuo bao 。 ru guo mou ge da kai de gong zuo bao you gai bian ,Microsoft Excel jiang xian shi xun wen shi fou bao cun geng gai de dui hua kuang he xiang ying ti shi 。 Workbooks.Close 6、 zong he shi li jia ru F pan you yi ge Excel wen jian test.xls, xian zai you ling yi ge Excel wen jian yao fang wen test.xls de shu ju , wo men lai kan yong VBA dai ma ru he cao zuo 。 dai ma ru xia : Public Sub test() Application.ScreenUpdating = False Workbooks.Open "f:\test.xls" ThisWorkbook.Sheets(1).Range("b1") = ActiveWorkbook.Sheets(1).Range("a2") ActiveWorkbook.Close Application.ScreenUpdating = True End Sub shou xian guan bi ping mu shua xin , shi wei le fang zhi test.xls zai da kai shi bei kan jian ( you shi hou huan shi kan de jian )。 da kai hou , jian test.xls de Sheet1 de dan yuan ge A2 zhong de zhi fu gei dang qian gong zuo bao de Sheet1 de dan yuan ge B2, ran hou guan bi test.xls。 dang yao da kai de gong zuo bao bu que ding de shi hou , ke yi tong guo tiao yong da kai dui hua kuang lai rang yong hu zi ji xuan ze 。 ke gai wei ru xia : Public Sub test() Application.ScreenUpdating = False Dim Filename as String Filename = Application.GetOpenFileName Workbooks.Open Filename ThisWorkbook.Sheets(1).Range("b1") = ActiveWorkbook.Sheets(1).Range("a2") ActiveWorkbook.Close Application.ScreenUpdating = True End Sub 7、 zong jie li yong Excel dui xiang de fang fa jin xing wen jian cao zuo shi zui jian dan , ye shi zui fang bian de , shi he chu xue zhe 。 dui yu Excel wen jian ge shi , ru guo wo men jin jin shi du qu qi biao ge zhong de nei rong , zhe zhong fang fa ye shi shou xuan 。 dui yu wen ben wen jian de cao zuo , shi yong di er zhong fang fa bi jiao fang bian , ruo yao jiang wen ben zhuan huan cheng biao ge , na me shi yong ci fang fa ye shi he shi de 。
󰈣󰈤
  免责声明:本文仅代表作者个人观点,与王朝网络无关。王朝网络登载此文出于传递更多信息之目的,并不意味着赞同其观点或证实其描述,其原创性以及文中陈述文字和内容未经本站证实,对本文以及其中全部或者部分内容、文字的真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
 
 
华丽的模特拍摄(8)
华丽的模特拍摄(7)
华丽的模特拍摄(6)
华丽的模特拍摄(5)
八里沟
朝阳宫
天下峨眉 云上金顶
老家(四)
 
>>返回首页<<
 
 
 为你推荐
 
 
 
 转载本文
 UBB代码 HTML代码
复制到剪贴板...
 
 热帖排行
 
 
 
 
 
©2005- 王朝网络 版权所有