Varsha Patil

+ Follow
since Jun 16, 2006
Merit badge: grant badges
For More
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Varsha Patil


The following code is from Dan Chisholm's site

When I compiled and ran this program, the output was

nullException in thread "main" java.lang.ArrayIndexOutOfBoundsException: 2
at A14.main(

I'm not able to understand why we are getting ArrayIndexOutOfBoundsException
Can someone please explain

Yes, we have used inline styles.
As per the feedback I tried giving
<table width="100">(with out percentage) at the start of each page and closed it with </table> at the end of the page.

But still the layers/controls are being re-positioned upon resizing. Is there something that I have missed??

Thanks for the reply
Yes they have used fixed pixels. We have developed the entire application by using percentages. Is there a way to achieve the same if we use percentages.
I have a requirement to be set in the browser(IE).
When a user resizes a window, it is seen that the layers/positioned elements in the page, loose their position/show up in the wrong place. I want to prevent this. I will be glad if someone has a solution for this.

For eg in site, when a user tries to reduce the window size, the actual positioning is not lost and the elements in the page do not shrink. I want to implement the same.

Thanks in Advance
You can refer this book

SCJP Sun Certified Programmer for Java 5 Study Guide (Exam 310-055) (Certification Press) by Katherine Sierra, Bert Bates

As for links

U can always google for knowing more links

In my jsp i have two textarea fields(Mapped to two attributes present in the Form). I'm using <layout:textarea>. The user
is allowed to enter data in the two fields and save. After saving I need to display the same page with saved data in the two textarea fields.
But it is seen that after saving, the data is not getting displayed in the textarea.

I tried giving <c ut> to check whether the data was getting set in the Form's data object. I'm able to print the data with <c ut>. But I dont know why its not getting displayed in the textarea.

Can somebody resolve this

17 years ago
If I include the javascript code in the jsp file it works. But if I move the javascript code to a separate js file and include that js file in the jsp then it does not work. I wonder why?
17 years ago

For displaying alert messages in javascript function calls I need to read the text from file.
I have tried the following combinations but nothing seems to be working. The text message is not being read from the properties file. Can someone give me the correct syntax.

1. alert(<bean:message key="message.invalidName"/> ;

2. alert('<bean:message key="message.invalidName"/>');

3. alert(<bean:message key='message.invalidName'/>");

4. alert(<bean:message key=message.invalidName'/> ;
In ApplicationResources
message.invalidName=The given name is invalid

Thanks in Advance
17 years ago
Thanks for the explanation!
Hi All,

Can someone explain wat's happening here

public class Test {

System.out.println("value of x :" + Test.x);
static int x=5;
public static void main(String[] args) {
System.out.println("value of x in main is :" + new Test().x);

The output is
value of x :8
value of x in main is :8

Can somebody explain
[ August 10, 2006: Message edited by: Varsha Patil ]
In Tomcat's server.xml you can make the following entries

<Context path="/project1" reloadable="true" docBase="C:\MyDocuments\project1\jspfiles" workDir="C:\MyDocuments\project1\work"/>

The path defines the URL path that this context is for. In this example, that would be http://www.localhost:8080/project1/.

docBase specifies where the web application is to be found
17 years ago

Can anyone give me some good links/tutorials for J2SE 1.5

Thanks in advance.
17 years ago
Thanks Merrill Higginson
17 years ago