on 06-21-2007 5:43 AM
i got running timer in hh:mm:ss format
i want to extract value at particular instant
i.e current time from timer
if i extact that context var it will be running timer
how to achieve that
Hi Vani,
Create one attributes named time and mapping from component controller to view and write the following code in the init method..
SimpleDateFormat fSDateFormat = null;
fSDateFormat = new SimpleDateFormat("dd/MM/yyyy HH:mm:ss");
Date now = new Date();
String date_out = fSDateFormat.format(now);
IPrivateCreditExposureView.IContextElement date_obj =
wdContext.createContextElement();
date_obj.setTime(date_out);
if u satisfied this reward points.....
Thanks,
P.Manivannan.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hai ,
Can you explain your question clearly,
If you want to get the current time from a context value,
create a Context attribute of type string, make calculated is true, it will create getter and setter methods for attribute,
in getter method simply write this code
{
SimpleDateFormat fmtIn = new SimpleDateFormat("hh:mm:ss");
return fmtOut.format(new Date());
}
Regards,
Naga
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.