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: 989
Default Copy a TextBox (shape)

Leith -

I'm not sure, its the type that you can create in Excel 2007 ...
Insert/Text/TextBox.

Mark

"Leith Ross" wrote:


OssieMac;208941 Wrote:
Hi Mark,

I haven't been able to do this without actually activating the 2nd
workbook
and worksheet and selecting the paste location. However, here is what I
have
that works but maybe someone else can do it better.

Windows("Book1").Activate
Sheets("Sheet1").Shapes("TextBox1").Copy
Windows("Book4").Activate
Sheets("Sheet2").Activate
Range("B8").Select
ActiveSheet.Paste

--
Regards,

OssieMac


"Mark" wrote:

Hi -

I am working in C# VSTO and Excel 2007 but thought I'd ask how to do

this in
VBA and maybe it would help with the C# code.

I just want to copy a shape (textbox) with all of its text and

formating
(e.g., Bold, no fill, no line). And paste it multiple times down the

page
(via a loop), actually to a different workbook.

I've tried shape.copy but don't know how to paste it where I want

it.
I've tried shape.duplicate but can't get that to work either.

Much thanks for ideas.

Mark




Hello Mark,

"Shapes" is a very broad class. It would save a lot of time if we knew
which of three types of text boxes you wanted to copy: HTML, Forms, or
Control Toolbox.


--
Leith Ross

Sincerely,
Leith Ross

'The Code Cage' (http://www.thecodecage.com/)
------------------------------------------------------------------------
Leith Ross's Profile: http://www.thecodecage.com/forumz/member.php?userid=75
View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=57318


 
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
Place formatted Text in Shape(textbox) StevenD72 via OfficeKB.com Excel Programming 2 September 10th 08 07:38 PM
Cutting and Pasting Cells into a shape or textbox Gator Excel Discussion (Misc queries) 4 July 14th 08 08:21 PM
set color of textbox (shape) bullets Pat D[_2_] Excel Programming 6 March 21st 08 10:17 AM
Textbox - Shape Jarle Excel Programming 2 February 22nd 08 09:54 PM
Editting textbox value that is grouped with a shape David Cuthill[_2_] Excel Programming 5 June 1st 04 06:39 PM


All times are GMT +1. The time now is 10:26 PM.

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"