IndexOf 方法 (String)
在給定資料表名稱時搜尋 DbSyncAdapter 物件,並傳回整個集合中第一次發生之以零起始的索引。
命名空間: Microsoft.Synchronization.Data
組件: Microsoft.Synchronization.Data (在 Microsoft.Synchronization.Data.dll 中)
語法
'宣告
Public Function IndexOf ( _
tableName As String _
) As Integer
'用途
Dim instance As DbSyncAdapterCollection
Dim tableName As String
Dim returnValue As Integer
returnValue = instance.IndexOf(tableName)
public int IndexOf(
string tableName
)
public:
int IndexOf(
String^ tableName
)
member IndexOf :
tableName:string -> int
public function IndexOf(
tableName : String
) : int
參數
- tableName
型別:System. . :: . .String
資料表的名稱。指定此名稱,以便在 DbSyncAdapterCollection 中取得相關聯 DbSyncAdapter 物件的索引。
傳回值
型別:System. . :: . .Int32
如果有找到該字串,則為 tableName 的索引位置,否則為 -1。