Hide Member from Intellisense list

W

wal

Hello,
I'm using __declspec(property) to access get/set methods as properties
(like in C# and VB.NET). Now, the problem is that both the property
name and the get/set methods show in the intellisense list. Is there
anyway to remove the names of the get/set methods from the
intellisense list?

Here's an example, I have two methods, one is a get method with the
name getText and another set method with the name setText, the name of
the property is Text. I only want Text to show in the intellisense
list, I don't want either getText or setText to show up in the list.

Thanks for any suggestions...
 
A

Alf P. Steinbach

* wal:
Hello,
I'm using __declspec(property) to access get/set methods as properties
(like in C# and VB.NET). Now, the problem is that both the property
name and the get/set methods show in the intellisense list. Is there
anyway to remove the names of the get/set methods from the
intellisense list?

"remove" elements from "list", that would be std::list::remove.

Cheers, & hth.,

- Alf

[no follow ups, please]
 
G

Guest

Hello,
I'm using __declspec(property) to access get/set methods as properties
(like in C# and VB.NET). Now, the problem is that both the property
name and the get/set methods show in the intellisense list. Is there
anyway to remove the names of the get/set methods from the
intellisense list?

Here's an example, I have two methods, one is a get method with the
name getText and another set method with the name setText, the name of
the property is Text. I only want Text to show in the intellisense
list, I don't want either getText or setText to show up in the list.

This has nothing to do with C++ or Win32 programming and is thus off-
topic in both the groups you have posted to. Ask your question in a
group discussing the VC++ IDE, such as microsoft.public.vc.ide_general.
 
W

wal

This has nothing to do with C++ or Win32 programming and is thus off-
topic in both the groups you have posted to. Ask your question in a
group discussing the VC++ IDE, such as microsoft.public.vc.ide_general.

Dear Steinbach, thanks for your reply but this is actually not what I
was asking about, my question was about Intellisense, I want some
members not to show in Intellisense.

Dear Erik, actually I was expecting there's a keyword that you prefix
to the member and it does exactly this (ie. remove a member from the
Intellisense list), this is why I posted in this news group. Besides,
my question has nothing to do with the IDE, i'm not trying to change
the options of visual studio, I want to do it from code...
 
G

Guest

Dear Steinbach, thanks for your reply but this is actually not what I
was asking about, my question was about Intellisense, I want some
members not to show in Intellisense.

Dear Erik, actually I was expecting there's a keyword that you prefix
to the member and it does exactly this (ie. remove a member from the
Intellisense list), this is why I posted in this news group. Besides,
my question has nothing to do with the IDE, i'm not trying to change
the options of visual studio, I want to do it from code...

IntelliSense is not part of either the C++ language or C++/CLR, it is
all in the IDE, and thus a newsgrups for the IDE is what you want. There
are no keywords or such that can be used to control IntelliSense since
it works by parsing the code and using the representation to give you
hints. In your case (since I believe that you are programming in C++/CLR
or managed C++) the code is first compiled to the CLR and the metadata
is then used by IntelliSense, in CLR there are no properties, they are
translated into a get and a set method along with a variable to hold the
data, which is why you see those in IntelliSence.

Using a newer version of VS and using the property keyword instead of
declspec will give you a smarter version of IntelliSense that knows that
those functions and the variable belongs to a property and will only
show you this. Note however that this is not topical in c.l.c++ since it
concerns C++/CLR and not C++.
 
W

wal

IntelliSense is not part of either the C++ language or C++/CLR, it is
all in the IDE, and thus a newsgrups for the IDE is what you want. There
are no keywords or such that can be used to control IntelliSense since
it works by parsing the code and using the representation to give you
hints. In your case (since I believe that you are programming in C++/CLR
or managed C++) the code is first compiled to the CLR and the metadata
is then used by IntelliSense, in CLR there are no properties, they are
translated into a get and a set method along with a variable to hold the
data, which is why you see those in IntelliSence.

Using a newer version of VS and using the property keyword instead of
declspec will give you a smarter version of IntelliSense that knows that
those functions and the variable belongs to a property and will only
show you this. Note however that this is not topical in c.l.c++ since it
concerns C++/CLR and not C++.

Dear Erik, actually I'm trying to use properties in native C++ not C++/
CLR but anyway as you said I'm trying my luck in a newsgroup for the
IDE, so thanks anyway .. no hard feelings my friend :)
 
G

Guest

Dear Erik, actually I'm trying to use properties in native C++ not C++/
CLR but anyway as you said I'm trying my luck in a newsgroup for the
IDE, so thanks anyway .. no hard feelings my friend :)

IF you want properties in native C++ then you are doomed to failure,
since there are not such thing as properties in C++.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,770
Messages
2,569,586
Members
45,085
Latest member
cryptooseoagencies

Latest Threads

Top