¡@

Home 

c# Programming Glossary: members

Can attributes be added dynamically in C#?

http://stackoverflow.com/questions/129285/can-attributes-be-added-dynamically-in-c

Attributes are static metadata. Assemblies modules types members parameters and return values aren't first class objects in C#..

Custom Compiler Warnings

http://stackoverflow.com/questions/154109/custom-compiler-warnings

standard The attribute Obsolete is used to mark types and members of types that should no longer be used. If a program uses a..

What's the best way of implementing a thread-safe Dictionary?

http://stackoverflow.com/questions/157933/whats-the-best-way-of-implementing-a-thread-safe-dictionary

value lock syncRoot d.Add key value more IDictionary members... I then lock on this SyncRoot object throughout my consumers.. ItemAdded if handler null handler this e more IDictionary members... Edit The MSDN docs point out that enumerating is inherently.. be to provide some methods for performing an action on all members and lock around the enumerating of the members. The problem..

Communicate between two windows forms in C#

http://stackoverflow.com/questions/1665533/communicate-between-two-windows-forms-in-c-sharp

form as argument and provides its reference to Form2 members. This solves the communication problem. For example I've exposed..

Method can be made static, but should it?

http://stackoverflow.com/questions/169378/method-can-be-made-static-but-should-it

methods versus Instance methods 10.2.5 Static and instance members of the C# Language Specification explains the difference. Generally.. Rule CA1822 in FxCop or Code Analysis states After marking members as static the compiler will emit non virtual call sites to these.. the compiler will emit non virtual call sites to these members which will prevent a check at runtime for each call that ensures..

Can a C# anonymous class implement an interface?

http://stackoverflow.com/questions/191013/can-a-c-sharp-anonymous-class-implement-an-interface

more public read only properties. No other kinds of class members such as methods or events are allowed. An anonymous type cannot..

When do you use the “this” keyword? [closed]

http://stackoverflow.com/questions/23250/when-do-you-use-the-this-keyword

There are several usages of this keyword in C#. To qualify members hidden by similar name To have an object pass itself as a parameter..

Is it possible to “steal” an event handler from one control and give it to another?

http://stackoverflow.com/questions/293007/is-it-possible-to-steal-an-event-handler-from-one-control-and-give-it-to-anoth

possible. Reflection is required because many of the members are private and internal. Start a new Windows Forms project..

How to provide user name and password when connecting to a network share

http://stackoverflow.com/questions/295538/how-to-provide-user-name-and-password-when-connecting-to-a-network-share

is not known on the client side. Client and server are not members of the same domain. c# .net winapi networking passwords share..

Default visibility for C# classes and members (fields, methods, etc)?

http://stackoverflow.com/questions/3763612/default-visibility-for-c-sharp-classes-and-members-fields-methods-etc

visibility for C# classes and members fields methods etc I'm trying to find a reference for the default.. modifier is specified . ... The access level for class members and struct members including nested classes and structs is private.. . ... The access level for class members and struct members including nested classes and structs is private by default ...

Convert generic List/Enumerable to DataTable?

http://stackoverflow.com/questions/564366/convert-generic-list-enumerable-to-datatable

performance. If you want to restrict it to particular members or enforce the order then you can do that too IEnumerable SomeType..

Create code first, many to many, with additional fields in association table

http://stackoverflow.com/questions/7050404/create-code-first-many-to-many-with-additional-fields-in-association-table

get set If you now want to find all comments of members with LastName Smith for example you can write a query like this.. Smith .Select mc mc.Comment .ToList Or to create a list of members with name Smith we assume there is more than one along with.. one along with their comments you can use a projection var membersWithComments context.Members .Where m m.LastName Smith .Select..

Is the C# static constructor thread safe?

http://stackoverflow.com/questions/7095/is-the-c-sharp-static-constructor-thread-safe

before any instances of a class are created or any static members are accessed. http msdn.microsoft.com en us library aa645612.aspx..

Random number generator only generating one random number

http://stackoverflow.com/questions/767999/random-number-generator-only-generating-one-random-number

if I put a breakpoint two lines below that code all members of the mac array have equal value. Why does that happen c#..

Writing C# Plugin System

http://stackoverflow.com/questions/1070787/writing-c-sharp-plugin-system

Constructor public TestPlugin #endregion #region IPlugin Members public String Name get return Test Plugin public String Version..

Parent Control Mouse Enter/Leave Events With Child Controls

http://stackoverflow.com/questions/1161280/parent-control-mouse-enter-leave-events-with-child-controls

public void Dispose StopFiltering #region IMessageFilter Members public bool PreFilterMessage ref Message m Call the appropriate..

WPF ICommand MVVM implementation

http://stackoverflow.com/questions/1468791/wpf-icommand-mvvm-implementation

_canExecute onCanExecuteMethod #region ICommand Members public event EventHandler CanExecuteChanged add CommandManager.RequerySuggested..

Using global keyboard hook (WH_KEYBOARD_LL) in WPF / C#

http://stackoverflow.com/questions/1639331/using-global-keyboard-hook-wh-keyboard-ll-in-wpf-c-sharp

break default break #endregion #region IDisposable Members summary Disposes the hook. remarks This call is required as..

How to sort databound DataGridView column?

http://stackoverflow.com/questions/1699642/how-to-sort-databound-datagridview-column

string.Format 0 1 Name Number #region IComparable MyClass Members public int CompareTo MyClass other return Name.CompareTo other.Name..

Non Public Members for C# Interfaces

http://stackoverflow.com/questions/17576/non-public-members-for-c-sharp-interfaces

Public Members for C# Interfaces In C# when you implement an interface all..

XML Serialization and Inherited Types

http://stackoverflow.com/questions/20084/xml-serialization-and-inherited-types

AbstractType data _data data #region IXmlSerializable Members public System.Xml.Schema.XmlSchema GetSchema return null this..

Get an IDataReader from a typed List

http://stackoverflow.com/questions/2258310/get-an-idatareader-from-a-typed-list

SetFields elementType Closed false #region IDataReader Members public abstract object GetValue int i public abstract bool Read..

Set global hotkeys using C#

http://stackoverflow.com/questions/2450373/set-global-hotkeys-using-c-sharp

KeyPressedEventArgs KeyPressed #region IDisposable Members public void Dispose this.DestroyHandle #endregion private.. KeyPressedEventArgs KeyPressed #region IDisposable Members public void Dispose unregister all the registered hot keys...

Can we define implicit conversions of enums in c#?

http://stackoverflow.com/questions/261663/can-we-define-implicit-conversions-of-enums-in-c

return _name #endregion #region IEquatable TDerived Members public override bool Equals object obj if obj null if obj.. return Value.GetHashCode #endregion #region IComparable Members int IComparable TDerived .CompareTo TDerived other return Value.CompareTo..

Kill child process when parent process is killed

http://stackoverflow.com/questions/3342941/kill-child-process-when-parent-process-is-killed

Error 0 Marshal.GetLastWin32Error #region IDisposable Members public void Dispose Dispose true GC.SuppressFinalize this #endregion..

c# (WinForms-App) export DataSet to Excel

http://stackoverflow.com/questions/373925/c-sharp-winforms-app-export-dataset-to-excel

value CellStyle.General #region IDisposable Members public void Dispose if _writer null return _writer.Close _writer..

Default visibility for C# classes and members (fields, methods, etc)?

http://stackoverflow.com/questions/3763612/default-visibility-for-c-sharp-classes-and-members-fields-methods-etc

for these types is internal . And for nested types Members of Default member accessibility enum public class private..

Validation: How to inject A Model State wrapper with Ninject?

http://stackoverflow.com/questions/4776396/validation-how-to-inject-a-model-state-wrapper-with-ninject

_modelState modelState #region IValidationDictionary Members public void AddError string key string errorMessage _modelState.AddModelError..

Finding common columns from two datatable and using those for Join condition in LINQ

http://stackoverflow.com/questions/5259711/finding-common-columns-from-two-datatable-and-using-those-for-join-condition-in

DataColumn #region IEqualityComparer DataColumn Members public bool Equals DataColumn x DataColumn y return x.Caption.. IEqualityComparer object #region IEqualityComparer object Members public bool Equals object x object y for var i 0 i x.Length..

C#: Accessing Inherited Private Instance Members Through Reflection

http://stackoverflow.com/questions/686482/c-accessing-inherited-private-instance-members-through-reflection

Accessing Inherited Private Instance Members Through Reflection I am an absolute novice at reflection in..

Create code first, many to many, with additional fields in association table

http://stackoverflow.com/questions/7050404/create-code-first-many-to-many-with-additional-fields-in-association-table

string Message get set public virtual ICollection Member Members get set public class MemberComment public int MemberID get set.. for example you can write a query like this var commentsOfMembers context.Members .Where m m.LastName Smith .SelectMany m m.MemberComments.Select.. can write a query like this var commentsOfMembers context.Members .Where m m.LastName Smith .SelectMany m m.MemberComments.Select..

TypeLoadException says 'no implementation', but it is implemented

http://stackoverflow.com/questions/948785/typeloadexception-says-no-implementation-but-it-is-implemented

class ImplementingClass IInterface #region IInterface Members public string GetString string key return hello world public..