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: 85
Default Text Box - Moving Formatted Text

I am moving text from one textbox (from the drawing toolbar) on one sheet to
another textbox (on another sheet). I used these textboxes to allow for
copy/paste functionality, which I couldn't make work using the ControlToolbox
Textboxes . Anyway, when I move the data using the function below, It does
not move the formats (underline / bold) of the moved text. Any help would be
appreciated.

Thank you.

Sub moveit

Dim x1 As Integer
Dim Source1 As TextBox
Dim Target1 As TextBox
Dim Text1 As String

Set Source1 = sht1.DrawingObjects(1)
Set Target1 = sht2.DrawingObjects(1)

For x1 = 1 To Source1.Characters.Count Step 250

' Place the first text box text into a variable called theText.
Text1 = Source1.Characters(Start:=x1, Length:=250).Text

' Place the value of theText variable into second text box.
Target1.Characters(Start:=x1, Length:=250).Text = Text1

Next

End Sub
 
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
Moving text around cells without moving boarder lines Dale Excel Discussion (Misc queries) 1 December 15th 09 06:14 PM
Text in Text-formatted cells changes to ### after the 255th charac wildetudor Excel Discussion (Misc queries) 2 July 30th 09 03:20 PM
Moving a shape with text inside without editing text Dan Excel Programming 3 March 10th 07 11:33 PM
Dates formatted as text thekovinc Excel Discussion (Misc queries) 5 February 14th 06 06:49 PM
Converting 'General' formatted cells to Text formatted cell using. Zahid Khan Excel Worksheet Functions 1 March 12th 05 07:13 PM


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