Win a copy of Svelte and Sapper in Action this week in the JavaScript forum!

Marcel Jacome

+ Follow
since Feb 06, 2009
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 Marcel Jacome

Hi guys, i have come across this very confusing problem and i do not know what to do about it. I have a link that makes this call: Javascript:abrirVentanaDepuracion();

which in turn calls an struts action named conectarAplicacionDepuracion which looks like this

the latter accesses a jsf page protected with jaas , so i have this authentication servlet in the jsf web project

java.lang.IllegalStateException: Cannot create a session after the response has been committed happens when the app uses this servlet. Is there any way to prevent this error and access the jsf page without this error happening? . What changes do i have to do in my code ?? Is it a problem that i am using https ?

Thanks in advance

8 years ago
Hi everyone , i have a problem persisting to the database using jpa . I am getting this exception 11:32:09,508 ERROR [JDBCExceptionReporter] ORA-02049: timeout: transacci¾n distribuida esperando bloqueo

I have two entities with the following code:

The other entity is

This is where i persist

What i basically do here is :

1. populate and persist a Reintegro type object , so as to get a sequence number (idReintegro) from a sequence generator
2. find and persist other entities (No problem here)
3. Take the sequence obtained in step 1 (idReintegro) , assign it to aportePortafolioDos object (foreign key value)
4. Persist the aportePortafolioDos object

The thing is that once the persistence context is synchronized with the Oracle 11g database , it hangs for a few minutes and then throws the exception ORA-02049: , which indicates there is a lock . The lock occurs while trying to persist aportePortafolioDos on an insert statement.

If I disable the foreign key on the table mapped by AportePortafolioDos , everything works as expected . but if the foreign key is active then i get the deadlock.

I have been trying to find a solution for days , to no avail. Is there anything to do at all ? Please help!!!
UPDATE: I have discovered the cause of the problem , it seems that under IE8 , there is an incompatibility problem , if you go to View -> Compatibility View , things begin to work again. If the compatibility view is switched off , the modal panel component stops working. What can i do in this case , is there any way to circumvent or avoid this problem? will switching to a better version of Richfaces help here??
9 years ago
The page works like this: A value is entered into

Since this is an onblur event , the screen is dimmed and the modal panel shown , then a combobox is updated and the request is completed , but the modal panel is never hidden.
9 years ago
Hi guys, i turn to your wisdom to help me out on this problem that really has me banging my head against a brick wall. I have a page that uses a4j:status to display a modal panel while an ajax request is in progress.

It works fine in Firefox and google chrome , but in IE8 the modal panel never goes away , even though the request has been completed.

This is the code

I am desperate please help!!! . Thanks in advance
9 years ago
Hi , i am having this problem with a rich calendar component , which is implemented as follows

What i want to do here is set a date range from January 1st , 2003 to now . The calendar works fine with any date except the ones that are previous to Jan 1st , 2003 , those dates throw a java.lang.IllegalArgumentException. I would like to catch the exception so as not to get the entire stack trace on screen , but i dont know if there is a way to accomplish this.

Thanks in advance.
9 years ago
Problem came back again , but Mark gave me a clue as to the serviceLocator pattern in the problem class. And he hit it right in the nail !!!

What i did was comment the protected variable and move the declaration inside the methods that needed it and voila.

Thank you very much Mark.

10 years ago
As far as the javascript and the undefined array elements , i just made both arrays global and solved the issue with IE.
It was easier than i thought , just used the onfocus method exposed by struts layout and it worked.
Is there anything to do at all??? Should i use a library like jquery to solve this problem??? are there more options??
Any ideas?? thanks
You can copy and paste the code into an html file and run it. The problem lies in these functions

In the code above , the array arr[] exists before entering the for loop, once inside the loop , the elements are undefined.

The same happens here in this function where i am changing an arrays' elements to uppercase

Thanks for your help
Hi guys, i am facing a big problem concerning javascript and internet explorer. I have been working on a virtual keyboard and everything works fine in all browsers except internet explorer 6 and up. The problem is that the elements of the arrays in my program turn out to be undefined. If i try the same program in a different browser , it works perfectly.
The code is as follows:

Pressing the button labeled "MAYUS." , the program changes the keys' values from lowercase to uppercase and viceversa, but this funcionality does not work in internet explorer.

What can i do to make it work for IE ?

Thanks in advance

Hi , i am trying to create a password field within a jsp which uses struts layout tags. This password field is associated to a virtual keyboard control created in javascript. what i want to do is replace the old <layout:password> control with the new password input field with the virtual keyboard.

My jsp looks like this:

This is the javascript where the virtual keyboard is assembled

What i am basically doing is replacing the following simple password field

with the password field and the keypad by trying to create an html control as follows:

but all i can see is the password field but no keypad. How can I create this control ? Can you guys point me in the right direction ?

Thanks in advance.

10 years ago
Thank you Mark , removing an attribute (duplicate="preserve") from build.xml and rebuilding solved the problem , which is weird.
10 years ago
Thanks Mark for your reply , the constructor looks like this

Thanks again.

10 years ago