RE: DataGrid - How to set the page?

2005-02-11 Thread Néstor Boscán
Hi Joselito

Basically yes you have to set the parameters. The class
DataGridParameters.getDataGridPageIndex method will return the page index
for your datagrid and the DataGridParameters.getDataGridOrderIndex will
return the order index. So if you have a form you will have to do something
like this:

% request.setAttribute (pageIndex,
DataGridParameters.getDataGridPageIndex  (request, datagrid1));
   request.setAttribute (orderIndex,
DataGridParameters.getDataGridOrderIndex (request, datagrid1)); %

input name=p_datagrid_datagrid1_page_index  type=hidden value=c:out
value=${pageIndex}//
input name=p_datagrid_datagrid1_order_index type=hidden value=c:out
value=${orderIndex}//

Regards,

Néstor Boscán

-Mensaje original-
De: Joselito Viana Soares [mailto:[EMAIL PROTECTED] 
Enviado el: Viernes, 11 de Febrero de 2005 08:42 a.m.
Para: [EMAIL PROTECTED]
Asunto: ENC: DataGrid - How to set the page?

Hi, Nestor

Excuse me to send to you this email, but I still didn't receive reply of the
my question. The TagLibs mailing list is with problem.

One more time, congratulations by the development. How is the status of the
project? Are there new features? We are testing the DataGrid in our
application and we are liking a lot.

Regards,

Joselito Soares


-Mensagem original-
De: Joselito Viana Soares [mailto:[EMAIL PROTECTED] Enviada em:
quarta-feira, 26 de janeiro de 2005 17:03
Para: 'Tag Libraries Users List'
Assunto: DataGrid - How to set the page?


Hi,

Congratulations by the development. We are testing the datagrid in our
application and we are obtaining good results.
At the moment we have the following problem: We create datagrid with a
column to select the row. When we click a button of our page (for example:
update), we desire that the action is executed and that in the end it
returns to datagrid in the same page where was. Do we need to set the
parameter p_datagrid_datagrid1_page_index? Are there another way?

Regards,

Joselito Soares



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Dynamic Map Access

2005-02-11 Thread Karl Coleman
I have a Map that contains keys of mime types and the values are more 
understandable String. What I want to do is on a JSP dynamically look up the 
key within an iteration. I know I can access map value by hard coding it such 
as ${mimeTypes[application/msword]}, but I am having problems figuring out 
how to make the key a variable.

Thanks,
Karl

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Dynamic Map Access

2005-02-11 Thread Karl Coleman
Nevermind. I fell like a complete idiot. I just figured it out.

Karl

-Original Message-
From: Karl Coleman 
Sent: Friday, February 11, 2005 2:54 PM
To: Tag Libraries Users List
Subject: Dynamic Map Access


I have a Map that contains keys of mime types and the values are more 
understandable String. What I want to do is on a JSP dynamically look up the 
key within an iteration. I know I can access map value by hard coding it such 
as ${mimeTypes[application/msword]}, but I am having problems figuring out 
how to make the key a variable.

Thanks,
Karl

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[BSF Taglib]

2005-02-11 Thread Carlos Cajina
Hi. I've just started using BSF hoping that this taglib (and the technology 
under the hood) could help me integrate portions of Java and JavaScript code 
within my JSP pages. My first attempt was to be able to assign an HTML control 
value to a Java variable (i.e. something like %= String htmlCtrlValue = 
document.all.someSelectControl.value; %), but I haven't been successful at 
it...

Here's what I've done:

1. Declared the taglib in my web.xml file adding the necessary *.jar and *.tld 
to their proper locations.
2. Include %@ taglib uri=http://jakarta.apache.org/taglibs/bsf-1.0; 
prefix=bsf % in my JSP
3. Added bsf.jar to my classpath.
4. Added rhino1_5R3 (js.jar) to the classpath

So far I keep getting this error:

2005-02-11 20:51:28,296 INFO  [STDOUT] org.apache.bsf.BSFException: JavaScript 
Error: Internal Error: java.lang.ClassCastException
2005-02-11 20:51:28,296 ERROR [STDERR] JavaScript Error: Internal Error: 
java.lang.ClassCastException: 
2005-02-11 20:51:28,296 ERROR [STDERR] java.lang.ClassCastException
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.mozilla.javascript.optimizer.Codegen.compile(Unknown Source)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.mozilla.javascript.Context.compile(Unknown Source)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.mozilla.javascript.Context.compile(Unknown Source)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.mozilla.javascript.Context.compileReader(Unknown Source)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.mozilla.javascript.Context.evaluateReader(Unknown Source)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.mozilla.javascript.Context.evaluateString(Unknown Source)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.bsf.engines.javascript.JavaScriptEngine.eval(Unknown Source)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.bsf.util.BSFEngineImpl.exec(Unknown Source)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.taglibs.bsf.scriptlet$1.run(scriptlet.java:99)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
java.security.AccessController.doPrivileged(Native Method)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.taglibs.bsf.scriptlet.doEndTag(scriptlet.java:92)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jsp.registro_content_jsp._jspx_meth_bsf_scriptlet_0(registro_content_jsp.java:1222)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jsp.registro_content_jsp._jspx_meth_html_form_0(registro_content_jsp.java:219)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jsp.registro_content_jsp._jspService(registro_content_jsp.java:103)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:210)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:575)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:498)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:822)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:398)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.struts.taglib.template.GetTag.doStartTag(GetTag.java:201)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jsp.template_jsp._jspx_meth_template_get_3(template_jsp.java:251)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jsp.template_jsp._jspService(template_jsp.java:135)
2005-02-11 20:51:28,312 ERROR [STDERR]  at 
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137)
2005-02-11 20:51:28,328 ERROR [STDERR]  at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
2005-02-11 20:51:28,328 ERROR [STDERR]  at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:210)
2005-02-11 20:51:28,328 ERROR [STDERR]  at 
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
2005-02-11 20:51:28,328 ERROR [STDERR]  at 
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
2005-02-11 20:51:28,328 ERROR [STDERR]  at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
2005-02-11 20:51:28,328 ERROR [STDERR]  at