on 04-26-2007 12:10 PM
Hi all,
How can i search the content in a table. is there any UI Element is there to do this? Can any body give me any sample code for this
regards,
VJR
Hi,
you gotta do that programmatically,
here is a sample code:
int sizeOfstudent = wdContext.nodeCtx_vn_student().size();
//Ctx_vn_student is the node associated with the table ie its dataSource property
String filtername = wdcontext.currentContextElement.getSName();
//sName is the name to be searched , it is a context attribute
for(int i = sizeOfstudent-1;i>=0;i--)
{
String matchValue = recNode.getElementAt(i).getAttributeAsText("Name");
//get the name of 1st record(in table) or 1st elememnt in node, "Name" here is value attribute of that node
//so we are fetching its value and comparing it like..
if(matchValue.equalsIgnoreCase(filtername))
{
//here you can add the action to be taken on mathing name }
}
hope it helps
regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
If this is from the UI perspective, you could implement a filter for the table. See the blog link for details <a href="/people/peter.vignet/blog/2007/01/03/generic-web-dynpro-java-table-filter:///people/peter.vignet/blog/2007/01/03/generic-web-dynpro-java-table-filter
Regards,
Sudeep
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.