Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
In the immediate window, I input:
? "_" & " abc " & "_" and it returns: _ abc _ Why did it knock off all but one of the spaces off the right side of the middle string? Thanks, Woody |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
It looks like it has something to do with the underscores. For instance:
?"_ _" _ _ ?"' '" ' ' ?"_ '" _ ' ?"" Space(10) "<" < ? "_" Space(10) "_" _ _ ? "_"; Space(10); "_" _ _ ? "_" Tab(10) "_" _ _ ? "" Tab(10) "<" < using Win 2K, Excel 2002 "Woody" wrote in message .121... In the immediate window, I input: ? "_" & " abc " & "_" and it returns: _ abc _ Why did it knock off all but one of the spaces off the right side of the middle string? Thanks, Woody |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Woody
you only have one space before abc and one after abc which is what the return result shows "_" & " abc " & "_" gives a string of _ abc _ --- Message posted from http://www.ExcelForum.com/ |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
how do you explain this?
? "_"; Space(10); "_" _ _ or this? ?"_ _" _ _ "mudraker " wrote in message ... Woody you only have one space before abc and one after abc which is what the return result shows "_" & " abc " & "_" gives a string of _ abc _ --- Message posted from http://www.ExcelForum.com/ |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
mudraker wrote in
: Woody you only have one space before abc and one after abc which is what the return result shows "_" & " abc " & "_" gives a string of _ abc _ --- Message posted from http://www.ExcelForum.com/ no, there are 3 spaces before and after "abc". This should make it more obvious: ?"_" & space(3) & "abc" & space(3) & "_" _ abc _ |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I don't know the correct answer but I beleive it has to do with VB
using _ as the symbol theat the line of code is continued on to th next line and VBA automatically removing all extra spaces betwee operators -- Message posted from http://www.ExcelForum.com |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
This one's worthy of inclusion in j-walk's 'Excel Oddities':
http://j-walk.com/ss/excel/odd/index.htm -- |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Cell Format changes unexpectedly | Excel Discussion (Misc queries) | |||
Excel Closes Unexpectedly | Excel Discussion (Misc queries) | |||
Excel quits unexpectedly | Excel Worksheet Functions | |||
data changes unexpectedly | New Users to Excel | |||
What does an ampersand mean in VBA? | Excel Programming |