简体   繁体   English

什么:= VBA中的意思

[英]What does := mean in VBA

This might be a simple question but I'm searching online for the answer and can't seem to find it. 这可能是一个简单的问题,但我在网上搜索答案,似乎无法找到答案。

With the use of the code below as an example, what do these symbols mean. 以下面的代码为例,这些符号意味着什么。 Symbol 1 :="" Symbol 2 :=_ 符号1 :=""符号2 :=_

Application.PrintOut FileName:="", Range:=wdPrintAllDocument, Item:= _

This is so called "Named argument". 这就是所谓的“命名论证”。 Meaning you can pass arguments to PrintOut in any order you like, as long as you name them on the left side of ":=" operator. 这意味着您可以按照您喜欢的任何顺序将参数传递给PrintOut,只要您在“:=”运算符的左侧命名它们即可。

Alternatively you would need to provide all the arguments in the exact order specified here https://msdn.microsoft.com/en-us/library/office/ff840681.aspx 或者,您需要按照此处指定的确切顺序提供所有参数https://msdn.microsoft.com/en-us/library/office/ff840681.aspx

More on named arguments in VBA here: https://msdn.microsoft.com/en-us/library/office/gg251503.aspx 有关VBA中命名参数的更多信息,请访问: https//msdn.microsoft.com/en-us/library/office/gg251503.aspx

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM