Gmail Account

So, somehow I was one of the “dudes” to get a gmail account. Since I have been travelling a lot (on work), I don’t get the time to be online as much – if you have me on one of the IM’s, you know that – since I am online only about 50% of the day. But the point I am getting to, is that I have not had a chance to play with gmail all that much. Karan, got in and was fooling around with it and gave me his feedback. Today is the first day I think I did something meaningful with it. What better way to set it up that to forward all my spam mails from my “honeypot” account to gmail. So that is done! Now we will see how good the spam filter is. As of now about 50% if the spam is not getting caught! Also would be an interesting test on what advertisments am I shown based on all the spam I get?

Switching gears to accessibility on Gmail. Someone has done an extensive test on this using a number of browsers, if you care about this check it out.

Here is what I found for the shortcuts from GMail’s help (and I like most of these):

Shortcut Key Definition Action
c Compose Opens the Compose Mail window.
/ Search Puts your cursor in the search box.
k Move to newer conversation Opens or moves your cursor to a more recent conversation. You can hit <Enter> to expand or collapse a conversation.
j Move to older conversation Opens or moves your cursor to the next oldest conversation. You can hit <Enter> to expand or collapse a conversation.
n Next message Moves your cursor to the next message. If the message is closed, you can hit <Enter> to expand it.
p Previous message Moves your cursor to the previous message. If the message is closed, you can hit <Enter> to expand it.
o or <Enter> Open Opens your conversation. Also expands or collapses a message if you are in Conversation View.
u Return to conversation list If you’re in Conversation View, this shortcut will refresh your page and return you to your list of conversations.
y Archive Automatically archives the message or conversation.
x Highlight conversation Automatically checks and highlights a conversation so that you can archive, apply a label, or choose an action from the drop-down menu to apply to that conversation.
s Star a message or conversation Adds or removes a star to a message or conversation. Stars allow you to give a message or conversation a special status. You can use stars in any fashion you’d like — for some, stars serve as a to-do list. For others, stars might represent a reminder or a message that needs to be followed up on later.
! Report spam Marks a message as spam and removes it from your conversation list.
r Reply Reply to the message sender.
a Reply all Reply to all message recipients.
f Forward Forward a message.
<Esc> Escape from input field Removes the cursor from your current input field.

But I gotta admit the 1 GB space certainly is appealing!

Longhorn Refresh

Microsoft is planning on releasing a Longhorn Refresh to geeks like me at WinHEC next month. I am looking forward to that as there are just too many leaks right now. On an average on a machine with a 1gb of mem, I have to reboot on an average every two hours otherwise the memory workingset get way to huge with all the disk thrashing!

More on spyware

After my recent post on spyware, there is an interesting story being run by BBC where 90% of technology managers say that there is some kind of  “spyware” running on their employees PC to track their browsing habits with 29% of those being installed surreptitiously. The interesting number to me was that about 6% of users believed that the machine they use had been infected by such software. So I guess you should stop reading this now and get back to work. 🙂

Porgrammable Logic Controller

ICP DAS USA has a new PLC coming out that is running on Windows CE.NET 4.2 on a Intel Strong ARM CPU. It can run PC based control software developed with higher languages such as c#, and embeded c++. This offers the best of both the worlds – PC and PLC. If you like ladder logic you can use ISaGRAF and TraceMode. It also has a builtin VGA, Ethernet, CompactFlash, USB, Keyb and mouse ports (phew) and can use a regular monitor (or touchscreen) to view its HMI. You can check it out here.

Zachman Framework

I posted an article (click here or on the title) on what the Zachman Framework is all about. I find it so surprising that in today’s world, I came across a whole bunch of people who call themselves as “Architects” who have no idea or clue as to what the Zachman Framework is. I am not trying to be critical towards those people, they are probably very smart and know their stuff, but I figured maybe its a time for a crash course.

Spyware and IE

Today, on one of the computers at home, Meenakshi accidentally installed one of the spy-wares (via a popup – which interestingly was not blocked). This changed the search engine used by IE, installed some toolsbars and opened a whole bunch of popup windows. Also disabled some of the other legit toolbars that were running (MSN, Yahoo, Google, etc.) Anyways, it took me a good 3+ hours to track the bugger down and clean up the whole machine. What a pain and waste of time. But it got me the opportunity to document what I did and hopefully you can benefit from it.

I would like to also point out that an 1+ hours was taken by the two anti-spy-ware software that I use (Adware and Spybot – if you have not heard of them, I highly recommend download and using both of them). Though neither of them cleaned this particular one. :'(

Well how do you find out what is installed? First of all try and find the name of the “thing” running. Right-click on the toolbar and since that toolbar would be checked, you can find out the name. The first and foremost you should do is run your anti-spywares (make sure you update them). If they do find anything I would recommend rebooting your machine ASAP, after cleaning it. If the problem is solved, you got lucky (and you can stop Reading now :)). If not then goto your Add/Remove and see if you find something there that you don’t recognise if you find something uninstall and check if the problem has done. When uninstalling try and find the location of where it was installed and delete that as most uninstall programs keep something lingering (hopefully you are a geek like me and are not required to be told how to this).

If you still have the spyware, then you got more trouble (like I had). Next steps would be to poke in the (dreaded) registry and see what you can find there. To start, run Regedit (Start => Run => regedit.exe). Next goto HKLM\SOFTWARE\Microsoft\Internet Explorer\Toolbar where you would see a list of entries. Now I don’t presume you would know the GUIDs for the toolbars *grin*, so you would need to find everyone and see if they are legit or not. Here is the list of the ones I found in this computer (and what they meant):

  • {2318C2B1-4965-11d4-9B18-009027A5CD4F} – Google
  • {47833539-D0C5-4125-9FA8-0819E2EAAC93} – Acrobat (6)
  • {79FFEBC8-745B-AFDE-82E6-14ACEDC16E19} – This was the CLUPRIT!
  • {8E718888-423F-11D2-876E-00A0C9082467} – Mmedia Radioband
  • {EF99BD32-C1FB-11D2-892F-0090271D4F88} – Yahoo

Well the second one in the list above was the culprit called SLOW.Citydent, and was installed at “C:\Program Files\Settings Book”.

To find the right or wrong guid, you need to search the registry for each of the GUID and traverse it (i.e. that GUID (or CLSID) might point to another one – so keep following the rabbit trail and at the end of it you would see a COM entry (InProc32) that would point to the execuatable (dll/exe) and also a class name (e.g. SLOW.Citydent.1 in my example). Make sure you search for the GUID from the root in Regedit and delete all entries you find – as always be very careful when modifying anything related to the registry.

Also search using the ClassName in addition to the GUID, as you could potentially find entries realted to this also. Before deleteing the hives/keys make sure you find out the path in the InProc to find out where this is installed in the system. In my case this was at C:\Program Files\Settings Book (which would look like C:\progra~1\settin~1 – the 8 characters from the old DOS days). Make sure you go to this directory and inspect all files and folders – once you are found all other COM entries, you can delete all these files and folders.

Also search for the path in addition to the ClassName and GUID as that would ensure you caught all missed spywares.

You also should clear the similar entries from the following hives:

  • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Extensions
  • HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Extensions

Lastly, also check for the programs you may not recognise in HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run

Make sure you reload regedit after you delete some key as it still would show it in its cache, which is not flushed till its loaded.

So, after a long number of hours I was able to clean the machine. The moral of the story is, be careful, if you don’t trust something, don’t open it or run it, no matter how convincing it might seem no matter how trustworthy the person sending it is. As more applications move to .NET this would be eliminated because of the security features built in the framework (and CAS – code access security), but till then, we all need to use our common sense.

Resource Management in .NET

Here is a very old post I found lying around on my disk by Brian Harry, he was the Product Manager of the CLR team at Microsoft (he might still be, I just don’t know). This is a long and very interesting read on the issue of resource management and the deterministic finalization of .NET. Brian provides the backgorund so most people (who were flaming MS at that time), understand that this is really a hard problem to solve. Happy Reading….

PDC Xaml Demo

This is probably stupid (and old news now), but if you saw the xaml demo during the PDC of Avalon (presented by Don Box I think), here is the code to reproduce that sample. Please note that you would need to change the source tag in the Video class to a path that makes more sense for you.

Also, as always, please use common sense when running this. Don’t flame me if something blows up. 🙂


    Text=”Amit’s First Longhorn App” Visible=”True”
    <!–  The namespace + class name in the codebehind file and the def:Class attribute in the root of this document, must stay identical.  You can change them, but you must keep them in sync. –>
        <Canvas DockPanel.Dock=”Fill”>
    <Video Width=”100%” Height=”100%” Stretch=”Fill” Source=”c:\temp\ChrisA-DonB_300K.wmv” />
    <TransformDecorator Transform=”rotate 30 scale 3 3″ DockPanel.Dock=”Fill”>
        <TextBox ID=”foo” Width=”2in” Height=”20pt”></TextBox>
        <Button Click=”Pushed”>Click Me</Button>

window1.xaml codebehind:

//This is a list of commonly used namespaces for a window.
using System;
using MSAvalon.Windows;
using MSAvalon.Windows.Controls;
using MSAvalon.Windows.Documents;
using MSAvalon.Windows.Navigation;
using MSAvalon.Windows.Shapes;
using MSAvalon.Windows.Data;

namespace LonghornApp1


/// Interaction logic for Window1.xaml

public partial class Window1 : Window

// To use Loaded event put Loaded=”WindowLoaded” attribute in root element of .xaml file.
// private void WindowLoaded(object sender, EventArgs e) {}

void Pushed(object o, ClickEventArgs e)



Avalon Introduction (XAML)

Here are some excerpts from my slide deck on XAML. If you need to see the complete powerpoint, let me know and I can either mail it to you or upload it here.

If you don’t know, XAML is the new Extensible Application markup language that is part of Longhorn. If you have the PDC bits you should be able to run these. I am skipping on most of the details of the controls, probably will post that some other day.

What is XAML?

  • Pronounced as “Zammell”
  • “Extensible Application Markup Language”
  • Declarative Language
  • Elements represented in a .xaml file by tags
  • “XAML” is a collection of class objects that correspond to markup elements

Why use XAML?

  • Combination of both desktop and web worlds to an application.
  • Separation of UI and Implementation.


  • Application object.
  • XAML pages are characteristically dynamic incorporating both procedural code and markup elements

  • All that things you can do with markup can be done with procedural code.

  • XAML applications are managed.

  • Only “pure” XAML pages need not be compiled.

Structure of a XAML File

  • Panels
    • Handles Page Layout

    • Containers for other Elements

  • Controls

    • Handles user interaction
  • Documents
    • Handles document presentation
  • Shapes
    • Handles vector graphic shapes

What are Panels?
Panels control rendering of elements and objects
  • size
  • dimensions
  • position
  • arrangement

Kind of Panels

  • Canvas
    • Area in which child elements can be explicitly positioned
  • DockPanel
    • Area in which child elements can be arranged horizontally or vertically.
  • FlowPanel
    • Used to break, wrap, and align content > length of a line
  • GridPanel
    • Defines a grid area consisting of columns and rows
  • TextPanel
    • Formats, sizes and draws text
    • Supports multiple lines of text and formats

Kind of Controls

  • Chief components of a UI and enable user interaction
  • Control Patterns
    • Simple Controls
    • Content Controls
    • Items Controls
    • Headered Items and Headeres Content
  • Resources


IT Manager Game – Simulation of an IT department

First of all here are the sys. requirements:

  • Macromedia Flash Player 6 r79
  • IE 6 compatible browser with Javascript enabled

The IT manager – overworked and underappreciated. You know the story. Back in school, always the last to be picked for football, but the first one they ran to when they accidentally deleted a homework assignment. Not much has changed since then. But the fact is it takes a special skill set to manage an IT department. As IT manager you need to monitor industry trends and administer mission-critical resources for an entire company. At the same time, you have to manage increasingly tighter budgets – finding ways to do more with less – and possess the people skills to oversee staff and run interference with top decision makers.

The Intel® IT Manager Game tests your entire skill set – people management, resource allocation, strategic analysis and planning. It also tests your courage under fire – can you stand up to the scrutiny of top management along with that of your peers in the industry? Will the decisions you make result in breathtaking profits or devastating losses? Will you enjoy the sweet taste of victory or the bitter agony of defeat? Are you destined for management glory or will you be the kid sitting on the sidelines, waiting for the bell to ring?

Humans are "Failure Machines"

I forget where I read this recently, but it stuck to me. Humans are failure machines, we are not success machines. We fail all the time and almost all the things. And it is only through this “weeding” process we get the feedback for the failures and learn how to correct them and then do better. Well … at least the smart ones learn to how to correct them.

Running .NET on a J2EE App. Server

Yes it is true and it is very cool! Mainsoft has a product called Visual MainWin for both J2EE and Unix and Linux platforms. You can have your ASP.NET applications (using ADO.NET) deployed on a single J2EE platform. Please note, this is not really “calling” any web services that are running on Java.

How does it work? Well for one you can check out this flash movie (and it surely is amazing!). But basically they wrote an IL compiler that takes the IL generated by .NET app (i.e. ASP.NET in this case) and converts it to Java bytecode which then is run “natively” on a J2EE platform.

When you install their product, they add some extensions to VS.NET that allows you to write your ASP.NET application with VS.NET including using all the features you are used to (such as the debugger). You can also jump to the debugger from the java code/component. In the demo they have on the site, the middle-tier of a typical 3-tier web app is hosted in EJB’s and the presentation tier is ASP.NET which is then run on J2EE. The middle-tier is component (jar file) is referenced in the solution. The deployed application is a war file on the J2EE application tier.

IHMO, this has a lot of value in an Enterprise environment, and should help avoid the whole “religious” debate that some companies get hung over. Has anyone has had a chance to play with this? If so, what have your experiences been? What do you think about this, I would love to hear your thoughts.