Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Technical Support
 Context field does not show C# properties
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Chris Nahr
Ketchup Master

92 Posts

Posted - Oct 19 2004 :  07:23:35 AM  Show Profile
This probably applies to earlier releases as well; I haven't checked there.

While discussing the Definition field in another thread, I thought I might try out the Context field as well.

As it turned out, VAX doesn't quite understand C# properties. The Context field never shows them, and they cannot be reached with the Alt + Arrow Up/Down shortcuts.

To reproduce, create the usual C# console project and insert the following code right after the beginning of Class1:

        public void Foo() { }

        public int SomeProperty {
            get { return 1; }
        }


You will see Foo() and Main() in the Context field but not SomeProperty, and Alt+Up/Down will jump right over the property.

This should be fixed IMO since C# classes can quite easily contain more properties than methods.

feline
Whole Tomato Software

United Kingdom
18939 Posts

Posted - Oct 19 2004 :  3:57:43 PM  Show Profile
i am not sure if this is the same bug, or two different bugs, so i have raised it as two separate cases, for ease.

the property not being listed in the alt_m list is:

case=384

alt+up arrow and alt+down arrow ignoring the property is:

case=385


out of interest, what is a property? it looks like a fancy form of a C++ getter. i presume it has some added bonus, otherwise what is the point? perhaps i can learn C# by osmosis if i ask simple questions now and then

zen is the art of being at one with the two'ness
Go to Top of Page

ubersu
Junior Member

16 Posts

Posted - Oct 19 2004 :  4:49:27 PM  Show Profile
A C# property is the rough equivalent of a setter/getter pair. It allows code like a.b = 5 and c = a.b rather than a.set_b(5) and c = a.get_b(). Syntactic sugar, to be sure, but cleaner code.

DJ
Go to Top of Page

Chris Nahr
Ketchup Master

92 Posts

Posted - Oct 20 2004 :  04:32:54 AM  Show Profile
Yes, exactly. In addition to looking nicer in code, properties also get their own XML comment tags ("value") and their own categories in information lists, like the object browser or MSDN and NDoc help files.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000