Re: [ADVANCED-DOTNET] Statics on Generic classes

2006-02-19 Thread Shawn Wildermuth
We're on the same page, at the Foo level. Thanks, Shawn Wildermuth http://adoguy.com C# MVP, MCSD.NET, Author and Speaker -Original Message- From: Discussion of advanced .NET topics. [mailto:[EMAIL PROTECTED] On Behalf Of Dean Cleaver Sent: Monday, February 20, 2006 1:45 AM To: ADVANCE

Re: [ADVANCED-DOTNET] Statics on Generic classes

2006-02-19 Thread Dean Cleaver
Shawn, When you say "keep static data about the schema at the type level" did you mean at the Foo<> level, or the Foo level? The CLR currently keeps it at the Foo which is what I want, and I think what you mean. I'm looking at cutting 1000's of lines of code from my projects, because I have lots

Re: [ADVANCED-DOTNET] Statics on Generic classes

2006-02-19 Thread Shawn Wildermuth
This question got me thinking a lot about overhead and statics. I have to say I think I like this implementation (where Foo and Foo are two different types). If I were to write a wrapper that did Foo and keep static data about the schema at the type level, it might cause a lot of static data, but

Re: [ADVANCED-DOTNET] PeekMessage

2006-02-19 Thread Mattias Sj�gren
Jon, The PeekMessaage declaration is correct, but I would remove the Alias "PeekMessageA" clause and instead add the Auto modifier keyword. All your other declarations are incorrect, they look like they are written for VB6 rather than VB.NET. I suggest you try to find correct ones at www.pinvoke

[ADVANCED-DOTNET] PeekMessage

2006-02-19 Thread Jon Rothlander
Is anyone familiar with PeekMessage? I am trying to get a sample app to run and I cannot. The sample app did not provide the code for the PeekMessage API. Below are two samples. The first is a sample that seems pretty simple, but they did not provide a declaration for PeekMessage. The 2nd sampl

Re: [ADVANCED-DOTNET] Statics on Generic classes

2006-02-19 Thread Dean Cleaver
Peter, Actually, now that you mention it I will see what I want. Basically, in almost every class I have I have 2 static datasets containing a list of all of the items in the database for that class - especially the likes of a "Country" table where countries are not added regularly if ever, I keep

Re: [ADVANCED-DOTNET] Statics on Generic classes

2006-02-19 Thread Peter Ritchie
Statics in generics don't operate any differently than non-generic classes. They're basically globals that are scoped within a class. Generics are also not like unmanaged C++ templates; their body is not copied (inlined) for each use. In your example, x is a member of GenericBase. If you change

[ADVANCED-DOTNET] Statics on Generic classes

2006-02-19 Thread Dean Cleaver
I just tried a test like this: class GenericBase { public static int x; } class GenericClass1 : GenericBase { } class GenericClass2 : GenericBase { } And then ran this: GenericClass1.x = 5; GenericClass2.x = 10; MessageBox.Show(GenericClass1.x.ToString()); To my disappointment, it display

Re: [ADVANCED-DOTNET] Source Control - What do you use, and why?

2006-02-19 Thread saad rehmani
eric, perforce supports cross-domain (their perforce to your perforce) integration. it will allow you to have the third parties work in their own p4 domain (perfoce server) in a branch split from yours. you can manage the process of integrating their branch with the main one based on whatever m