LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 19
Default Do Loop and data formatting question

First I am getting a file and all the data is text. Is there a way to
convert the Text to Numbers?

What I am trying to do is generate a indented Bill of Material. The
report I received has levels in Column "B". I would like to indent the
cell in column "B" based on the level that the item report to. I am
trying to do a conditional do loop but I am get error with the
"Selection.InsertIndent 1". I have also added a X=Abs(Range("B" &
i).Select) or something to this affect and did a
Selection.InsertIndent X to try and keep the coding simple to no
luck.. Can someone help?



i = 4
Do
Range("B" & i).Select
If Range("B" & i).Select = -1 Then
Selection.InsertIndent 1
Else
Selection.InsertIndent 4
i = i + 1
End If
Loop Until IsEmpty(ActiveCell.Offset(0, 1))
End Sub
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Loop QUESTION to end of data range... mniccole Excel Worksheet Functions 2 December 4th 06 09:25 PM
Loop QUESTION to end of data range... mniccole Excel Worksheet Functions 2 December 4th 06 05:19 PM
Loop QUESTION to end of data range... mniccole Excel Worksheet Functions 0 December 4th 06 03:59 PM
Macro question - Need to copy data & formatting to another workboo Rog Excel Programming 3 July 27th 06 04:00 PM
VBA Loop Formatting Text Question Richard Excel Programming 3 June 13th 06 05:08 PM


All times are GMT +1. The time now is 05:03 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"