在 Excel 中学习 VBA 编程的资源(适用于完整的编程新手)
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/4859850/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Resources for learning VBA Programming in Excel (for a complete programming newbie)
提问by Rahul
A friend of mine spends long hours on Excel, and wishes to learn VBA for Excel. He has no experience coding whatsover. What are the best resources (links/books) available?
我的一个朋友在 Excel 上花费了很长时间,并希望学习 VBA for Excel。他没有任何编码经验。什么是最好的资源(链接/书籍)?
回答by David
The best resource for getting going is the Macro recorder. Run it while using Excel and it will generate code to reproduce what you've just done. Looking through and playing with the generated code is a nice way of getting a feel for VBA - both the language and the underlying structures.
开始使用的最佳资源是宏记录器。在使用 Excel 时运行它,它将生成代码来重现您刚刚完成的工作。浏览并使用生成的代码是感受 VBA 的好方法——语言和底层结构。
There's a nice introduction at http://www.mrexcel.com/articles/record-modify-run-excel-macro.phpand some instructions for Excel 2010 at http://msdn.microsoft.com/en-us/library/ee814737.aspx.
在http://www.mrexcel.com/articles/record-modify-run-excel-macro.php 上有一个很好的介绍,在http://msdn.microsoft.com/en-us/library 上有一些 Excel 2010 的说明/ee814737.aspx。
The Excel VBA Programming for Dummiesbook (http://www.amazon.co.uk/Excel-VBA-Programming-Dummies-Computers/dp/0470503696/) is one of the better Dummies books (admittedly the version I read was a few years ago now) - the author does know his stuff. He also maintains a pretty good Excel site, the VBA section is at http://spreadsheetpage.com/index.php/tip/C33.
在Excel的VBA编程傻瓜书(http://www.amazon.co.uk/Excel-VBA-Programming-Dummies-Computers/dp/0470503696/)是更好的傻瓜书(当然我读的版本是一个几年前的现在) - 作者确实知道他的东西。他还维护着一个相当不错的 Excel 站点,VBA 部分位于http://spreadsheetpage.com/index.php/tip/C33。
回答by Doc Brown
Pick your favorite:
选择你最喜欢的:
http://www.excel-vba.com/excel-vba-contents.htm
http://www.excel-vba.com/excel-vba-contents.htm
http://www.vbtutor.net/VBA/vba_tutorial.html
http://www.vbtutor.net/VBA/vba_tutorial.html
http://www.anthony-vba.kefra.com/
http://www.anthony-vba.kefra.com/
Here's a similar question asked before on SO:
这是之前在 SO 上提出的类似问题:
VBA: Basic Syntax and Examples Tutorial
And not to forget: tell him about this site, if he has specific questions, he should ask them here on SO.
不要忘记:告诉他这个网站,如果他有具体问题,他应该在这里问他们。