Thursday, January 04, 2007
Textron commerative coins
In April of 2006, the company that I work for, Visual Learning Systems, got acquired by Overwatch Systems. Then in November of 2006, we got bought out by Textron Systems, a division of Textron, which is a Fortune 500 company.
This coin was given to us as a commeration of this event (which I think is a testament to the great work done by us at this company).
Labels:
Visual Learning Systems
Friday, December 29, 2006
Windows XP dialog default font changed automatically!
Recently, we had a customer running chinese on his machine have a problem with the way in which fonts were being choosen for the dialog.
On all our machines the dialog would default to MS Sans Serif. But on this one machine it would switch to a serif based font.
We tried changing fonts via the Appearance dialog under Display Properties, but that would not do it. We even tried changing the DPI to recreate the issue, tried installing foreign language packs, but we just could not recreate the proble.
Then we found the following registry item : "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontSubstitutes"
Under that key are two entries MS Shell Dlg and MS Shell Dlg 2. These are set to Microsoft Sans Serif and Tahoma respectively on my machine. If you change these, then, VOILA!, the font used in the dialog started to change.
More info about this key is available at http://support.microsoft.com/kb/282187
Once we had a way to recreate the problem, we were able to provide a fix to the customer, as well as fix the code so that it would better scaled dialogs to handle different fonts.
Lesson here: never resize dialogs by hard-coded values. Either use the automatic scaling functionality provided by .NET 2.0, or resize to a location that is offset from a control on the dialog. That way, when fonts change and the position of the controls change, your dialog will resize to the new location without a problem.
This probably is my last post for 2006 - So HAPPY NEW YEAR!
Are ATMs safe
According to an article from MSNBC, ATMs could be hacked to divulge your account number and pin to a hacker. (Its not the ATM itself, but the method in which the information is sent to the bank, that makes the process insecure).
Here is an illustration of the points of vulnerability.
And read it in full at http://redtape.msnbc.com/2006/11/researchers_who.html#posts
Introduction to the Make Controller Kit in C#
From Coding for Fun:
Introduction to the Make Controller Kit in C#
The Make Controller Kit was developed by MakingThings in collaboration with Make Magazine to provide an open hardware platform that encourages experimentation, learning, and - most importantly - the creation of fun, interesting, and practical projects.
This article talks about using C# to control this controller.
Labels:
.NET
A GPS device that plugs into the SD memory slot!
Labels:
Gadgets
Monday, November 27, 2006
Trouble with the Large Object Heap
I have always had trouble understanding why at times .NET will allow you to allocate a block of memory and then a couple of minutes later it will refuse to do so, even though there is enough free memory available.
In my case I know its because of .NET not compacting the large object heap.
And this article explains it very well with a code example and also typical work arounds - good read!
http://www.codeproject.com/useritems/Large_Objects____Trouble.asp
Labels:
.NET
Wednesday, November 22, 2006
Creating an object just from its name in .NET
Recently one of my co-workers was looking for a method of creating an instance of an object just from its name.
The Activator class has methods to do just that, but those methods need a full name.
So to create an object just from its name (excluding version number, public key and assembly name), I came up with the following steps.
Type type = Type.GetType("name of object"); //where name of object is System.String or namespace.object
Object theObj = Activator.CreateInstance(type);
Thats it!
Labels:
.NET
Tuesday, November 21, 2006
Disabling the CTRL + TAB functionality in Visual Studio 2005
Hated the new way in which Ctrl + Tab worked within the new Visual Studio 2005 IDE. From day 1, I have been trying to disable it and make it work in the old way.
Finally I found the answer.
The simple answer : one can use CTRL + F6, to tab through the windows as one would do in previous versions of VS.
But I prefer reassigning the shortcuts, so that I can use the good old CTRL+TAB (CTRL+F6, somehow doesnt cut it for me and is harder for single hand access!)
So here is how you do that:
Goto Tools->Customize.
Click on Keyboard...
This will bring up the Options dialog with the tree item Keyboard under Environment open.
Type in the "Show commands containing" text box the following "Window.NextD".
This should bring up two commands Window.NextDocumentWindow and Window.NextDocumentWindowNav.
If you look, CTRL+Tab has been assigned to Window.NextDocumentWindowNav and CTRL+F6 to Window.NextDocumentWindow.
Just reassign the shortcuts and you are in business.
Labels:
.NET
What is ReadyBoost?
A new feature in the Windows Vista operating system is where it can automatically take advantage of a USB flash drive to improve system performance.
Read more about this cool new feature at : http://windowsvistablog.com/blogs/windowsvista/archive/2006/11/20/windows-readyboost.aspx
Here is the main excerpt from that page :
"Windows ReadyBoost isn’t really using that memory to increase the main system RAM in your computer. Instead, ReadyBoost uses the flash drive to store information that is being used by the memory manager. If you are running a lot of applications on a system that has limited memory, Windows ReadyBoost will use the flash drive to create a copy of virtual memory that is not quite as fast as RAM, but a whole lot faster than going to the hard disk. What is very cool here is that there is nothing stored on this flash disk that isn’t also on the hard disk, so if you remove the flash drive, the memory manager sees the change and automatically goes to the hard disk. While the performance gain from ReadyBoost is gone, you don’t lose any data and there is no interruption. And because the Windows Readyboost cache on the flash drive is encrypted using AES-128, you don’t need to worry about exposing sensitive data if the flash drive is stolen or lost. Also, the memory manager compresses the pages before writing them into the cache on the flash disk, which means you’ll get more mileage from each MB.
"So, if you just want your PC to run faster with Windows Vista -- it's pretty simple -- connect your flash drive through any USB 2.0 socket or PCI interface and when the autoplay interface comes up, choose 'Speed up my system using ReadyBoost.' "
Generalization of a Simple Genetic Algorithm (GA)
Taking a simple genetic algorithm and constructing a framework to allow easy creation of similar algorithms.
http://www.codeproject.com/useritems/GA_Generalization.asp
Subscribe to:
Posts (Atom)
