Hello,
im locking for a Example how I can check in some files via API (V.3)!
thanks alot!
best regards
S. Haas
Sample for check in via API (V.3)
Moderator: SourceGear
Take a look at the example code at http://weblogs.asp.net/jeremy_sheeley
You can find which change set item you want to check in by looping over the InternalChangeSet in clientInstance. Here's some very rough code to get you started.
Code: Select all
ChangeSetItemColl csic = ClientInstance.InternalChangeSet_GetItems(true);
if ( (csic != null) && (csic.Count > 0) )
{
for (int j = 0; j < csic.Count; j++)
{
ChangeSetItem csiItem = csicOld[j];
if (csiItem.DisplayRepositoryPath.ToLower().Equals(MYPATH.ToLower()))
{
ChangeSetItemColl csicNew = new ChangeSetItemColl();
csicNew.Add(csiItem);
ClientInstance.Commit(csicNew);
}
}
}