Quantcast
Channel: Dotnet/C# – Xinyustudio
Browsing all 204 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

Serialize & Deserialize derived class insances in generic List: Problems &...

There have been numerous discussions on serialize & deserialize derived class insances to and from generic List<T> and XML files. The problem is when you declare the collection as...

View Article


Image may be NSFW.
Clik here to view.

WinForm:Using Numerical Recipe in C#

In my previous post, I have presented how to use the code of Numerical Recipes in MFC/C++. In this post, the use of it in C# is discussed. The most straightforward way is to use some wrapper class,...

View Article


Image may be NSFW.
Clik here to view.

Using /clr and incompatibility troubleshooting in MFC applications

In some circumstances, to use C# Winform or other .Net objects in MFC applications, the “/clr” directive should be used in the MFC project settings. However, it is found not always possible to use...

View Article

Image may be NSFW.
Clik here to view.

unresolved external symbol _clReleaseContext@4

When tesging an OpenCL program in 64bit windows, Visual Studio 2010, building the program generates below error: error LNK2019: unresolved external symbol _clReleaseContext@4 referenced in function...

View Article

Image may be NSFW.
Clik here to view.

WPF: Difference of Visibility.Collapsed and Visibility.Hidden

In a recent trial to rename a TreeViewItem in WPF, I added a TextBlock as well as a Hidden TextBox in the Header, so that when in a “rename”, I will toggle of the TextBlock and TextBox’s visibility and...

View Article


Image may be NSFW.
Clik here to view.

Expression Blend 4: cannot see/switch to design view

If you are using Visual Studio 2012 to create a WPF application, and open it in Micosoft Blend 4, it is likely that you can only see the XAML file, but cannot switch to design view. To solve this, in...

View Article

Image may be NSFW.
Clik here to view.

C#: How to get installed Matlab paths and versions

In a recent project, I need get the installed Matlab’s executable path and their versions, and I know that users might not install Matlab in default “C:\Program files\MathWorks\…”. The first solution...

View Article

Image may be NSFW.
Clik here to view.

How to use WPF AvalonWizard control (I)

The AvalonWizard control is a handy WPF wizard control. To use it in your project, follow below procedures: 1. In your project, add a reference to the AvalonWizard assembly. You can right click the...

View Article


Image may be NSFW.
Clik here to view.

How to use WPF AvalonWizard control (II): Adding event handlers

In my previous post, we have discussed on how to get started with AvalonWizard. Yes, we need do sth else to make it work for our project. In this post, I will demonstrate how to add some logic to...

View Article


Multi-cursor of Sublime Text Editor, Box Selection, Multi-Line Editing with...

The sublime text editor has a feature called multi-cursor, and it is good to know VS 2010 also has a “Box selection” feature. Hope this is useful to programmers~

View Article

Image may be NSFW.
Clik here to view.

Remove unused languages/cultures from WPF/silverlight applications

If you ever used Microsoft Blend to open your WPF applications, you will find that in the output folder there are some satellite dlls in the form of fr, de, zh etc. To remove these unused languages...

View Article

Image may be NSFW.
Clik here to view.

Visual Studio 2010, 2012 Very slow and the solution

I have installed VisualStudio 2010 for quite some time but suddenly it becomes very, very slow, and opening a project with dozens of files will take over 3-4 minutes, but it used to work very fast, on...

View Article

Image may be NSFW.
Clik here to view.

WPF Tooltip control: Tips & Tricks

1. How to add multi-line tooltip?For button control, you can wrap the tooltip string in a TextBlock element, and then use either <LineBreak/> or &#x0a in the tooltip string.     If you set...

View Article


Image may be NSFW.
Clik here to view.

Create Solidworks addin in Visual Studio 2012

Up to now, Solidworks had released its 2013 sp2.0 version, and its API is updated to v21.2.0.50, but once you installed the API, you will not see the addin wizard appear in Visual Studio 2012. One...

View Article

Image may be NSFW.
Clik here to view.

Rhino C# Development (I) : Get Visual Studio Wizard ready

1. Go to http://www.rhino3d.com/new/dev to download the SDK. Unzip the file, and you will see 4 files: 2. Unzip the file “Rhino4DotNetWizards.zip”, and you will see two files Double click on the...

View Article


Image may be NSFW.
Clik here to view.

Rhino C# Development (II) : HelloRhino

If you have not got Rhino Visual Studio working, see this post to get it done. 1. In Visual Studio, create a new project, in the opened dialog, type “rhino” in the upper right filter field: 2. Click Ok...

View Article

Image may be NSFW.
Clik here to view.

Rhino C# Development (III) : Add Winform UI to Rhino

Rhino C# Development (I) : Get Visual Studio Wizard ready Rhino C# Development (II) : HelloRhino Now that we are able to talk with Rhino, let’s add our own UI to Rhino. In Rhino 5 with RhinoCommon SDK...

View Article


Image may be NSFW.
Clik here to view.

Visual Studio 2012 update: offline / standalone download

1. Go to this Link, to get the latest update. 2. Download the latest update, following the link above. Note: do not install, simply download it. 3. Once the package is downloaded, an iso file will be...

View Article

Image may be NSFW.
Clik here to view.

C#: programmatically get and set non-unicode languages for windows OS

We know that we can use English version of Windows and at the same time to display non-unicode texts such as Chinese and Japanese etc. The procedures are as follows: Control Panel > Region >...

View Article

Image may be NSFW.
Clik here to view.

C# Command Line Parser Library Example

Command Line Parser Library allows CLR applications to define a syntax for parsing command line arguments. It is very easy to incorporate this library into your C# project. To install Command Line...

View Article
Browsing all 204 articles
Browse latest View live