Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 VAX 1845: $FILE_BASE$ doesn't insert extension

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
Uniwares Posted - May 03 2011 : 11:51:42 PM
I have a snippet set up like this:
// $Workfile: $FILE_BASE$ $
// $Revision: $
// $AUTHOR: $
// $Date: $DATE$ $
//
// <copyright file="$FILE_BASE$" company="">


Works fine, except in one special case: When I use R#'s "move to another file to match type name", this class gets moved into a new file which is automatically added to the project. When I insert the snippet before saving the file, it will insert only the typename as filename, without the extension .cs, although the tab shows clearly the filename as "typename.cs" and the tabs tooltip shows the full path with filename and extension.

Annoying when doing some refactoring.
5   L A T E S T    R E P L I E S    (Newest First)
sean Posted - May 04 2011 : 12:24:02 PM
Ahh; no problem. Forgotten.
Uniwares Posted - May 04 2011 : 12:01:14 PM
Oh damn it, you know what... just forget what I said. Sometimes we should just run our head through the debugger before releasing. As you can see, the header is designed to be keyword expanded by VSS, and that whats happening. VSS inserts the right filename with extension. Not VA. Sorry.
sean Posted - May 04 2011 : 11:08:08 AM
Very strange. I'm not able to repro. Is the problem related to the name of the file? Can you give example names where it works consistently and examples where it doesn't work?
Uniwares Posted - May 04 2011 : 10:31:34 AM
When I use $FILE_BASE$ in a snippet any other file, it will always insert filename.ext, so maybe this is the error? :)
sean Posted - May 04 2011 : 03:07:03 AM
I don't follow the intermittent behavior part of this. I would expect it to be consistent. $FILE_BASE$ does not include the file extension. Use this instead: $FILE_BASE$.$FILE_EXT$

http://www.wholetomato.com/products/features/vasnippets.asp#reserved

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