Options

time

toshitaporitoshitapori Member Posts: 52
Hi All,
how to convert the time field into 24 hr for example if it is 1.30 it shud show 13.30 .
thanx in advance
tapori

Comments

  • Options
    jmjm Member Posts: 156
    Hi,

    try it with "<Hours24,2>.<Minutes,2>" in the format property or use the format command.

    for more details have a look to the online help of the format property.

    br
    Josef Metz
    br
    Josef Metz
  • Options
    toshitaporitoshitapori Member Posts: 52
    Hi jm ,
    it did not worked :-k .

    Thanks
    Tapori
  • Options
    jmjm Member Posts: 156
    Hi Tapori,

    please try this code:
    TestTime := 133000T;
    
    MESSAGE('Time: >%1<',FORMAT(TestTime,0,'<Hours24,2>.<Minutes,2>'));
    
    TestTime := 093100T;
    
    MESSAGE('Time: >%1<',FORMAT(TestTime,0,'<Hours24,2>.<Minutes,2>'));
    
    br
    Josef Metz
    br
    Josef Metz
  • Options
    tguptatgupta Member Posts: 86
    Hi toshitapori,
    Its quite simple if you look at the format property of the time field .
    Just put exactly this thing on the format property .
    <Hours24,2>.<Minutes,2>.<Seconds,2>

    I did the same thing for oneof my client recently so preety sure it works .

    Cheers,
    Tarun
Sign In or Register to comment.