Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 287
Default Combine Strings into One String

I need to create a bookmark into Word, but I have all these strings. Is there
a method to combine these strings into one string; however have each string
as a paragraph??

Example Code:
String1 = "All Preparation Work as Stated Above"
x.Selection.TypeText String1 & vbCr

String2 = Worksheets("Bid").Cells(1, 15).Value & " : " & "Apply " &
Worksheets("Bid").Cells(i, 15).Value & " coats interior flat latex paint of
highest quality"
x.Selection.TypeText String2 & vbCr

String3 = Worksheets("Bid").Cells(1, 20).Value & " : " & "Apply " &
Worksheets("Bid").Cells(i, 20).Value & " coats interior flat latex paint of
highest quality"
x.Selection.TypeText String3 & vbCr

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 863
Default Combine Strings into One String

Have you posted in the Word VBA/programming group?

On Tue, 8 Mar 2005 18:11:02 -0800, "Adam"
wrote:

I need to create a bookmark into Word, but I have all these strings. Is there
a method to combine these strings into one string; however have each string
as a paragraph??

Example Code:
String1 = "All Preparation Work as Stated Above"
x.Selection.TypeText String1 & vbCr

String2 = Worksheets("Bid").Cells(1, 15).Value & " : " & "Apply " &
Worksheets("Bid").Cells(i, 15).Value & " coats interior flat latex paint of
highest quality"
x.Selection.TypeText String2 & vbCr

String3 = Worksheets("Bid").Cells(1, 20).Value & " : " & "Apply " &
Worksheets("Bid").Cells(i, 20).Value & " coats interior flat latex paint of
highest quality"
x.Selection.TypeText String3 & vbCr

Thanks


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Combine Strings into One String

Adam
String1 =String1 & NextLotOfTextWithOrWithoutvbCr

x.Selection.TypeText String1

NickHK

"Adam" wrote in message
...
I need to create a bookmark into Word, but I have all these strings. Is

there
a method to combine these strings into one string; however have each

string
as a paragraph??

Example Code:
String1 = "All Preparation Work as Stated Above"
x.Selection.TypeText String1 & vbCr

String2 = Worksheets("Bid").Cells(1, 15).Value & " : " & "Apply " &
Worksheets("Bid").Cells(i, 15).Value & " coats interior flat latex paint

of
highest quality"
x.Selection.TypeText String2 & vbCr

String3 = Worksheets("Bid").Cells(1, 20).Value & " : " & "Apply " &
Worksheets("Bid").Cells(i, 20).Value & " coats interior flat latex paint

of
highest quality"
x.Selection.TypeText String3 & vbCr

Thanks



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 400
Default Combine Strings into One String

Use x.Selection.TypeParagraph instead of x.Selection.TypeText; also, send
each string separately to Word.

"Adam" wrote:

I need to create a bookmark into Word, but I have all these strings. Is there
a method to combine these strings into one string; however have each string
as a paragraph??

Example Code:
String1 = "All Preparation Work as Stated Above"
x.Selection.TypeText String1 & vbCr

String2 = Worksheets("Bid").Cells(1, 15).Value & " : " & "Apply " &
Worksheets("Bid").Cells(i, 15).Value & " coats interior flat latex paint of
highest quality"
x.Selection.TypeText String2 & vbCr

String3 = Worksheets("Bid").Cells(1, 20).Value & " : " & "Apply " &
Worksheets("Bid").Cells(i, 20).Value & " coats interior flat latex paint of
highest quality"
x.Selection.TypeText String3 & vbCr

Thanks

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
Combine strings and numbers Alain Dekker Excel Discussion (Misc queries) 6 February 21st 10 08:51 PM
Finding 1 of 3 different strings in a string MarkMcG Excel Worksheet Functions 3 June 10th 08 05:55 PM
Colomn of strings, how to count each string with "abc" OR "def" Tommy T Excel Worksheet Functions 8 September 5th 05 04:57 PM
Seperating 1 String into Many strings! Chip Pearson Excel Programming 0 September 2nd 04 08:03 PM
Seperating 1 String into Many strings! Don Guillett[_4_] Excel Programming 0 September 2nd 04 08:00 PM


All times are GMT +1. The time now is 12:51 AM.

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"