Announcement

Collapse
No announcement yet.

Print formating with other than US currency

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Print formating with other than US currency

    Is there a way to get similar results with print using "$$##.##"
    when the currency is for example UK pounds? Subsituting the "££##.##" does not work.

  • #2
    Try using the REPLACE statement (function).


    ------------------


    [This message has been edited by Mel Bishop (edited February 08, 2003).]
    There are no atheists in a fox hole or the morning of a math test.
    If my flag offends you, I'll help you pack.

    Comment


    • #3
      Originally posted by Mel Bishop:
      Try using the REPLACE statement (function).

      Thanks Mel for replying, but I don't think REPLACE can work as the variable that is used in say ' PRINT USING "$###.##"; amount ' is a numeric variable and doesn't even contain a "$" in it. RELPLACE only works with string variables. I like PRINT USING fuction for financial tables as it always put the $ right before the most significant digit no matter how far it is from the decimal point and still keeps all number in a column lined up. Seems like anyone abroad using BASIC should have this problem and I'm wondering how they get around it.

      ------------------

      Comment


      • #4
        In PB for DOS you can use the internal variable pbvUsingChrs to change the behavior of PRINT USING, e.g. pbvUsingChrs = "*£,.". You must continue using "$$###.##", but PB will print a £ instead of a $.




        ------------------

        Comment


        • #5
          RELPLACE only works with string variables.
          You can write your formatted output into a string variable (with USING$ function) and use REPLACE on that variable.

          ------------------
          Davide Vecchi
          [email protected]

          Comment

          Working...
          X