ProcessCommandVersionHistory error

If you are having a problem using Vault, post a message here.

Moderator: SourceGear

Post Reply
kkchan
Posts: 54
Joined: Wed Jun 30, 2010 12:45 am

ProcessCommandVersionHistory error

Post by kkchan » Mon Jun 18, 2012 2:51 am

Hi
I tried to call ProcessCommandVersionHistory(), and hit error below. I tried to changed parameter of folderPath to "$/VaultToGemini/VaultToGemini" as well, but still hit the same exception. Any ideas?

Constant parameter:
versionHistoryBeginVersion: 1
beginDate/EndDate: VaultDate.EmptyDate()
rowLimit: 100

Code: Select all

System.Exception was caught
  Message="No object was found at the repository path: $/VaultToGemini/VaultToGemini/cvsSubmit.aspx.cs"
  Source="VaultClientIntegrationLib"
  StackTrace:
       at VaultClientIntegrationLib.RepositoryUtil.FindVaultTreeObjectAtReposOrLocalPath(String testPath)
       at VaultClientIntegrationLib.RepositoryUtil.FindVaultFolderAtReposOrLocalPath(String testPath)
       at VaultClientIntegrationLib.ServerOperations.ProcessCommandVersionHistory(String folderPath, Int64 versionHistoryBeginVersion, VaultDateTime beginDate, VaultDateTime endDate, Int32 rowLimit, String commentFilter)
       at VaultClientIntegrationLib.ServerOperations.ProcessCommandVersionHistory(String folderPath, Int64 versionHistoryBeginVersion, VaultDateTime beginDate, VaultDateTime endDate, Int32 rowLimit)
       at Gemini._Default.Page_Load(Object sender, EventArgs e) in D:\InHouse\VaultToGemini\VaultToGemini\cvsSubmit.aspx.cs:line 91
  InnerException: 

lbauer
Posts: 9736
Joined: Tue Dec 16, 2003 1:25 pm
Location: SourceGear

Re: ProcessCommandVersionHistory error

Post by lbauer » Mon Jun 18, 2012 10:03 am

Are you trying to show history on cvsSubmit.aspx or some other file?
Linda Bauer
SourceGear
Technical Support Manager

kkchan
Posts: 54
Joined: Wed Jun 30, 2010 12:45 am

Re: ProcessCommandVersionHistory error

Post by kkchan » Mon Jun 18, 2012 4:11 pm

Hi
I want to retrieve the file version history, because i want to parse the check in comment and do something else.

lbauer
Posts: 9736
Joined: Tue Dec 16, 2003 1:25 pm
Location: SourceGear

Re: ProcessCommandVersionHistory error

Post by lbauer » Tue Jun 19, 2012 1:52 pm

ProcessCommandVersionHistory() maps to "VERSIONHISTORY" in the CLC. Check the code in the CLC -- it might provide useful information.
Linda Bauer
SourceGear
Technical Support Manager

kkchan
Posts: 54
Joined: Wed Jun 30, 2010 12:45 am

Re: ProcessCommandVersionHistory error

Post by kkchan » Tue Jun 19, 2012 4:42 pm

sorry, what is CLC? where is it located?

kkchan
Posts: 54
Joined: Wed Jun 30, 2010 12:45 am

Re: ProcessCommandVersionHistory error

Post by kkchan » Tue Jun 19, 2012 8:37 pm

Hi
I tried the command line, and found that I should use ProcessCommandHistory(). I able to retrieve the historyItem, but, I feel a bit weird on the result as it is difference than command Line.

My file object contains 3 version. All with comments entered. If I pass 2 as begin/endversion, I will get HistoryItem[2], HistoryItem[0].Comment = null, HistoryItem[1] = "comment that I wrote"; If I pass 3 as begin/end version parameter, it will hit error 1209 : FailInvalidObjID. However, commandLine is working fine, it return result as expected.

Please advice. thank you

kkchan
Posts: 54
Joined: Wed Jun 30, 2010 12:45 am

Re: ProcessCommandVersionHistory error

Post by kkchan » Thu Jun 21, 2012 7:00 pm

Any news? tq

kkchan
Posts: 54
Joined: Wed Jun 30, 2010 12:45 am

Re: ProcessCommandVersionHistory error

Post by kkchan » Thu Jun 28, 2012 12:20 am

OK, found the mistake. I should pass null value for those parameters that not in use instead of empty string.

lbauer
Posts: 9736
Joined: Tue Dec 16, 2003 1:25 pm
Location: SourceGear

Re: ProcessCommandVersionHistory error

Post by lbauer » Thu Jun 28, 2012 9:46 am

Thanks for the update.

You can run the Command Line Client code through a debugger to see all the calls, if you need more information about how the Client API works.
Linda Bauer
SourceGear
Technical Support Manager

Post Reply