Selecting a file in Vault GUI program from another program

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

Moderator: SourceGear

Post Reply
Thomas Linder Puls
Posts: 153
Joined: Tue Jan 20, 2004 2:28 am
Location: PDC, Copenhagen Denmark
Contact:

Selecting a file in Vault GUI program from another program

Post by Thomas Linder Puls » Wed May 07, 2008 5:27 am

We use Vault together with our own IDE.

Operations like get-latest and check-in, which works on large structures aredone from the Vault GUI client. Such "set" operations are handled fine in this way.

But operations on individual files is more problematic:
  • You look at the file in the IDE
  • But to do a Vault operation on the file you first have to locate the file in the Vault GUI client.
We have implemented check-out directly in our IDE, because this is by far the most important operation on a single file.

We could of course implement more operations in the IDE, but it seems silly to reprogram a lot of functionality from the Vault GUI client in our IDE.

It would be much nicer if we could simply implement a locate function in our IDE. I.e. given a file in the IDE press a certain key and then the Vault GUI client switch to the corresponding file (and get focus).

With such a functionality we can easily perform operations like undo-check-out, difference, history, etc.

And we do not have to implement each of the operations.

So my question is:

It there a way to instruct an already running Vault GUI client to locate a certain file?
Thomas Linder Puls
Visual Prolog www.visual-prolog.com

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Post by jeremy_sg » Wed May 07, 2008 8:32 am

Curiosity abounds! I'd love to see a screenshot of what you're doing. I have a few questions, though.

1. Why build off the GUI client instead of the API?
2. How are you handling things like the GUI client dialogs?
3. Can you just send windows events, (much like an automated GUI testing tool would) to select the items?

-Jeremy
Subscribe to the Fortress/Vault blog

Thomas Linder Puls
Posts: 153
Joined: Tue Jan 20, 2004 2:28 am
Location: PDC, Copenhagen Denmark
Contact:

Post by Thomas Linder Puls » Wed May 07, 2008 1:35 pm

Reg 1. It is of course not the intent to build off the GUI client. But if we for example obtain the history using the API, we will have to implement a window to show it in. Such a window already exists in the GUI client. So effectively we will have to re-implement much of the functionality of the GUI client.

Reg 2. We are not handling any GUI client dialogs. The IDE does not interact with the GUI client at all. It interacts with a COM component based on the source code of the command line client.

All other operations we make directly in the GUI client.

Reg 3. Yes, it may be a possibility to send window events to the GUI client. But it would be nice if there was a more "semantically" based way to perform the selection. [/list]
Thomas Linder Puls
Visual Prolog www.visual-prolog.com

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Post by jeremy_sg » Wed May 07, 2008 2:06 pm

Thomas,

I'll Private Message you a bit of code that _may_, but probably will not help you.
Subscribe to the Fortress/Vault blog

Thomas Linder Puls
Posts: 153
Joined: Tue Jan 20, 2004 2:28 am
Location: PDC, Copenhagen Denmark
Contact:

Post by Thomas Linder Puls » Wed May 07, 2008 4:50 pm

I do not know how to use the code: it seems like code that can be used inside the GUI client itself, but not in another program.

But thanks for the help.
Thomas Linder Puls
Visual Prolog www.visual-prolog.com

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Post by jeremy_sg » Thu May 08, 2008 10:13 am

Thomas,

Sorry, but I don't think I can help you on this one. I think that you'll have to send windows events.
Subscribe to the Fortress/Vault blog

Post Reply