New year – new blog or how to migrate Community Server to any other engine, supports XML-RPC

יום חמישי, ינואר 1, 2009

Please update your bookmarks, because the new url of this blog is http://khason.net/ (you have not update RSS feeds, it will be done automatically). Why I did it? Why I decided to go to “stand-alone”… Well. there are some reasons. Generally, I do not want to explain all those here, but trust me, there are some. The main reason is, that there is no responsible person in charge for this blog platform in Microsoft Israel. This why, if your blog is popular and you have a respect to your blog visitors, you cannot host it here… Take a look...

Read and use FM radio (or any other USB HID device) from C#

יום שלישי, דצמבר 30, 2008

Last time we spoke about reading and decoding RDS information from FM receivers. Also we already know how to stream sound from DirectSound compatible devices. However, before we can do it, we should be able to “speak” with such devices. So, today we’ll spoke about detection and reading information from Radio USB adapters (actually from any Human Input Devices). Let’s start. First, if you want to do it, go and buy such device. The are not a...

Capturing and streaming sound by using DirectSound with C#

יום חמישי, דצמבר 25, 2008

I already wrote a little about managed way to use DirectX DirectSound. Today we’ll speak about how to get sound from your microphone or any other DirectSound capturing device (such as FM receiver) and stream it out to your PC speakers and any other DirectSound Output device. So, let’s start creating our first echo service by using managed DirectX. First of all we should decide what Wave format we want to use for capturing and recording. So,...

Quick Silverlight (and WPF) tip: How to write program without XAML

יום שלישי, דצמבר 23, 2008

From the moment, 10K MIX09 contest was launched, I got more, then 20 people, asking the same question: Is it possible to have Silverlight program up and running without XAML at all? The answer is “YES, IT IS”. Here is how: All you need for run WPF or Silverlight application is Class inherited from System.Windows.Application Class inherited from System.Windows.Controls.UserControl So, Let’s create new WPF or Silverlight...
אין תגובות

Reading and decoding RDS (Radio Data System) in C#

יום שישי, דצמבר 12, 2008

RDS or Radio Data System is very common in US and many European countries. It is communication protocol used to send small amount of digital information using regular FM radio broadcast. This protocol is used to "tell" your receiver about alternative frequencies, time, program notifications, program types, traffic information and regular text (such as singer name or genre). Unfortunately in Israel RDS is not very common and there is very limited number of radio stations broadcasts RDS information. ...
אין תגובות

Creating transparent buttons, panels and other control with Compact Framework and putting one into other

יום שישי, נובמבר 21, 2008

In WPF/Silverlight world it's very simple to make transparent controls and put anything inside anything. However, that's not the situation in WinForms, and even worth in the world of compact devices with CF. Within this worlds, there is only one way to make controls transparent - to use color masks. Today, we'll create transparent controls with Compact Framework and put it into panel, which has image background. So let's start. First of all, we need create our own control....
אין תגובות

How to P/Invoke VarArgs (variable arguments) in C#? … or hidden junk in CLR

יום רביעי, נובמבר 19, 2008

Recently I wrote a cheat sheet for pinvoking in .NET. Shortly after I got a question in comments about how to deal with variable arguments, when it's more, then one parameter. Also what to do if those arguments are heterogeneous? Let's say, that we have following method in C: int VarSum(int nargs, ...){    va_list argp;    va_start( argp, nargs );    int sum = 0;    for( int i = 0 ; i < nargs; i++ ) {        int arg = va_arg(...
אין תגובות

Set binding, based on trigger

יום שני, אוקטובר 13, 2008

Let’s say, that you want to set binding. However, you want to set it by using some trigger. Wait! Why I need it? Let’s say, that I have some very special object, that actually has no hard-coded properties. All it’s properties are created during the runtime, based on some trigger. In this case, I still want to use binding, however, if the property does not exists, I cannot do it. In this special case (that we’ll probably speak more later), we...
אין תגובות

Silverlight Bidi Controls Library RC0 and movement from Beta 2 to RC0

יום ראשון, אוקטובר 5, 2008

Finally, I got free minute to convert Silverlight BiDi controls from Silverlight beta 2 to RC0 (you can download SL rc0 tools for VS2008 here) and as usual some breaking changes (the full list is here) Calendar and DatePicker moved from System.Windows.Controls.Extended into System.Windows.Controls – Extended namespace is now deprecated. CalendarButton is not inside System.Windows.Controls.Primitives TypeConverter.CanConvertFrom(Type sourceType) was changed and now it has new first parameter ITypeDescriptorContext context ...
5 תגובות

WGS to UTM, UTM to WGS conversions, geo distance, azimuth and other geographical calculations in C#

יום שני, ספטמבר 15, 2008

"The reports of my death are greatly exaggerated" Since my post about leaving consulting field, I got huge amount of email with questions about all community projects, I'm leading, blogging in general and specific to the future of this blog. To make things clear, I leaved consulting, and now, I have less time and reasons to blog, however, I'm keep blogging and maintaining almost all of my community projects (see the left side of the main page to list...
תגובה אחת