Share via


TranslationCollection.Add 方法

定義

多載

Add(Translation)

將指定的 Translation 新增至集合的結尾。

Add(Int32)

使用指定的語言,建立新的 Translation 物件,然後將它新增至集合結尾,並傳回新建立的 Translation。

Add(Int32, String)

使用指定的 DimensionID 建立新的 Translation 物件,然後將其新增至集合結尾,並傳回新建立的 Translation。

Add(Translation)

將指定的 Translation 新增至集合的結尾。

public int Add (Microsoft.AnalysisServices.Translation item);
override this.Add : Microsoft.AnalysisServices.Translation -> int
Public Function Add (item As Translation) As Integer

參數

item
Translation

要新增的 Translation

傳回

以零起始的索引,其為 Translation 新增至集合的位置。

例外狀況

  • 指定的項目為 Null 參考 (Visual Basic 中的 Nothing)。
  • 指定的項目已存在於集合中。
  • 指定的 語言 Translation 在集合中無效。
  • 指定的名稱 Translation 在集合中無效。
  • 指定的 Translation 相容性層級在集合中無效。

適用於

Add(Int32)

使用指定的語言,建立新的 Translation 物件,然後將它新增至集合結尾,並傳回新建立的 Translation。

public Microsoft.AnalysisServices.Translation Add (int language);
override this.Add : int -> Microsoft.AnalysisServices.Translation
Public Function Add (language As Integer) As Translation

參數

language
Int32

Translation 物件的語言。

傳回

新建立的 Translation 物件。

例外狀況

指定的語言在集合中無效。

適用於

Add(Int32, String)

使用指定的 DimensionID 建立新的 Translation 物件,然後將其新增至集合結尾,並傳回新建立的 Translation。

public Microsoft.AnalysisServices.Translation Add (int language, string caption);
override this.Add : int * string -> Microsoft.AnalysisServices.Translation
Public Function Add (language As Integer, caption As String) As Translation

參數

language
Int32

Translation 物件的語言。

caption
String

Translation 物件的標題。

傳回

新建立的 Translation 物件。

適用於