Java Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Try It Free
Go Back   Dev Shed ForumsProgramming LanguagesJava Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Generate data entry and reporting .NET Web apps in minutes, straight from your database. Read our FREE whitepaper “Build Web 2.0 Applications Without Hand-Coding” Download now!
  #1  
Old June 28th, 2001, 09:42 AM
val04 val04 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2001
Posts: 0 val04 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Unhappy Help! Urgent! Can't find any info on property in a bean

I'm trying to test my JSP. Unfortunately, whenever I load the page, I encounter the error message: Can't find any info on the property - PropertyStatusMsg, in a bean of type 'login'. What could possibly be wrong with my code?

login.java

public class login {
//Properties
private int Idno = 0;
private int idnum;
private String pwd = null;
private String pword;
private boolean isInitialized;
private String msg;

public void setIdno(int idnum) {
Idno = idnum;

}

public int getIdno() {
return Idno;

}

public void setPwd(String pword) {
isInitialized = true;
pwd = pword;

}

public String getPwd() {
return pwd;

}

public String getPropertyStatusMsg() {

msg = "Welcome!";

if(!isInitialized()) {
msg = "Please enter values in all fields.";
}

return msg;

}

public String[] getPropertyStatusDetails() {
Vector details = new Vector();

if(isInitialized() && !isValid()) {

if(idnum == 0) {
details.addElement("Id number is missing.");
}

if(pword == null) {
details.addElement("Password is missing.");
}

}

String[] arr = new String[details.size()];
details.copyInto(arr);
return arr;
}

public boolean isInitialized() {
return isInitialized;
}

public boolean isValid() {
return isInitialized() && getIdno() != 0 && getPwd() != null;
}

}

login.jsp


<%@ page language="java" contentType="text/html" %>
<jsp:useBean id="login" scope="request" class="login" />
<jsp:setProperty name="login" property="*" />

<html>
<head>
<title>Untitled</title>
</head>

<body>
<font color="red">
<jsp:getProperty name="login" property="propertyStatusMsg" />
<ul>
<ora:loop name="login" property="propertyStatusDetails" loopId="details" className="String" >
</ora:loop>
</ul>
</font>

</body>
</html>

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesJava Help > Help! Urgent! Can't find any info on property in a bean


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway