Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default VBA problem -

I am trying to write a code that will the do following: I have
columms(A,B,C,D) with data (with unlimited number of lines/data in eac
columm), I want to have the program search down the 3rd columm (C) an
when ever it finds an entry, to create a text box besides columm D a
the same line number.

Can this be done? Thanks alot for any help,

Regards,
Bourbo

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,824
Default VBA problem -

I used the textbox from the Drawing toolbar:

Option Explicit
Sub testme()

Dim myCell As Range
Dim myRng As Range

With Worksheets("sheet1")

.TextBoxes.Delete 'delete all existing textboxes???

Set myRng = .Range("c1", .Cells(.Rows.Count, "C").End(xlUp))
For Each myCell In myRng.Cells
If IsEmpty(myCell) Then
'do nothing
Else
With myCell.Offset(0, 1)
.Parent.Shapes.AddTextbox _
Orientation:=msoTextOrientationHorizontal, _
Top:=.Top, Left:=.Left, Width:=.Width, Height:=.Height
End With
End If
Next myCell
End With
End Sub


"Bourbon <" wrote:

I am trying to write a code that will the do following: I have 4
columms(A,B,C,D) with data (with unlimited number of lines/data in each
columm), I want to have the program search down the 3rd columm (C) and
when ever it finds an entry, to create a text box besides columm D at
the same line number.

Can this be done? Thanks alot for any help,

Regards,
Bourbon

---
Message posted from http://www.ExcelForum.com/


--

Dave Peterson

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default VBA problem -

Thank you very much, it works fine. You have been a great help! Thank
again.


--
Message posted from http://www.ExcelForum.com

Reply
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
Colon at the end of excel file name(ex: problem.xls:1, problem.xls financeguy New Users to Excel 2 January 15th 10 01:15 AM
Started out as an Access problem. Now an Excel problem RobertM Excel Discussion (Misc queries) 2 April 26th 06 07:30 PM
problem with a conditional max problem Brian Cornejo Excel Discussion (Misc queries) 1 February 18th 05 06:25 PM


All times are GMT +1. The time now is 08:35 PM.

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

About Us

"It's about Microsoft Excel"