goldbug 0 Posted May 16, 2012 Report Share Posted May 16, 2012 The $date function return mm/dd/yyyy tt:tt:tt in my pc.I want to get the value of yyyy , mm and dd, so that i get year=2012, month=05, day=15 Thanks in advance. Quote Link to post Share on other sites
Randy Role 1 Posted May 16, 2012 Report Share Posted May 16, 2012 Here you go: clear list(%date_1) add item to list(%date_1, $date, "Delete", "Global") clear list(%date) add list to list(%date, $list from text($list item(%date_1, 0), "/"), "Delete", "Global") set(#month, $list item(%date, 0), "Global") set(#day, $list item(%date, 1), "Global") set(#year, $substring($list item(%date, 2), 0, 4), "Global") Quote Link to post Share on other sites
goldbug 0 Posted May 16, 2012 Author Report Share Posted May 16, 2012 Hi thanks.I use find regular expression to get the value too.Hope i get it right. year = $find regular expression($date, "([\\d]+\\s)") month = $find regular expression($date, "(^[\\d]+)") Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.