¡@

Home 

c# Programming Glossary: uses

Parse JSON in C#

http://stackoverflow.com/questions/1212344/parse-json-in-c-sharp

Cheese content u003cb u003eCheese u003c b u003e uses your webcam to take photos and videos applies fancy special..

Creating application shortcut in a directory

http://stackoverflow.com/questions/234231/creating-application-shortcut-in-a-directory

a great class call ShellLink.cs at vbAccelerator This code uses interop but does not rely on WSH. Using this class the code..

Why .NET String is immutable? [duplicate]

http://stackoverflow.com/questions/2365272/why-net-string-is-immutable

its lifetime which does require immutability makes uses as keys where maintaining equality to previous values is vital..

Randomize a List<T> in C#

http://stackoverflow.com/questions/273313/randomize-a-listt-in-c-sharp

products GetProducts products.Shuffle The code above uses the much criticised System.Random method to select swap candidates...

What is the difference between a field and a property in C#?

http://stackoverflow.com/questions/295104/what-is-the-difference-between-a-field-and-a-property-in-c

string _myField this is a property. When you access it uses the underlying field but only exposes the contract that will..

Case insensitive 'Contains(string)'

http://stackoverflow.com/questions/444798/case-insensitive-containsstring

is language dependent . For example the English language uses the characters I and i for the upper and lower case versions.. versions of the ninth letter whereas the Turkish language uses these characters for the eleventh and twelfth letters of its..

Best practice to save application settings in a Windows Forms Application

http://stackoverflow.com/questions/453161/best-practice-to-save-application-settings-in-a-windows-forms-application

simple I have a Windows Forms .NET 3.5 application that uses a path for reading information. This path can be modified by..

Casting vs using the 'as' keyword in the CLR

http://stackoverflow.com/questions/496096/casting-vs-using-the-as-keyword-in-the-clr

which attempts a conversion and then one statement which uses the result. The is and cast or is and as performs a test and..

When to use struct in C#?

http://stackoverflow.com/questions/521298/when-to-use-struct-in-c

order to satisfy implementation of IEnumerable Dictionary uses the Enumerator struct which it copies every time an enumerator..

Convert generic List/Enumerable to DataTable?

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

var reader ObjectReader.Create data table.Load reader This uses the FastMember's meta programming API for maximum performance...

How do I convert Word files to PDF programmatically?

http://stackoverflow.com/questions/607669/how-do-i-convert-word-files-to-pdf-programmatically

Here is a modification of a program that worked for me. It uses Word 2007 with the Save As PDF add in installed. It searches..

Accessing a Shared File (UNC) From a Remote, Non-Trusted Domain With Credentials

http://stackoverflow.com/questions/659013/accessing-a-shared-file-unc-from-a-remote-non-trusted-domain-with-credentials

files Folder file.txt Here is some sample C# code that uses WNetUseConnection . Note for the NetResource you should pass..

Sending email through Gmail SMTP server with C#

http://stackoverflow.com/questions/704636/sending-email-through-gmail-smtp-server-with-c-sharp

has happened before . When I try the piece of code that uses SmtpDeliveryMethod.Network I quickly receive a SmtpException..

Is it possible to dynamically compile and execute C# code fragments?

http://stackoverflow.com/questions/826398/is-it-possible-to-dynamically-compile-and-execute-c-sharp-code-fragments

Here's a nice short example take from LukeH's blog which uses some LINQ too just for fun. using System using System.Collections.Generic..

C# Finalize/Dispose pattern

http://stackoverflow.com/questions/898828/c-sharp-finalize-dispose-pattern

interface. Does this mean that the webclient indirectly uses unmanaged resources Is there any hard and fast rule to follow.. fast rule to follow about this. How do I know that a class uses unmanaged resources c# .net idisposable finalizer share improve.. pattern is here . When programming a class that uses IDisposable generally you should use two patterns When implementing..

How can I detect the encoding/codepage of a text file

http://stackoverflow.com/questions/90838/how-can-i-detect-the-encoding-codepage-of-a-text-file

Must Know About Unicode and Character Sets No Excuses . Specifically Joel says The Single Most Important Fact About.. sense to have a string without knowing what encoding it uses. You can no longer stick your head in the sand and pretend that..

ExecuteReader requires an open and available Connection. The connection's current state is Connecting

http://stackoverflow.com/questions/9705637/executereader-requires-an-open-and-available-connection-the-connections-curren

To minimize the cost of opening connections ADO.NET uses an optimization technique called connection pooling. Connection.. nature. So theres a great chance for these locks which causes performance issues at best. Actually sooner or later you'll..

Broadcasting UDP message to all the available network cards

http://stackoverflow.com/questions/1096142/broadcasting-udp-message-to-all-the-available-network-cards

to the UdpClient base class. Socket s this.Client Uses the Socket returned by Client to set an option that is not available.. to the UdpClient base class. Socket s this.Client Uses the Socket returned by Client to set an option that is not available..

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

summary Listens keyboard globally. remarks Uses WH_KEYBOARD_LL. remarks summary public class KeyboardListener..

Does using “new” on a strict allocate it on the heap or stack?

http://stackoverflow.com/questions/203695/does-using-new-on-a-strict-allocate-it-on-the-heap-or-stack

to a field or use as a method argument. call instance Uses an already allocated storage location whether on the stack or.. it doesn't allocate more stack space each time. initobj Uses an already allocated storage location and just wipes the data...

Uses for static generic classes?

http://stackoverflow.com/questions/2685046/uses-for-static-generic-classes

for static generic classes What are the key uses of a Static..

Uses of Action delegate in C#

http://stackoverflow.com/questions/371054/uses-of-action-delegate-in-c-sharp

of Action delegate in C# I was working with the Action Delegates..

Spawn a new thread to open a new window and close it from a different thread

http://stackoverflow.com/questions/4698080/spawn-a-new-thread-to-open-a-new-window-and-close-it-from-a-different-thread

is a tree of how the spawning currently works Main thread Uses a function in the main thread to start another function in a..

Uses for MachineKey in ASP.NET

http://stackoverflow.com/questions/550210/uses-for-machinekey-in-asp-net

for MachineKey in ASP.NET What different ways are Machine Keys..

When should i use [Serializable] in C#? [closed]

http://stackoverflow.com/questions/5877808/when-should-i-use-serializable-in-c

different format. This conversion is called SERIALIZATION. Uses for Serialization Serialization allows the developer to save..

Is there a much better way to create deep and shallow clones in C#?

http://stackoverflow.com/questions/8025890/is-there-a-much-better-way-to-create-deep-and-shallow-clones-in-c

Returns a deep copy of a given object returns remarks Uses BInarySerialization to create a true deep copy remarks public..

When should I use double instead of decimal?

http://stackoverflow.com/questions/803225/when-should-i-use-double-instead-of-decimal

advantages to using double or float instead of decimal Uses less memory. Faster because floating point math operations are..

WPF equivalent to TextRenderer

http://stackoverflow.com/questions/824281/wpf-equivalent-to-textrenderer

Get the required height and width of the specified text. Uses FortammedText summary public static Size MeasureTextSize string.. Get the required height and width of the specified text. Uses Glyph's summary public static Size MeasureText string text FontFamily..

MVC Custom Authentication, Authorization, and Roles Implementation

http://stackoverflow.com/questions/8567358/mvc-custom-authentication-authorization-and-roles-implementation

_authorizedRoles authorizedRoles summary Uses injected authorization service to determine if the session user..

Troubleshooting BadImageFormatException

http://stackoverflow.com/questions/8996653/troubleshooting-badimageformatexception

verbose option to ensure the assembly binaries were valid. Uses fuslogvw to look for any loading issues. Used CheckAsm to look..

Launching a Desktop Application with a Metro-style app

http://stackoverflow.com/questions/9527644/launching-a-desktop-application-with-a-metro-style-app

false p.StartInfo.FileName C Path To App.exe p.Start Exp 2 Uses the ProcessStartInfo class to start new processes both in a..

Difference between == operator and Equals() method in C#?

http://stackoverflow.com/questions/9529422/difference-between-operator-and-equals-method-in-c

'x' 1 string b new string 'x' 1 Console.WriteLine a b Uses string's implementation prints True object c a object d b Console.WriteLine..

Do “type-safe” and “strongly typed” mean the same thing?

http://stackoverflow.com/questions/969088/do-type-safe-and-strongly-typed-mean-the-same-thing

4.0 you can do dynamic foo hello dynamic length foo.Length Uses String.Length at execution time foo new int 10 20 30 length.. at execution time foo new int 10 20 30 length foo.Length Uses Array.Length at execution time dynamic bar FileStream foo Fails..