PC Review


Reply
Thread Tools Rate Thread

Adding a space?

 
 
=?Utf-8?B?U2pha2tpZQ==?=
Guest
Posts: n/a
 
      27th Feb 2007
I have an array which holds names and details i have been able to set "test1"
to the longest name in the array and add 5 more spaces. I then want it to
lookat the first value in the array and count howmany characters it is if it
is less than that that was stored in "test1" i want it to add spaces on
untill it reaches the same ammount as "test1" is this possible?
 
Reply With Quote
 
 
 
 
Bob Phillips
Guest
Posts: n/a
 
      27th Feb 2007
ary(0) = Space(Len(test1) - Len(ary(0))) & ary(0)


--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Sjakkie" <(E-Mail Removed)> wrote in message
news:6D9A91A9-1DBD-4E9D-BD1C-(E-Mail Removed)...
>I have an array which holds names and details i have been able to set
>"test1"
> to the longest name in the array and add 5 more spaces. I then want it to
> lookat the first value in the array and count howmany characters it is if
> it
> is less than that that was stored in "test1" i want it to add spaces on
> untill it reaches the same ammount as "test1" is this possible?



 
Reply With Quote
 
=?Utf-8?B?VG9tIE9naWx2eQ==?=
Guest
Posts: n/a
 
      27th Feb 2007
s = arr(lbound(arr))
if len(s) < len(test1) then
s = s & string(len(test1)-len(s)," ")
arr(lbound(arr)) = s
end if

--
Regards,
Tom Ogilvy


"Sjakkie" wrote:

> I have an array which holds names and details i have been able to set "test1"
> to the longest name in the array and add 5 more spaces. I then want it to
> lookat the first value in the array and count howmany characters it is if it
> is less than that that was stored in "test1" i want it to add spaces on
> untill it reaches the same ammount as "test1" is this possible?

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Missing space on HD; adding new HD Pekka Numminen Windows Vista Hardware 2 9th Oct 2008 10:58 PM
Adding more space in a pulldown box? jcolley05 Microsoft Excel Misc 2 18th Feb 2008 11:46 PM
Adding a space eddie57 Microsoft Excel Worksheet Functions 3 6th Aug 2007 06:08 PM
Adding a space with =A59&B59 =?Utf-8?B?Smlt?= Microsoft Excel Worksheet Functions 1 17th May 2005 12:37 AM
Adding more space kevindu28@yahoo.com DIY PC 2 13th Feb 2005 09:16 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:50 AM.