Support Forum Softcomplex logo
About Us  | Services  | Download  | Order  | Support  | |
| Search | Today's Posts | Stats | Board Rules | Not logged in [ Login | Register ]
go to bottom
Last active: Never

Printable Version | Subscribe | Add to Favourites   Post new thread
Author: Subject: custom sorting function help
bidllc
Newbie

Posts: 1
Registered: 9/22/2005
Member Is Offline
posted on 9/22/2005 at 09:17 PM Reply With Quote
custom sorting function help


I have a column holding data in the format:

10 (33%)
12(36%)
5(3%)


I've written a function that strips the number in parens:

function sort(a)
{
var re = new RegExp("(.*)", "g");
return = Number(a.replace(re,""));
}

and referenced it properly. It works, except it appears to treat the value as a string sorting like this

1
2
30
4
55
6

Is there a way to get the result treated as a number??
View User's Profile View All Posts By User U2U Member
Post new thread

Related Links:
Product Page
Product Demonstrations Live Demos
Simple
XP-styled
3D designed
Product Documentation Documentation
Documenation Page
Change Log
Support Forum Technical Support
Support Forum
Customer Care System
Order Now ORDER NOW!
Add to Cart
View Cart

Go To Top


Powered by XMB 1.9.1 Nexus
Developed By Aventure Media & The XMB Group © 2002-2004