Why Enter key on Mac OS X renames files instead of launching?

Standard

Enter has been the command to enter rename mode for a long time. At least since System 7 in 1993.

That bothered me, too, when I switched to Mac, but after some years of use and renaming lots of files in Finder, I appreciate it over pressing F2.

You can also open any file in the Finder by pressing cmd-down (the apple key + the down arrow). It also works for folders, too. This is intuitive if you think about it this way: cmd-up navigates up one level in the hierarchy of your filesystem and cmd-down navigates deeper. If it’s a file, going deeper opens the file.

How to disable a C# .net tab inside a TabControl?

Standard

The TabPage class doesn’t have an Enable property. You can get a similar effect simply by setting the Enable property of the controls on that page. That also avoids the problem of dealing with a TabControl that has only one page. For example:

public static void EnableTab(TabPage page, bool enable) {
 foreach (Control ctl in page.ctls) ctl.Enabled = enable;
}

Or a better way, cast your TabPage to a Control, then set the Enabled property to false.

((Control)this.tabPage).Enabled = false;

Or

((Control)tbcSettings.TabPages[2]).Enabled = false;

Therefore, the tabpage’s header will still be enabled but its contents will be disabled.

How to fix your Windows 7 boot

Standard
some times by installing linux or some problems you lose your boot menu for windows. to solve this problem the only thing that you have to do is to boot your system using Windows 7 DVD, in installation menu choose repair, and in repair menu choose command prompt. Then using bootrec.exe command in windows\system32 directory and using these switches:

Microsoft InstallShield Error: “Setup failed to launch Installation engine: Calss not Registered”.

Standard
  1. Launch Windows Explorer by pressing Windows Key + E on your keyboard or select Start > Run and type explorer.
  2. Browse to C:\Program Files \Common Files\InstallShield\engine.
  3. Right-click the highlighted engine directory and select Delete.
  4. Install the latest version of the iKernel engine.
    1. Download iKernel engine update and save it to your Desktop.
    2. Double-click on ikernelupdate.exe to install.