Results 1 to 3 of 3

Thread: [RESOLVED] Keeping output from a formula aligned.

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Feb 2006
    Posts
    27

    Resolved [RESOLVED] Keeping output from a formula aligned.

    I have a formula which outputs a time bewteen 2 dates in the format Days Hours Minutes. I have a formula which calculates this and this is the line for the output:

    truncate(dd) & " D " & truncate(hh) & " H " & truncate(mm) & " M";

    However, if there is a day or hour with 2 digits, the alignment screws up and it looks ugly. What would be the best way to fix this?
    Thanks

  2. #2
    Junior Member
    Join Date
    Feb 2006
    Posts
    27

    Re: Keeping output from a formula aligned.

    Try entering something like this: (Use DateTime because you need Days Hours and Minutes and format it with CStr)

    Cstr( DateTime(Datediff("d",CDate({@Fecha1}) , CDate({@fecha2}))),"dd ' D ' hh ' H ' mm ' M'")

    I attach a .rpt file.

    I expect it may help you.

    Regards,
    Tribo
    Attached Files Attached Files

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Feb 2006
    Posts
    27

    Re: Keeping output from a formula aligned.

    thank you for that

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width