Thursday, January 10, 2013

The Disk is write-protected. Solution for this, Removing write protection

The solution for this is we have to make small change in the registry.

GO to Run (windows + R)

Type 'Regedit' and Press Enter

Expand "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\StorageDevicePolicies"

Click on 'StorageDevicePolicies' and change that value to '0'.

Now try copying the file. It should work now.


Wednesday, December 12, 2012

Adding favicon to the our domain

Add the image in root folder of the web server(Apache Tomcat).
Image extension '.ico'

add the following tag under title tag.
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />

Wednesday, May 9, 2012

Basic DB2 commands



  • If we close the systram icon for db2 manager, to activate again the icon the below cmd..

             C:\Documents and Settings\db2admin>db2systray

Thursday, January 5, 2012

Ajax and Struts1.3 Sample Example

Task: Populate states based on Country using AJAX.

In previous post its done using javascript. Now its based on Ajax.
In this example i used static data. we can do it using Database. Based on country it will get the corresponding states.

1). RegisterUser.jsp

<%@taglib uri="http://struts.apache.org/tags-bean" prefix="bean"%>
<%@taglib uri="http://struts.apache.org/tags-logic" prefix="logic"%>
<%@taglib uri="http://struts.apache.org/tags-html" prefix="html"%>
<html>
<head>
<script type="text/JavaScript" src="javascripts/CommonAjax.js"></script>
</head>
  <body>  <h2>Struts1.3 - Ajax Example</h2>