Visual C# Samples, Specifications, Quick Reference and Visual C# General FAQ
Sticky
-
2009年4月8日 上午 02:00
I am excited to announce the availability of the following FAQ paper which lists some of the questions frequently asked by the Visual C# General forum members. This material should not be considered as a complete coverage of the frequently asked questions, but it tries to capture the high-level features with some depth in the Visual C# .NET General areas.
On behalf of the whole forum support team, I want to thank Mads Torgersen who precisely reviewed the FAQ entries with commendable thoroughness. I also want to thank the Visual C# team for their ceaseless supports and advocates of this work. And finally I want to thank all C# forum members who actively participate in this community and help others. If you have any feedback, please send mail to MSDNMG@microsoft.com.COM Interop
1. Can base/derived classes be exported to COM?
2. How do I import a Type Library as an Assembly?
P/Invoke
C# Language Features
4. What is the difference between const and static readonly?
5. What are implicit type var and Anonymous Types?
6. What are Object Initializers and Collection Initializers?
7. What are Lambda Expressions?
8. What are Extension Methods?
9. What character escape sequences are available in C#?
10. What's the difference between string and System.String?
Application Configuration File and Application Settings
11. How do I (update/insert/remove) the config file during runtime?
12. How do I modify the settings value during runtime?
Process
13. How do I set the process priority?
14. How do I capture a screenshot of a process’s main window?
15. How do I redirect standard I/O?
Low Level Hooks in C#
16. How do I set a low level mouse hook and keyboard hook in C#?
XML Serialization
17. How do I do XML serialization of classes with static properties in C#?
WebBrowser
18. How do I prevent a new page from being opened outside the WebBrowser?
19. How do I block specific URLs in the WebBrowser?
Project Resource
20. How do I read *.resx files and create *.resources files in C#?
21. How do I use .NET Reflection to inspect a generic type object?
22. How do I automate a managed application using Reflection?
Windows Management Instrumentation (WMI)
23. How do I retrieve hardware information from a remote machine via WMI?
GDI+
24. How do I rotate or flip images?
25. How do I draw an ellipse with mouse down, move, and up actions in a Windows Forms application?
Communication between different Forms and Applications & Application Automation
26. How do I input to another application?
27. How do I maximize/minimize applications programmatically in C#?
Windows Form
28.Does Application.Exit() method affect FormClosing event?
29.How to perform tasks before the form is closed and how to prevent a form from being closed when the Close button is clicked?
30.How to change the system’s cursor using Visual C#.NET?
31.How to set the cursor of a windows form using Visual C#.NET?
32.How to retrieve a Window Handle in Visual C#.NET?
Please remember to mark the replies as answers if they help and unmark them if they provide no help.
Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.- 已變更類型 Michael Sun [MSFT]Microsoft Employee, Moderator 2009年4月8日 上午 03:14 Visual C# General FAQ
- 已編輯 Michael Sun [MSFT]Microsoft Employee, Moderator 2009年4月10日 上午 06:19 Edit
- 已編輯 Michael Sun [MSFT]Microsoft Employee, Moderator 2009年4月10日 上午 06:20 Edit
- 已編輯 Jialiang Ge [MSFT]Microsoft Employee, Moderator 2009年4月16日 下午 12:03 Modify
- 已編輯 David M MortonModerator 2009年8月31日 下午 02:25 Merging two similar threads.
- 已編輯 David M MortonModerator 2009年8月31日 下午 02:29 Too many stickies
- 已編輯 Ji.ZhouModerator 2010年2月1日 下午 02:45 Add Item
- 已編輯 Ji.ZhouModerator 2010年2月1日 下午 03:00 Add New Items
- 已編輯 Ji.ZhouModerator 2010年2月1日 下午 03:02 re-align
所有回覆
-
2007年3月7日 上午 02:23
You can download LINQ samples as well as others here for Visual Studio 2008:
Visual Studio 2008 Samples- Charlie
- 已編輯 OmegaManMVP, Moderator 2009年2月2日 下午 08:58 Updated the link removed beta
- 已合併 David M MortonModerator 2009年8月31日 下午 02:28 Similar content
-
2007年9月19日 下午 08:17版主This is the document which covers all the C# language specifications for each version 1 to 3.0. Keep in mind this document targets .Net 3.5 and not .Net 3 or previous.
- 已合併 David M MortonModerator 2009年8月31日 下午 02:24 Fits with the FAQ
-
2009年4月2日 下午 02:40版主Thank you Charlie! The samples are very useful.
I'd also like to share some Visual Studio 2008 samples:
All-In-One Code Framework
It not only has examples for LINQ, but also examples for Winform, Office dev, COM, Library, IPC and RPC, other data access techs, and so on. The sample code project is live, and our passion is to cover all Microsoft dev techs. For more info, please read the introduction of the project.
Regards,
Jialiang Ge
Please remember to mark the replies as answers if they help and unmark them if they provide no help.
Welcome to the All-In-One Code Framework! If you have any feedback, please tell us. -
2010年6月20日 下午 12:12版主
The original post seems corrupted and cannot be edited. Adding three FAQ items:
10. What are the differences between dynamic and object keywords?
11. What are the differences between var and dynamic keywords?
12. How do I remove an item in from a generic list inside a foreach loop?
Please remember to mark the replies as answers if they help and unmark them if they provide no help.

