Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 GO Button uses wrong source directory

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
smeuser Posted - Jul 31 2007 : 07:32:33 AM
Hello,

using version 1559 with Visual Studio 2005 SP1 with C++ project on Win XP:

We have the source of our project distributed according the version:
s:\\x\\5.1
s:\\x\\5.2
The directory below the version number contains around 100 projects organized in subdirectories which are included as projects (libraries) in a solution.

Currently I'm working only in 5.2. "Find Reference" for example is only finding references in 5.2. But the "GO" Button (or ALT+G) is sometimes jumping into the 5.1 branch. Why does it do that and how can I avoid that. It is very confusing, if the name of the source file is correct but the location is wrong.

thank you very much,

Stefan Meuser
11   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Aug 02 2007 : 11:18:50 AM
While I tend to agree with you, we have some users who have very complex directory tree's full of thousands of code files, but no IDE solution holding all of these files.

Hopefully by being a little more careful which files you open in the IDE you can avoid this problem, but if you still run into it do tell us, and we will try to figure out what is causing this problem.
smeuser Posted - Aug 02 2007 : 08:49:28 AM
While I can see, that there are situations where it may be helpful, I think that in general if you use the Visual Studio and buy Visual Assist, you also have your project structure reflected in VS (BTW, the code here is also compiled and developed on Linux and other Unix - depending on the developer)).

I use external libraries (e.g. QT), added them to the directories and Visual Assist does parse these (at least the header files).

But of course, there are different ways to develop application with different needs and in general it is working fine. Opening a file from an older version should in my opinion not "corrupt" the database (I understand now it is no corruption) but I can avoid this situation, so I this was the reason it should not happen anymore.

Thanks again for all the support.

Stefan





feline Posted - Aug 02 2007 : 07:23:46 AM
Point 1, consider the situation where you are looking at a set of code, but do not have a solution for it. You open and read through a group of files, but still want VA to help you with these files...

This can happen if you are using something other than the IDE to compile the code, for example the code is being read via the IDE under windows, but you are compiling it under Linux.

Or how about opening library code that you use via a dll, so the code is not part of your project, even though you are "using" it.

Under these conditions it is reasonable for VA to remember details of the files you have opened.
smeuser Posted - Aug 02 2007 : 06:47:49 AM
At least where I noticed it, I was always in a header file.

1) This may be possible and is not unlikely. But why is the file added in this case to the database. It is not referenced by the project. Surly, it must be possible to open other files (for viewing) without adding symbols to the database ?

2) This should not be the case. All includes are added to the project. (except for system includes of course).

Thanks for your ideas.

Stefan

sean Posted - Aug 01 2007 : 1:08:51 PM
When you wrote that VA would jump from the 5.2 to the 5.1 branch, did it end up in a header file or a source file?

If it ended up in a header file, then there are two possibilities that I can think of.

1) If you had the 5.2 solution open but loaded a file from the 5.1 solution (for example, to see how something was implemented on the 5.1 branch) then that will cause some pollution (whether you loaded a source file or header file from the 5.1 solution).

2) If the solutions don't have all of their header files explicitly listed in the projects, then those header files would not be linked to any solution. Note that a solution will build completely even though the header files are not explicitly listed in the solution projects.
smeuser Posted - Aug 01 2007 : 09:16:13 AM
Okay, thanks for clarifying.

If the problem appears again, I will rebuild the database and inform you if it helps. Maybe I know then, what I have done to trigger the problem.

Stefan
feline Posted - Aug 01 2007 : 08:57:05 AM
Using two IDE's at the same time, with one solution in each directory tree open at the same time should not cause any problems. There was a known bug that was triggered by doing this, that could lead to VA's symbol database becoming corrupt, but this was fixed a few builds ago.

Certainly the test case I have for triggering this bug no longer fails in 1559.

Can you keep an eye on this problem, and if it occurs again try rebuilding VA's symbol database? If you keep on seeing this, and rebuilding the symbol database fixes the problem then something, somehow, is corrupting the database. The trick will be to find this trigger.
smeuser Posted - Aug 01 2007 : 04:53:38 AM
Thanks for the answer.
The rebuild seems to help. Now no files from 5.1 are suggested.

Yes, it is possible (and not unlikely in the future) that I have opened two versions at the same time. The solutions have identical names but resides in different directories. If this causes the problems, what would help? Is the problem that they have identical names? (Can change that). Or is the problem, that I have opened both solutions at the same time (this I cannot change)?
feline Posted - Jul 31 2007 : 12:16:48 PM
Apologies for the confusion. OFIW is Open File In Workspace, http://www.wholetomato.com/products/features/fiw.asp
You should have a toolbar button for this, or you can use the keyboard shortcut ALT+SHIFT+O to open this dialog.

I am used to just using the short hand name, and most people here recognise it, but not everyone does.

The Find References result is a little odd, since this clearly suggests that VA knows to only look in one directory tree.

Rebuilding VA's symbol database is probably a good idea, hopefully this will fix the problem. You can do this by pressing the button:

VA Options -> Performance -> Rebuild symbol databases

Of course, if VA's symbol database is corrupt this still leaves the question of how that happened.

Do you sometimes run two IDE's at the same time, with one using the 5.1 directory tree and the second using the 5.2 directory tree?
smeuser Posted - Jul 31 2007 : 09:47:54 AM
What is the OFIW dialog?
At least in the Visual Assists Option dialog (C++ Directories) and in the Visual Studio options (Source Files, Include Files) there is no entry with 5.1 or 5.2.
All include paths (except for system includes) are local to the projects and this should be always 5.2.
What is wondering me, is that the "Find Reference" function never finds anything in the 5.1 branch but the "GO" button. I would have assumed, that they are looking for the same directories.
Where does VAX store its database? May it be possible that I have mixed 5.1 and 5.2 there (without knowing it)? The Visual Studio projects (as well as most of the files) have identical names in 5.1 and 5.2.
Can I rebuild the VAX database (I know only of "Reparse current file")?
Is it possible to see the case 7457 (or any other case?).

Thanks,

Stefan
feline Posted - Jul 31 2007 : 09:11:53 AM
If you open the OFIW dialog and sort the list of files by "Path" are any files in the 5.1 directory tree listed? I am wondering how VA knows about the files in the 5.1 tree.

There is a known bug that can show up when you have duplicate files in different projects in the same solution and different directories on the hard drive. In this case VA does not always list all of the locations it should when you use alt-g, and sometimes goes directly to one of the files in a different project.

case=7457

I am wondering if you are seeing the same effect, but this would require that your solution referenced both directory tree's at the same time.

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000