Category: Blogroll


Breaking Singleton

Singleton can be broken by usingĀ Reflection and the below code demonstrates the same.

Singleton Class

package com.test.singleton;

public class Singleton {

	private static Singleton singleton  = null;

	private Singleton() {
		System.out.println("Running Constructor......");
	}

	public static Singleton getInstance(){
		if(singleton==null)
			singleton  = new Singleton();
		return singleton;
	}

}

View full article »

Enable / Disable Task Manager

There is a registry hack to enable or disable Task Manager.

Hive: HKEY_CURRENT_USER
Key: Software\Microsoft\Windows\CurrentVersion\Policies\System
Name: DisableTaskMgr
Type: REG_DWORD
Value: 1=Enable this key, that is DISABLE TaskManager
Value: 0=Disable this key, that is Don’t Disable, Enable TaskManager.

If you are an Administrator you can considerĀ  using Group Policy Editor. For that,

  • Click Start
  • Click Run
  • Enter gpedit.msc in the Open box and click OK
  • In the Group Policy settings window
    • Select User Configuration
    • Select Administrative Templates
    • Select System
    • Select Ctrl+Alt+Delete options
    • Select Remove Task Manager
    • Double-click the Remove Task Manager option

Since the policy is Remove Task Manager, by disabling the policy, you are enabling the Task Manager.

FYI: You can run registry editor with command regedit.

Happy New Year !!

May this New Year bring newly found prosperity, love, happiness and delight in your life !!

Enjoy !!

A Cool Trick – Change your PC Processor

This trick is really cool !

Goto START>RUN>type REGEDIT

Then goto HKEY_LOCAL_MACHINE\HARDWARE\DESCRIPTION\System\CentralProcessor

On right hand side double click on processorNameString and write what ever you want.

Now check for the modified information in Computer Properties.

How an Mechatronics – Engineer will commit suicide????

Hi Friends the picture i am posting here is from the mail which i received some time back from one of my friend. (I really Enjoyed this , Hope you also like this !).

You can see how intelligent is the Mechatronics Engineer in committing suicide(Of course i am !).

Mechatronics - Engineer commit suicide????

Cheers !!

It’s a given that anything that runs in RAM will be faster than an item that
has to access the hard drive and virtual memory. Rather than have the kernel
that is the foundation of XP using the slower Paging Executive functions,
use this hack to create and set the DisablePagingExecutive DWORD to a
value of 1.
Perform this hack only if the system has 256MB or more of
installed RAM!
Edit the Registry key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\
Control\Session Manager\Memory Management\DisablePagingExecutive to 1 to
disable paging and have the kernel run in RAM (set the value to 0 to undo
this hack). Exit the Registry and reboot.

Today out of the blue, when loading office 2003 on an xp machine, an error message appeared with the text:

“An extension failed to initialize. Can’t open file: extend.dat. The file may not exist, you may not have permission to open it, or it may be open in another program. Right-click the folder that contains the file, and then click Properties to check your permissions for the folder. You don’t have appropriate permissions to perform this operation.”

Being me an administrator it seemed more complicated than a permission problem. What is the extend.dat file? It is a file used to cache extensions built for outlook. The problem with the file could be fixed by either deleting it or renaming it.

If hidden files and folders are not visible you will have to set your explorer window to view those types of files. If you know how to show hidden files skip “Viewing Hidden Files”.

Viewing Hidden Files: To view folders and files that are hidden, from my computer, click tools and then folder options. Click the view tab at the top of the window. Scroll down to the option Hidden files and folders. Click the option that says show hidden files and folders. Then click OK.

The Fix: Make sure outlook is closed and not running. If you are viewing hidden files and folders, use windows explorer to go to documents and settings, then the folder of the user with the error. Next click Local Settings, then Application Data, then Microsoft, and finally click and go into the outlook folder. There is where you will find extend.dat. Now from here rename the file from extend.dat to extendOld. Restart outlook and send someone an email.

Tip : To do this in my style just type the below line at your command prompt but make sure you close outlook first

del “%userprofile%\local settings\application data\microsoft\outlook\extend.dat”

Secure your system :: Ctrl + c

Using “Ctrl+c” to copy sensitive data when you are connected to net is stored in clipboard and is accessible from the net by a combination of JavaScript’s and ASP.

It’s better to avoid keeping sensitive data (like credit card numbers, bank login/passwords, PIN, date of births, etc.) in the clipboard while surfing the web.

Meanwhile using some simple steps you can disable a third person accessing your sensitive data

Follow the below given steps.

1. In Internet Explorer, go to Tools -> Internet Options -> Security

2. Click on Custom Level

3. In the security settings, click to disable the “Allow Paste Operations via Script .”(In IE6 or lesser versions) or “Allow Programmatic clipboard Access”(In IE7,IE8). That will keep your clipboard contents private

Powered by WordPress | Theme: Motion by 85ideas.