473,387 Members | 1,597 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Overloaded indexed properties

Hello,

I have a class with three overloaded indexed poperties.
Declaration in *.h

__gc class ByteArrayN : public FArrayN
{
typedef BYTE T;
typedef ByteArrayN FTArrayN;
Nov 17 '05 #1
4 854
Hi Michael,

Currently I am looking for somebody who could help you on it. We will reply
here with more information as soon as possible.
If you have any more concerns on it, please feel free to post here.
Thanks for your understanding!

Best regards,

Gary Chang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------

Nov 17 '05 #2
Hi Michael,
the above row At[ ind3,ind2,ind1 ] always call the function get_At[ ind 1

].
According to the rules of C++ the above code is working as expected. C++
does have built-in support multi-dimensional arrays and thus a[e1, e2, e3]
is treated as a[(e1, e2, e3)], or once you apply the comma-expression rules
a[e3];

By the way, for Whidbey the compiler will be supporting multi-dimensional
CLR arrays and so with this release a[e1, e2, e3] will work the way the
user expects it to work.
Thanks!

Best regards,

Gary Chang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------

Nov 17 '05 #3
Just to make sure we don't confuse readers:
According to the rules of C++ the above code is working as expected. C++
does have built-in support multi-dimensional arrays and thus a[e1, e2, e3]
is treated as a[(e1, e2, e3)], or once you apply the comma-expression
rules
a[e3]; Gary meant to say that C++ does __NOT__ have built in rectangular
multi-dimensional arrays.

And if anyone is less familiar with the comma operator, it evaluates all
arguments left to right and then returns the last one.

Thanks.

Ronald Laeremans
Visual C++ team

""Gary Chang"" <v-******@online.microsoft.com> wrote in message
news:BE**************@cpmsftngxa06.phx.gbl... Hi Michael,
the above row At[ ind3,ind2,ind1 ] always call the function get_At[ ind 1

].
According to the rules of C++ the above code is working as expected. C++
does have built-in support multi-dimensional arrays and thus a[e1, e2, e3]
is treated as a[(e1, e2, e3)], or once you apply the comma-expression
rules
a[e3];

By the way, for Whidbey the compiler will be supporting multi-dimensional
CLR arrays and so with this release a[e1, e2, e3] will work the way the
user expects it to work.
Thanks!

Best regards,

Gary Chang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no
rights.
--------------------

Nov 17 '05 #4
Hi, Michael:

Here is what I have found out from the book <<Essential Guide to Managed
Extenstions for C++>> by Siva Challa:

A good property behaves like a data member. But there is things that we can
do with a data member but not with a property.

"An array property declaration shall not overload an indexed property."
Otherwise, we will have ambiguity problem.

It looks from your code, you have overloaded the array property. I would
suggest you to avoid overloading here.

Thanks!

Sally Lou

This posting is provided "AS IS" with no warranties, and confers no rights.

Nov 17 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Kor | last post by:
Hi, Am I right that indexed properties are implemented in VB ..NET, but NOT in C#. It seems that for C# you have to wrap the property in a separate class, for emulating index properties. In...
3
by: cybertof | last post by:
Hello, Is it possible in C# to have 2 overloaded functions with - same names - same parameters - different return type values If no, is it possible in another language ?
3
by: Fin | last post by:
Index properties in C++ class libraries (.NET) apper as set_ and get_ methods when used in C# To test this out, I changed the example from section "13.2 Indexed Properties" in MSDN, and placed the...
6
by: Altman | last post by:
I would like to use an indexed property to access my private array of user controls. If I don't use an indexed property, the property will show up in my Properties Window during development. Is...
6
by: Ray Cassick \(Home\) | last post by:
I have a set of properties in my assembly that look like this: ''' <overloads> ''' Allows the caller to have get or set access to an item in the collection. ''' </overloads> ''' <summary> '''...
0
by: liko81 | last post by:
I have an Invoice class that must know, directly or indirectly, how to do anything associated with creating, reading, or otherwise processing an invoice to a customer. It is an uber-DAO object that...
1
by: solar | last post by:
Indexed.Yes (Duplicates OK). In my code for remote control i wanted to remove the property Indexed of a field, but i receive the date type conversion error.How can i change these properties by...
7
by: Tom Dacon | last post by:
I'm using Reflection to iterate over the properties and fields of an arbitrary object. For non-indexed properties it's pi.GetValue(theObject, Nothing) for VB, or pi.GetValue(theObject, null) for...
17
by: David C. Ullrich | last post by:
Having a hard time phrasing this in the form of a question... The other day I saw a thread where someone asked about overrideable properties and nobody offered the advice that properties are...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.