Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Macro to insert object into spreadsheet ??


Hi,

I would like to have a square (ie. three cells long) that contain
information that the user must input, and can be moved around th
spreadsheet.
Can I program this in VBA ?

Any help is greatly appreciated.

Ale

--
klusk
-----------------------------------------------------------------------
kluska's Profile: http://www.excelforum.com/member.php...fo&userid=3774
View this thread: http://www.excelforum.com/showthread.php?threadid=57324

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Macro to insert object into spreadsheet ??

Sub AddATextBox()
Dim rng As Range, bx As Shape
Set rng = Range("B9:D9")
Set bx = ActiveSheet.Shapes.AddTextbox( _
msoTextOrientationHorizontal, _
Top:=rng.Top, _
Left:=rng.Left, _
Width:=rng.Width, _
Height:=0.75 * rng.Width)
bx.TextFrame.Characters.Text = "Add some text here"
With bx.TextFrame.Characters.Font
.Name = "Arial"
.FontStyle = "Regular"
.Size = 10
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
End With

End Sub


is a possibility.

--
Regards,
Tom Ogilvy


"kluska" wrote:


Hi,

I would like to have a square (ie. three cells long) that contains
information that the user must input, and can be moved around the
spreadsheet.
Can I program this in VBA ?

Any help is greatly appreciated.

Alex


--
kluska
------------------------------------------------------------------------
kluska's Profile: http://www.excelforum.com/member.php...o&userid=37740
View this thread: http://www.excelforum.com/showthread...hreadid=573242


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
how do i prepare a macro to insert drawing object on specific cell Harshad[_2_] Excel Discussion (Misc queries) 2 November 25th 08 08:06 AM
Macro to insert an object in a specific cell 2007` mpsears62 Excel Discussion (Misc queries) 2 July 7th 08 07:04 PM
Macro to insert a object in excel Lester from AUS[_2_] Excel Discussion (Misc queries) 5 March 28th 07 02:47 AM
How do I insert a 2-3 page Excel spreadsheet as an object in MS Wo D at Spectra Excel Discussion (Misc queries) 0 May 15th 06 07:39 PM
Is there a way to insert a formula, password or macro in an excel spreadsheet that will automatically delete the spreadsheet? oil_driller Excel Discussion (Misc queries) 1 February 8th 05 09:34 AM


All times are GMT +1. The time now is 08:21 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"