SharedProperty iteration

  • Thread starter Thread starter gluggi
  • Start date Start date
G

gluggi

Hi,

I try to read out the Groupnames and Propertyvalues of
SharedProperties. With the SharedPropertyGroup I
have a IEnumeration object that let my iterate the different
groups and receive the Groupnames like this.

SharedPropertyGroupManager oManager = new SharedPropertyGroupManager();
System.Collections.IEnumerator iGroupEnum = oManager.GetEnumerator();
while(iGroupEnum.MoveNext()==true)
{
string groupName = iGroupEnum.Current.ToString();
}

But how can I receive the sharedproperties from a group-object without
having the name of the property?
Can someone give me a hind?

Ciao

Martin
 
Hi,

I try to read out the Groupnames and Propertyvalues of
SharedProperties. With the SharedPropertyGroup I
have a IEnumeration object that let my iterate the different
groups and receive the Groupnames like this.

SharedPropertyGroupManager oManager = new
SharedPropertyGroupManager(); System.Collections.IEnumerator
iGroupEnum = oManager.GetEnumerator();
while(iGroupEnum.MoveNext()==true) {
string groupName = iGroupEnum.Current.ToString();
}

But how can I receive the sharedproperties from a group-object without
having the name of the property?
Can someone give me a hind?

I don't know why anyone would read a property without knowing the name
of the property. How can you ever know WHAT you want to read in taht
case? ;)

And what's SharedProperties?

FB

--
 
Frans said:
I don't know why anyone would read a property without knowing the name
of the property. How can you ever know WHAT you want to read in taht
case? ;)
Think about writing such kind of information down to an file and later
to read it in again ;-)
OK.
I just want to do that because I need it.
And what's SharedProperties?
An MVP should know first to have a look into the MSDN before writing
thinks like that.
It's part of the System.EnterpriseServices
There are 3 Klasses for managing shared informations.
SharedPropertyGroupManager, SharedPropertyGroup and SharedProperty

Please answer to this thread if you have qualified informations for me.
Not such thinks like Frans (sorry Frans)

Ciao and Thanks

Martin
 
Think about writing such kind of information down to an file and later
to read it in again ;-)
OK.
I just want to do that because I need it.

and I just want to help you but I need proper context information.
Your question read like "I want to read someobject.SomeProperty but I
don't know what 'Someproperty' is so how do I do that?"...
An MVP should know first to have a look into the MSDN before writing
thinks like that.
It's part of the System.EnterpriseServices
There are 3 Klasses for managing shared informations.
SharedPropertyGroupManager, SharedPropertyGroup and SharedProperty

1) first learn what 'MVP' means. It's an award for people who have
done a lot for the community, not some course graduation diploma
2) there are literaly thousands of classes in the framework. I know a
lot of them from my bare head but not all of them. So please forgive me
that I didn't know that one from my bare head. And no, I'm not going to
look up every class name mentioned here in the .net reference manual to
see if it is a framework class or not. YOU want help, provide me with
info so I can help you.

For starters: trying to be funny and not being friendly towards a
person who might be able to help you isn't helping YOU either.
Please answer to this thread if you have qualified informations for
me. Not such thinks like Frans (sorry Frans)

Huh?
You don't want me to help you apparently. Listen Martin, I do this in
my spare time and I don't spend my spare time on helping people who
think they have to be unfriendly towards me, I've better things to do
with my spare time.

FB

ps: why doesn't SharedPropertyGroup.Property(name) work for you?

--
 
Hi Frans,

first, we had a unlucky start. I excuse me for my rude answer. OK?

I know what a MVP is and I'm not an starter. I thought SharedProperty
would be a well known term because it is a dotnet-framework keyword.

What I like to do is something that I can do, for example, with a
hashtable.
Think about using the hashtable to store String-Key and String-Values.
After I have inserted some Key-Value-pairs, I want to print out a list
with this key-value-pairs. For this the hastable gets an
iterator-object. OK?

I use the SharedProperties (and the Shared-PropertyGroups) in such a
way to
share information in my project.

So I make some groups and fill this groups with key (property-name) and

value (the value of the property) pairs. After this I want to have a
functionality
to print out the inserted group(names)-property(names) and Values.
For this I need a functionality to iterate over the group-items (that I
have) and
after this to iterate over the group-properties (that I don't have).

So I can not use SharedPropertyGroup.GetPropertyName(name) because I do
not know the name of the property. I also can not store propertynames
in an other variable because there is no permanet instance that can
hold this information.
SharedPropertyGroup.GetProperty((int) position) is also not working. I
always get
an exception that the index is wrong. I think that I have to create the
property with the
positions as key (or name) to have an access over the position to the
property.
But that is something that I do not want to do.

I hope you will still answer me ;-)

Thanks and Ciao

Martin
 
Back
Top