Steve Dyke

Ranch Hand
+ Follow
since Nov 16, 2004
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Steve Dyke

Ron McLeod wrote:
overrideValue.trim().isEmpty()



I will give this a try. Thanks.
2 weeks ago

Ron McLeod wrote:On the client side, couldn't you just use the JS trim() method?



This does not prevent spaces either:

2 weeks ago
Sorry, I am using Java 8
2 weeks ago

Ron McLeod wrote:

Try using isBlank() rather than isEmpty():



isBlank() does not seem to be a method of Java String class
2 weeks ago
This does not seem to work either:

2 weeks ago

Ron McLeod wrote:What is the value of overrideValue after this is executed?



The default value for the input is a zero.
It is a space. The user is wiping out the zero using the space bar.
Seems like my client code reads a space as allowed.
How do I check for a space and not allow it?
Would I use a regex in lieu of the jQuery trim method?

2 weeks ago

Liutauras Vilda wrote:

Try this version of formatting (note, I extracted some code to variables and inverted some logic, for better readability(?)):



Okay I changed my code to:



I am still getting this:

java.lang.NumberFormatException: For input string: ""

This is my client code:

2 weeks ago
I use JSTL to auto populate a select list. During the for each loop I check for a match on the var attribute.
If a match is detected I set the selected attribute on the option.
If there a way at the same time to fire the change event?

3 weeks ago
JSP
I just realized I did not need the extra attribute.
I removed it and it works as expected.

was:


changed to:
I got this to work by changing the parent container to position: absolute and declaring a height.
Again I need some help and have a wild question.
Is there any obvious reason why the following JS would fire twice?
This does not happen when I initially(load a menu) start my application.
However, once I log on(reload the menu), this behavior starts.

When I use jQuery .load on the navOptions Container(Child) it appears outside of the navDiv Container(Parent).
The navOptions Container(Child) is populated with a jQuery .menu. I need it placed inside the navDiv container and if the height of the child exceeds(screen resize) the parent then display a scroll bar for the y axis.

My CSS:



My JS code:

Tim Holloway wrote:

Only if I wanted to dynamically update the list with partial page updating would I use jQuery and then I'd be doing an AJAX fetch for the data.



Yes it is dynamic. The user is prompted for a document#.
This is sent to the server to do a remote data lookup.
Then the list is sent back to calling client.
I found the issue was the return string contained <select></select> tags.
The jqGrid element was already a select element and the .html(myList) was being placed inside the already existing select tags.
I only needed the option tag portion.
The only thing I cannot figure out is why it worked until this morning.
I realize this is a long shot with the limited data I can provide but I need the help if possible.
I have some machines exhibiting this behavior and some not.
This just started happening this morning. On the machines that are not displaying the list, I have sent different lookup parms to rule out various return strings.

Issue is a Select list is not being populated with a json return string.

I have verified that the function faiLogDocumentItemListResults is receiving the correct return string.
I did remove the Chosen portion of code and the native list is empty(not populating) either.

This is the string being built on the server:


This is my javascript: