Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!

Haiko van der Schaaf

Greenhorn
+ Follow
since Jan 19, 2005
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 Haiko van der Schaaf

I got it fixed. I made the mistake to clean the data of the JTable by nullifying the JTable. Appareantly the JScrollpane, where i add the JTable to, and the JTable went out of sync.

Thanks for your trouble.
15 years ago
hi everyone,

I construct a JTable with a DefaultTableModel. But after filling in some data in the table on the screen, my program can not find any data in the TableModel, everything is null. I understand from the Java API (5.0) that there is default a TableModelListener. Does anyone how an idea how this is possible ??

Thanks for the help

The code is below:
instantiating the table -->


retreiving data


[ January 19, 2007: Message edited by: Haiko van der Schaaf ]
15 years ago
problem was in the <c:import> tag. When I add the attribute charEncoding with the value utf-8 the problem was solved. I did a recursive import in this jsp file(mijnxtranet/notifylevel.jsp). The complete code is:
What a bit strange is that the directive is overruled by the import attribute.

<%@ page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8" %>
<%@ taglib uri="/WEB-INF/struts-bean-el.tld" prefix="bean-el"%>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%>
<%@ taglib uri="/WEB-INF/struts-html-el.tld" prefix="html-el"%>
<%@ taglib uri="/WEB-INF/struts-logic-el.tld" prefix="logic-el"%>
<%@ taglib uri="/WEB-INF/struts-tiles.tld" prefix="tiles"%>
<%@ taglib uri="/WEB-INF/c.tld" prefix="c"%>
<%@ taglib uri="/WEB-INF/fmt.tld" prefix="fmt"%>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic"%>

<html-el:xhtml />

<c:set var="my_node" value="${requestScope.recurse_node}" />


<c:set var="ulclass" value="open" />
<c:if test="${!my_node.uitgeklapt}">
<c:set var="ulclass" value="closed" />
</c:if>

<ul id="<c:out value='ul_${my_node.klapTagValue}' />"
class="<c:out value='${ulclass}' />">
<c:forEach var="curcat" items="${my_node.children}">
<li id="<c:out value='${curcat.klapTagValue}' />">
<%--
klapbaar: <c:out value="${curcat.klapbaar}" />
uitgeklapt: <c:out value="${curcat.uitgeklapt}" />
--%>
<c:choose>
<c:when test="${curcat.klapbaar}">
<c:choose>
<c:when test="${curcat.uitgeklapt}">
<html-el:img src="/images/global/min.gif"
styleId="img_${curcat.klapTagValue}" border="0" alt="" />   
</c:when>
<c:otherwise>
<html-el:img src="/images/global/plus.gif"
styleId="img_${curcat.klapTagValue}" border="0" alt="" />   
</c:otherwise>
</c:choose>
</c:when>
<c:otherwise>
<html-el:img src="/images/global/minplusspacer.gif" border="0"
alt="" />   
</c:otherwise>
</c:choose>
<c:set var="checked" value="" />
<c:if test="${curcat.checked == true}">
<c:set var="checked" value="checked" />
</c:if>

<input type="checkbox" name="cat_<c:out value="${curcat.id}"/>"
value="<c:out value="${curcat.id}"/>" <c:out value="${checked}"/>
<c:if test="${!curcat.allChildrenChecked}"> style="background-color: #ddd"</c:if> />
<c:out value="${curcat.naam}" />
<c:if test="${not empty curcat.children}">
<c:set var="recurse_node" value="${curcat}" scope="request" />
<c:import url="../mijnxtranet/notifylevel.jsp" charEncoding="UTF-8"/>
</c:if>
</li>
</c:forEach>
</ul>
<c:set var="recurse_node" value="${my_node}" scope="request" />
[ August 07, 2006: Message edited by: Haiko van der Schaaf ]
15 years ago
JSP
Hoi,

I got a problem with displaying the character �. The code of the jsp is:

<c:out value="${someproperty}" escapeXml="false"/>

The static content in the JSP displays the � correctly, but in the out-tag the character is misformed. I have set the page encoding and contentType of the page in utf-8 and the string someproperty correctly shows an � with debugging, but somewhere in the translation from the controller to the view the character is misformed. Has anyone an idea what happens ??

Thanks Haiko
15 years ago
JSP
Hi,

I am just building an ordinary Java client-program with Eclipse. I run into a problem when I am debugging. While debugging Eclipse steps through the code normally, until it comes to giving the initiative to the user. Eclipse does not generate my Swing composed screens. I got the message "source not found" on a Swing component. When I try the button "Change Attached Source" it points to a folder rt.jar of Eclipse which does contain the Swing component . Is there something wrong with my settings or is this the behaviour of Eclipse ?? Does anyone have the same problem ?? Would be thankfull for your help
thanx, that fixed the problem. I have added weightX constraints and that did the trick.

Gr. Haiko
17 years ago
Michael, is it illegal to post on two different forums ?? And if not, isn 't there a ex-Stasi meeting you should attend ?
17 years ago
Hi,

I am having some trouble with JTextArea. I insert Strings by using the append() method,

for (int i = 0 ; i < ing.length - 1; i++ ) {
gekozenIngredienten.append((String )(ing[ i ] + ", "));

and that causes the JTextArea to grow in width. But when I am setting Linewrap to true my GridbagLayout turns in some really ugly screen. Does anyone know how to add Strings to a JTextArea without the Area to grow in width ?? Or setting LineWrap to true without my GridBagLayout going of the screen ?

Thanx Haiko
17 years ago