Win a copy of Beginning Java 17 Fundamentals: Object-Oriented Programming in Java 17 this week in the Java in General forum!

Anders Boje Larsen

Greenhorn
+ Follow
since Jul 15, 2010
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Anders Boje Larsen

Lets say I have a JSP page, that show data from a database. Then i change the data and if I refresh the site or F5 the change of data will now be showed. First if i press F5 ex. 4 times. Some time the old page show up again.
10 years ago
Yes F5 in browser. It read that Tomcat look at the page and see when are show cached-file-date<file-date. If the file date i newer then it should be the new cached-file. But this i not the the situation all the time but some times.

Was wondring if there was a way to always use the file and not the cached-file in tomcat.
10 years ago
Hi Experts
I have an apache-tomcat-6.0.32 running. My problem is that when I update the JSP files or HTML files it requires quite often pushing refesh (F5) before the change can be seen.

It was not a problem for me as we where running on Tomcat 5, so assume it is an option in the new Tomcat which is causing the problem.

Thanks for all help ..
10 years ago
I solved the problem with use sqljdbc.jar instead of sqljdbc4.jdbc.
There are to different in the same version. I are not allow to update the java version we are running here.

Thanks for the help.
You may have right in that conclusion.

I tried to run some code with the connection that works and get this error that I think tell the same story as you.



I can read that JVM is a way to execution some code on my machine, is that right?
And who can i update and solved this problem?
Hi
I have in many years use a JDBC Driver 2000, but now we are moved to a MS SQL Server 2008. That's why I now are trying to make e connection with sqljdbc4.jar from MS.

Normally we use "context" to make the connection.


But now i give me a exception.


It works with a connection make like this:


I use jakarta-tomcat-5.5.9 and Eclipse, with JDBC Driver SQL 4.0.

I have placed the jar file the workspace WEB-INF/lib and on TOMCAT: C:\jakarta-tomcat-5.5.9\common\lib

Please help me to get the context to work

THANKS
Hey expert
I am trying to find a way to make a reminder/appointment from a homepage to Lotus Notes.
I am going to make an online system, that are used as a calendar but they need to get some alert. I now that Lotus Notes always are open a thought that if I could make a button that creates a reminder with an alert on the user’s computer it could be very useful.

Does any know how to do this or to get any opportunities to communicate with Lotus Notes from a JSP/JAVA homepage

THANKS
11 years ago
Hey expert
I am trying to find a way to make a reminder/appointment from a homepage to Lotus Notes.
I am going to make an online system, that are used as a calendar but they need to get some alert. I now that Lotus Notes always are open a thought that if I could make a button that creates a reminder with an alert on the user’s computer it could be very useful.

Does any know how to do this or to get any opportunities to communicate with Lotus Notes from a JSP/JAVA homepage

THANKS
I Will try to talk to it support. The same file Can be read by a javascript function that read the last date of when the filen where modify.

Why do this function work? Any guess?
11 years ago
BufferedReader bf = new BufferedReader(new FileReader("i:\test.txt"));
IO Error Occurred: java.io.FileNotFoundException: i:\test.txt (Access is denied)


I get access denied on this file, and i think it is because the server not have access to i. If I run the code on my intern computer it works fine.
I now there are access if i use javascript to give me the last modified date of the file.

Do any of you know away to to find a specific word in a file and to overcome this issue!



11 years ago
You are the man.....!
This work, now i just need to a way so the variable are been remember, in a session.
I can't find a method to do this from the adgang class.
11 years ago
JSP
OK if i remove this
<jsp:useBean id="dataBean" scope="session" class="utilities.MenuAccess"/>
From the JSP-page and write it in the java class (adgang). I don't now the code for create a session with the bean in java and not jsp, yet.

I thought that when i wrote
<jsp:useBean id="dataBean" scope="session" class="utilities.MenuAccess"/>
I make the scope for the bean in jsp and that I could yes same scope in the java-class also.
11 years ago
JSP
Okay, now i have try to look at the link you send me. But i still don't think that is the first problem.
My problem is that it return null, and that have nothing to do with the session i think. I have try to short down the code, so it is more simple to understand. REMEMBER it should be possible to get some value other then null first time you open the page.

JSP page


JAVA (test.adgang) class


Bean-class MenuAccess

11 years ago
JSP
Please help.
Where do replace the bean? AND is that the real problem? because right now i do not work first time i load the page.
when i call dataBean.getTest() i get null, but i then console i can see that the java-class are in the bean and setTest("test") and that seams to work, but why do it not remember ?
11 years ago
JSP
okay, if i change the scope to "session" it still don't remenber.

In line 16 of the (test.adgang.authorized("NAME");) i call the java-class where it set the value.
The way the bean shouldbe set happens in line 28 (PropertyUtils.setProperty(u, "test", "tst");)

I for thought the method set the property of the bean.

You probably right missing something besalt so the bean can remember somthing.
11 years ago
JSP