How to count drawing object (text box) in vba
This will work if your textbox is from the Control Toolbox.
Sub way()
With Sheets(1)
.OLEObjects("Textbox1").Object = "My name"
.OLEObjects("Textbox2").Object = "is"
.OLEObjects("Textbox3").Object = "Mike Jackson"
End With
For i = 1 To 3
Sheets(1).Range("A" & i) = _
Sheets(1).OLEObjects("Textbox" & i).Object.Value
Next
End Sub
"geniusideas" wrote in message
...
Hi,
My next project is to count drawing object which is textbox place this
textbox content into cells.
For example:
TextBox1 = My Name
TextBox2 = is
TextBox3 = Micheal Jackson
Final result all these text is inside individual cell
Range(A1) = My Name
Range(A2) = Is
Range(A3) = Micheal Jackson
Please help in vba code.Thanks
Note : number of textbox is umlimited..
Please help
|