ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   how prin in cells by using vb macro (https://www.excelbanter.com/excel-programming/305398-how-prin-cells-using-vbulletin-macro.html)

nader

how prin in cells by using vb macro
 
I want to use the visual basic tools coomand and textbox
so I want to know how Ii can print the data in the cells of excel fro
the textbox or command
by the way I did this code : cells.cells and it print in all cells o
excel, I want to print in a specific cells like a1 and b2 etc..

and thankyou for all

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


Mauro Gamberini[_2_]

how prin in cells by using vb macro
 
I want to use the visual basic tools coomand and textbox
so I want to know how Ii can print the data in the cells of excel from
the textbox or command

Private Sub CommandButton1_Click()
Sheet1.Range("A1").Value = TextBox1.Text
End Sub

Or

Private Sub CommandButton1_Click()
ActiveCell.Value = TextBox1.Text
End Sub

--
----------------------------
Mauro Gamberini



Bob Phillips[_6_]

how prin in cells by using vb macro
 
Try Cells(1,"A") as an example - A1.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"nader " wrote in message
...
I want to use the visual basic tools coomand and textbox
so I want to know how Ii can print the data in the cells of excel from
the textbox or command
by the way I did this code : cells.cells and it print in all cells of
excel, I want to print in a specific cells like a1 and b2 etc..

and thankyou for all .


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




nader

how prin in cells by using vb macro
 
thankyou for both of you to help m

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



All times are GMT +1. The time now is 01:40 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com