Java Won't Work With Chrome
Apr 8, 2014
I use Chrome rather than IE. Recently I got an error message when I tried to deposit a check online.
It said that I needed up get a newer version of Java than 6.10, so I downloaded 7u51.
When I tried to deposit the check again, Chrome asked if I wanted to run the app, and I said yes, but that took me back to the download link again.
I spent almost an hour with my bank experts, but they were unable to solve the problem.
When we tried it on Internet Explorer, it worked fine.
Later, I discovered that on the Java Control Panel under the Default Browser for Java, it has only IE and Mozilla, with the IE being checked and greyed out.
I'm assuming that's why the problems on Chrome, even though up until a few days ago, I was able to deposit checks using Chrome-Java.
View Replies
ADVERTISEMENT
Jul 17, 2014
I have a jsf form which has a drop down. When I select any value in drop down it shows related details. When I use chrome browser, and I press back space key it comes back to the page, it keeps the value selected which was selected earlier, but in the firefox, IE it keeps the zero index selected. The same code is not working for chrome browser.
I would like the zero index to be selected in the drop down in previous page in chrome browser also when back space key is pressed...
View Replies
View Related
Feb 25, 2014
My current URL is URL....The context rootpath is URL....In my current URL page, I upload a CSV file. This page has two buttons-- ok and Cancel and these buttons are what I'm having trouble with ( I will come to that part in a short while). The relevant JSP part is as follows.
<html:form action="importEmployee?method=save" method="POST" styleId="importEmployee" enctype="multipart/form-data">
....... some headers and title bar and stuff... and then as follows.
<div class="contentSection">
<table border="0" class="formTable">
<html:hidden property = "selectedSet" />
<tr>
[code]...
So, if I click on cancel in the second URLpage (URL...), I go back to the first URLpage, i.e to URL...But this part behaves differently in Firefox and in Chrome browsers.In Chrome, if I click on cancel in the second page, I can still see the uploaded file name( the hidden property in the first JSP is the file name ) in the first page. And if I click on ok, I can do the processing again as was done by clicking ok the first time on the first page.However when I run my application in a Firefox browser, if I click on cancel in the second page, the uploaded file name says 'no file selected' in the first page. Hence to import Employees again, I need to upload a new/same CSV file again.
I don't want the file to be present in the first page when I click on cancel in the second page even when I run my application in Chrome. Yes, I require the file name to be a hidden property. This is because depending on the data in the file, different kind of processings are done and some of them require to take additional inputs from user on another page and a third page does the processing. So the file name should be passed on to the form but I don't want the user to upload the file again.
However in the event the user clicks on cancel, I don't want the file name to be retained in the first page. But this isn't happening.So I have two questions. Why is the behaviour different in Chrome and in Firefox and is there a way I can correct the way it behaves in chrome?
View Replies
View Related
Mar 26, 2014
i am calling a method of my applet from within the javascript. My code works fine with all browsers except CHROME.i get this exception in browser = "Uncaught TypeError: Object #<HTMLObjectElement> has no method 'loadComplete' mainControl.js:6". i called this method on the "onload" of <body> tag.
View Replies
View Related
Mar 12, 2015
I have written sample web application with servlets and jsp. As per the below code the action url should be executed automatically according to the "onload". I have written this below code in one of my servlet, The below "onload" form hits the path in action only in Firefox and IE but not in Chrome(41.0.2272.74 beta-m (64-bit)).I have seen the link [Chrome - <body onload=“”> is not working ][1] , I have my below code in the end of servelt. there is nothing to execute after this code in the servlet.
out.write("<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
");
out.write("<html><body onload="alert('alert has been fired');document.forms[0].submit()">
");
out.write("<form method="POST" action="" + actionUrl + "">
[Code] ....
Is there any reserved key words of chrome in the above action url? If I execute this code in the html format, it is working in chrome. but if it is from servlet, alert() is not running.
View Replies
View Related
Dec 6, 2014
I am trying to make a java Simon game but I cannot figure out how to make the GUI work. I have this so far, but now it just keeps saying I lose and it isn't functioning. It seems the only way I can make it work is having the action listeners in the do loop, but then once a button is clicked, the code errors out.
import java.awt.Color;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.util.ArrayList;
import java.util.Random;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JOptionPane;
[code]....
View Replies
View Related
May 12, 2015
I have a couple .java examples I want to mess with but don't know how to get them into Netbeans so I can work with them. What is the process in loading a .java into Netbeans so I can work with the code and run it in Netbeans?
View Replies
View Related
Jun 10, 2015
I have java http client which sends periodically (every 30 sec; this code is run by heartbeat thread in the cycle) heartbeats:
private PostResponse post(String jSessionCookie, final String action, final String data, final int postTimeoutMs) throws IOException, SSYSException
{
final HttpURLConnection httpConn = openHttpUrlConnection(true, postTimeoutMs, jSessionCookie);
final OutputStream os = httpConn.getOutputStream();
try (final PrintWriter wr = new PrintWriter( DefaultProperty.isEnableSocketTraceGW ? new TracerOutputStream(os) : os ))
[Code] .....
On the server side there is Tomcat 8.0.21 + APR connector. Every time this heartbeat is sent I see in the Wireshark and EtherDetect that new TCP connection is opened (SYN-SYNACK packets) and after getting response from Tomcat connection is closed (FIN – FINACK packets). I was expecting that TCP connections will be reused but not closed.
Capture.png 182.0 K
View Replies
View Related
Mar 28, 2014
I faced with a problem, when I use method reference as a function in Collectors.groupingBy I get an error: "no suitable method found for collect". But! if I replaced method reference with a lambda expression everything works fine.
Here is the code sample:
interface Iface{
public int getPropertyOfClassA();
public void setPropertyOfClassA(int propertyOfClassA);
}
class A implements Iface{
private int propertyOfClassA;
[Code] ....
Change "C::getPropertyOfClassA" with "objC -> objC.getPropertyOfClassA()" and it works!
View Replies
View Related
Aug 7, 2014
i am fairly new to java but have made a few projects so i do know most aspects that would allow me to complete the task its just i have been stuck at the same place now for 2 days.The project is to create a java program that can read specific data within a csv file to work out the averages etc. The csv file is a database of different weather stats . an example of the first 12 months of the csv file is below..
[CSV FILE]
year ,month,average rainfall etc
1946 15.70.616108.131.5
1946 28.23.56111.871
1946 38.82932.9 102.9
1946 414.16.3029.2 150.5
1946 513.96060.7 143.6
[code]...
I know that once the data is indexed i can than use a double to find the average of the 12 specific pieces of data and so on. once this is complete i should than be able to transfer the data to a simple graph.
View Replies
View Related
Jun 18, 2014
The problem is as follows: I've been running java script using git bash and at one point it tells me that I need to increase heap size because apparently it takes more than 1gb to run. However although I manually increase it via control panel>programs>java nothing changes. I've been told that I need to ' figure out how to use 64bit java (and a VM that supports 64bit) in order to increase the maximum memory allocation (heap size) to something north of 2g.'
My laptop has 8GB worth of RAM (Windows 7)so it shouldn't technically have problems running anything above 1G. But there is apparently a 1GB wall But increasing the heap size to above 2G results in an error stating that VM doesn't initialize within git bash, I thought that my java is 32 bit so I downloaded a 64 bit java. Now how and if it is even possible to allocate a program to run under 64 bit java and if I should delete the other java version.
View Replies
View Related
Dec 13, 2014
how does recursion works, I don't understand why it prints al numbers going up again?This is the code
void print2(int n){
if (n<0){
out.printf(" %d",-1);
return;
}
out.printf(" %d", n);
print2(n-1)
out.printf(" %d", n);
}
this should be the output if n is 6: 6 5 4 3 2 1 0 -1 0 1 2 3 4 5 6.
View Replies
View Related
Mar 6, 2015
I need to create a chart for work and comes across this sample from mbostock's chord diagram (bl.ocks.org/mbostock/4062006).
I only need to revise the tick label (names, display positions) but I don't know how to do it as I have 0 experience with Java.
My sample data for the var matrix is
[0,100,100,100]
[0,0,99,98]
[0,0,92,84]
[0,99,0,0]
which shows flows between country A, B, C and D.
I would like to revise the tick labels, so that:
1) Instead of showing 0K 5K 10K, I would like to show the country names (A - D), with no number or tick. I figured out this one by just commenting out all the codes relating to ticks.
2) Place the country names in the center of the arch. I don't know how to do this one.
View Replies
View Related
Mar 5, 2014
a buffer reader , how does it work and what is the code for it ?
View Replies
View Related
Oct 9, 2014
I've got a panel which an arbitrary number of text fields may be added to at run time. I've got it set up so that the window's height, and the height of the panel in which the fields appear will never exceed the height of the screen.What I don't have is a way to make the panel scroll to access the fields that are being visually truncated. I'm setting the autoscrolls on the panel to true, but when I run the program, the fields are simply truncated.
pnlDeclensions.setAutoscrolls(true);
View Replies
View Related
Jun 10, 2014
how inheritence and exception work together ?? what are the rules ??
View Replies
View Related
Oct 4, 2014
So I'm working on a project and noticed that my toString() method won't work. This is just an example of the type of code that I have in my real project. THIS IS MY MAIN CLASS
XML Code:
package trialanderror;
import java.util.Scanner;
public class TrialAndError {
public static void main(String[] args) {
Scanner keys = new Scanner(System.in);
String name;
String phonenumber;
[code]....
View Replies
View Related
Nov 17, 2014
I want to create a dropdown menu with contents from a database. You can see my Code in the attachment. It does not work, but why? I have a dropdown-symbol, but no contents.
View Replies
View Related
Jan 12, 2015
All I am trying to do is to make a section of code execute if two strings are equal. The two strings are userId and "A001062". When I use the debugger in Eclipse, I can see the value of userId as "A001062" but whatever string comparison I try never evaluates to true. I have tried
userId=="A001602"
userId.equals("A001602")
"A001602.equals(userId)
Assigning A001062 to a string called AAA and comparing userId to AAA
My code is as follows. I have also attached a screen shot from the Eclipse Debugger which makes me think the string comparison should succeed. I never see the debugger execute the print line nor do I see the print line on the JBOSS console.
String userId = StringUtils.trim(nextLine[HR_USER_ID]);
String AAA="A001062";
if (userId.intern().equals(AAA.intern())) {System.out.print("MKP1: " + userId+"-"+managerId);}
if (userId.compareTo("DTS0428")==0) {System.out.print("MKP2: " + userId+"-"+managerId);}
Attached image(s)
View Replies
View Related
Sep 13, 2014
import java.util.*;
public class OneDimenArray {
public static void main(String[] args) {
double[] decimals = new double[12];
double nums = 0.0;
double a = 1.0;
[Code] ....
These are the erroe codes I'm getting;
OneDimenArray.java:13: error: ']' expected
double[] decimals = double[Scanner.nextDouble()];
^
OneDimenArray.java:13: error: ';' expected
double[] decimals = double[Scanner.nextDouble()];
^
2 errors
----jGRASP wedge2: exit code for process is 1.
----jGRASP: operation complete.
View Replies
View Related
Dec 14, 2014
Okay so I have this part done and I cannot get all the JButtons to work. This is my first GUI!
import java.awt.Dimension;
import java.awt.FlowLayout;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.io.PrintStream;
import java.util.Arrays;
import javax.swing.BoxLayout;
[Code] ....
BTW the error is on 310, 311, and 312 and the error is cannot find symbol ....
View Replies
View Related
Mar 20, 2015
I am trying to get the gridBagLayout function to sort my code to look like the attached image. I am having trouble figuring out how to do it or even where to start. My code can be seen below and this was as far as I could get on my own.
// Using JSlider to size an oval.
import java.awt.BorderLayout;
import java.awt.Color;
import javax.swing.JFrame;
import javax.swing.JSlider;
import javax.swing.SwingConstants;
import javax.swing.event.ChangeListener;
[Code] .....
View Replies
View Related
Nov 4, 2014
I have being trying to figure out why my string doesn't work as a passcode and I can't seem to figure out why.
import java.util.*;
public class Login
{
public static void main(String[] args)
{
Scanner in = new Scanner(System.in);
System.out.println("Hello there, please state your name");
String userName = in.nextLine();
[Code] ....
View Replies
View Related
Mar 5, 2014
I have a code issue and I have a below question for the same.Assuming data[] is of type byte[], is the below statement in java -
while((data[p++] & 0x80) == 0x80);
same as -
while ( (data[p] & 0x80) == 0x80 ) { p++; }
I tried with do { p++; } while ( (data[p] & 0x80) == 0x80 ); That also doesn't seem to be the same thing. I am not putting code around this but essentially if I make this change for not using data[p++] code stops working!
View Replies
View Related
Feb 26, 2014
I have a simple applet that doesn't stray outside the sandbox. It used to work fine before Java 7 but now it craps out with security warnings. It does nothing but play a game, it doesn't even save the state of the game. This is the applet, it's a very simple chess program.
The warnings and popups I'm getting are:
activate javaTM platform SE 7U?allow now?activation blocked by security settings - I never changed any security settings and as I said, this applet stays firmly in the sandbox so I can't see what the issue is.Viewing the java error window I see
Java Plug-in 10.51.2.13
Using JRE version 1.7.0_51-b13 Java HotSpot(TM) Client VM
User home directory = C:UsersMike
----------------------------------------------------
c: clear console window
f: finalize objects on finalization queue
g: garbage collect
h: display this help message
l: dump classloader list
m: print memory usage
o: trigger logging
[code]....
why it shows the C:UsersMike directory in the above listing, there is no access to files etc.The applet plays fine if I run it in appletviewer.What do I need to do to make this simply work in anyone's browser? I have a similar problem with a (rather funky) Connect 4 program I wrote. It worked fine for years and then just stopped with the Java 7.
View Replies
View Related
Apr 25, 2014
I can't get Relative paths to work. I have created the class.dat file and I can't get java to recognize it. I am using Eclipse as an IDE. Was wondering if I could get Eclipse to recognize it. I tried with a .txt file as well and couldn't get that to work.
import java.io.*;
public class ReadBytes
{
public static void main(String[] args)
{
try
{
FileInputStream file = new FileInputStream("class.dat");
[Code] .....
View Replies
View Related