Format$ using "!@" When Value ""

DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Thread: Format$ using "!@" When Value ""

  1. #1
    Join Date
    Jul 2004

    Format$ using "!@" When Value ""

    I use the following logic to get the value equal to the value in SavSLCust_ShipToCity plus trailing spaces

    Format$(SavSLCust_ShipToCity, "!@@@@@@@@@@@@@@@@@@@")

    problem is if the value of SavSLCust_ShipToCity is equal "" then the Format$ does not return all spaces. Any ideas on how to change the Format$ so it does return all trailing spaces when value is ""?

  2. #2
    Join Date
    Nov 2003
    Portland, OR
    Instead of Format$, try this:

    Dim Buffer As String
    Buffer = Space$(20)

    LSet Buffer = SavSLCust_ShipToCity

    You only have to initialize Buffer once, then use LSet (and/or RSet) to populate it with values.
    Phil Weber

    Please post questions to the forums, where others may benefit.
    I do not offer free assistance by e-mail. Thank you!

Similar Threads

  1. Replies: 2
    Last Post: 10-12-2005, 09:07 AM
  2. Format$ (Left to Right)
    By Don in forum VB Classic
    Replies: 6
    Last Post: 09-09-2005, 01:23 PM
  3. opening Filename with "(" character
    By krish_indus in forum Java
    Replies: 2
    Last Post: 05-26-2005, 06:22 AM
  4. Replies: 1
    Last Post: 01-27-2003, 07:12 PM
  5. problem for ";"
    By James in forum VB Classic
    Replies: 2
    Last Post: 09-23-2002, 10:37 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
Latest Articles
Questions? Contact us.
Web Development
Latest Tips
Open Source

   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center