0

How to detect variable type in Visual Assist X? When i use encapsulate field like example it doesn't work(

1 Answers1

1

The Whole Tomato website support page or forum would be a good place to get help with this :)

http://wholetomato.com/support/contact.asp

If you place the caret into the variable and press Alt-G, are you taken to the variable declaration? You should be. If you are taken to the wrong place, this is a useful clue as to the problem.

If you place the caret into the variable the Visual Assist definition field, normally at the top of the editor window on the right hand side, shows the definition, and the variable type, that Visual Assist has worked out for the variable. Does the type shown here match the type used when you trigger Encapsulate Field?

Sadly I don't have enough information in the question to work out the actual problem, but hopefully this is a starting point.

  • Problem with snippets, i need to detect variable type( When we use encapsulate field, VAX automatically determinate variable type( – user2529696 Apr 22 '14 at 19:34
  • VA is looking to add variable type to snippets, but currently this is not possible. The refactoring commands know how to work this out when required. For now have you considered having the snippet prompt for the type http://docs.wholetomato.com/default.asp?W264 – Visual Assist support Apr 22 '14 at 22:49