Image representing the Snippets category

Fun With Linq!

Published 14 years ago

Quite often I have discussed the impossibility of joining data from a database with that of the file system. I discussed it with my team members, mentioned it in trainings and wrote about it recently in this article.

Being able to join data from a database with other data from a file system could be very useful though.

Read on ...
Image representing the Snippets category

How Do I Retrieve the Location of the Temp Folder for the Current User?

Published 17 years ago

When you're working with files, it is sometimes necessary to write to temporary files. Of course you could drop those files in the application's folder, but it's good practice to save those files in the user's Temp folder instead. This snippet will return the full path to the user's temp folder, e.g. D:\Documents and Settings\Imar\Local Settings\Temp\, so you know where to save your temporary files.
For this code to work, you'll need to import the System.IO namespace.

Read on ...
Image representing the Snippets category

Singleton Class

Published 17 years ago

This article is considered obsolete. Take a look here instead. This snippet shows you how to implement a Singleton class in C#.

Read on ...
Image representing the Snippets category

Measuring the Size of an Image with C#

Published 17 years ago

It can be useful to be able to retrieve the Height and Width of an image file you have on disk. The following snippet shows you how to do that:

Read on ...
Image representing the Snippets category

A Write-Only Property in C#

Published 17 years ago

This sample code shows how to create a simple Write-Only string property in a C# class.

Read on ...
Image representing the Snippets category

A Read-Only Property in C#

Published 17 years ago

This sample code shows how to create a simple Read-Only string property in a C# class.

Read on ...
Image representing the Snippets category

A Property in C#

Published 17 years ago

This sample code shows how to create a simple string property in a C# class.

Read on ...
  • «First
  • Previous
  • 1
  • Next
  • »Last

Mobile: False

Crawler: True

I: False