English 中文(简体)
VB诉VBA之间有何区别?
原标题:what is the difference between VB vs VBA?
  • 时间:2011-11-12 18:16:41
  •  标签:
  • vba
  • excel

我正在为2007年Excel开展这一项目。 它为此目的使用蓄电池和C#。 我没有写法,而是从其他人手中接过该项目。 因此,我仍在学习前线部分,因为我只知道C#。 我确实注意到,有一些制定工作手册/工作表格的守则。 我如何知道,它是在VB或VBA撰写的,以便我能够学习吗? 档案的延期情况如下: 我正在使用2010年视觉演播室。

Also the workbook/worksheets are password protected after creation.When I tried to change the password through VB/VBA code(whatever it is), it creates errors during build such as identifier expected, declaration expected etc.But when I undid the changes, all the errors disappeared. The only change I made was change the string that stored the password. (string "password" was changed to "password1") and suddenly other lines of code started getting errors.The errors are identifier expected, declaration expected etc. and that doesn t make sense to me. So i had to change the password through C# after it was password protected through VB/VBA. Also, how do I debug VB/VBA code. I tried putting breakpoints through VS2010 , but it s not hitting them when I run the project.I am sure the worksheets are created using VB/VBA and so its getting inside those codes, but cant debug.

我开始使用Saludio 2010,并介绍该守则如何使用C#和VB/VBA。 我用Alt+F11做任何改动。

问题回答

.cls, .frm, and .bas are VBA files. I suggest you try debugging the code in Excel using the VBE (the Visual Studio equivillent for VBA). It s quite easy to debug in that enviornment.

VB(VB.Net)和VBA之间的差别很大。 尽管如此,VBA是一种非常简单的语言,因此,如果你能够抓住C#,我相信你能够以几幅读和实验的镜子学习VBA。

如果你对实际守则有疑问,我建议你将此列为一个恰当问题。

你们如何加入法典? 如果通过Excel,例如通过Alt+F11,使用VBE,则采用VBA。 如果你开一个项目,它很可能是VB(VB6)。 注:VB。 NET利用了.vb的延伸。 此外,由于VBA是VB的一个子集,如果你从VBE项目出口VBA,则出口文件被拖欠至VB的表象。

我们确实需要知道你们如何加入该法典。

同我一样,VBA(6.x)是VB6的子集。 Excel部分只是使用VBA的物体模型。 VB. NET是不同的,并不是因为档案延期是错误的。

因此,重点学习传统做法和2007年Excel 标 书

MSDN Search for VBA at http://social.msdn.microsoft.com/Search/en-US?query=VBA&ac=8.

http://msdn.microsoft.com/en-us/library/d553655(v=office.12)。

本条 http://msdn.microsoft.com/en-us/library/bb931201(v=office.12).aspx“rel=“nofollow”http://msdn.microsoft.com/en-us/library/bb931201(v=office.12)。 应当提供帮助。





相关问题
import of excel in SQL imports NULL lines

I have a stored procedure that imports differently formatted workbooks into a database table, does work on them then drops the table. Here is the populating query. SELECT IDENTITY(INT,1,1) AS ID ...

Connecting to Oracle 10g with ODBC from Excel VBA

The following code works. the connection opens fine but recordset.recordCount always returns -1 when there is data in the table. ANd If I try to call any methods/properties on recordset it crashes ...

Excel date to Unix timestamp

Does anyone know how to convert an Excel date to a correct Unix timestamp?

C# GemBox Excel Import Error

I am trying to import an excel file into a data table using GemBox and I keep getting this error: Invalid data value when extracting to DataTable at SourceRowIndex: 1, and SourceColumnIndex: 1. As ...

Importing from excel "applications" using SSIS

I am looking for any tips or resources on importing from excel into a SQL database, but specifically when the information is NOT in column and row format. I am currently doing some pre-development ...

热门标签