File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Removing the "null" test from textfields

 
Ramaswamy Srinivasan
Ranch Hand
Posts: 295
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I need some idea in this regard.

The Scenario :

I have a page, where I have to display some fields, which are brought from database.

Before the records are fetched, the textfields show "null". I can get rid of this using script.

I want to know whether, we can make a generalized script, which could be used to check all the textfields, in a page and then, set a value of "", when it is null?

Is there a way to get all the textfields in a script?

Cheers,
Swamy
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This code may be what you are looking for:


You call it with:


There is one problem with this logic, if a person has JavaScript disabled, then the field values will still be set to the inital value since the code can not run.

Eric
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic