Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 09-26-2021, 02:40 PM
trevorc trevorc is offline vba coding for CrLf in text Windows 7 32bit vba coding for CrLf in text Office 2013
Competent Performer
vba coding for CrLf in text
 
Join Date: Jan 2017
Posts: 174
trevorc will become famous soon enoughtrevorc will become famous soon enough
Default vba coding for CrLf in text

Hi All,


How can i code for the addition of an Alt-Enter in the middle of text?

I have a table with header rows, some have 2 words in them, after doing an Alt-Enter to put the second word below the first and then centering the text in the field my VBA code no longer sees the field

Sheets("Docket").Range("V" & OFF_SET) = Intersect(ActiveCell.EntireRow, tblColumns("Serial Number").Range)

I know it's something like "Serial" & VbCrLf & "Number"but can't figure it out.

Any help would be appriciated

regards
Trevor
Reply With Quote
  #2  
Old 09-26-2021, 04:18 PM
Logit Logit is offline vba coding for CrLf in text Windows 10 vba coding for CrLf in text Office 2007
Expert
 
Join Date: Jan 2017
Posts: 529
Logit is a jewel in the roughLogit is a jewel in the roughLogit is a jewel in the rough
Default

The following works here :

Code:
Option Explicit

Sub InsertLineFeed()
    Range("A1").Value = "Serial" & vbCrLf & "Number"
End Sub
Reply With Quote
  #3  
Old 09-26-2021, 06:26 PM
trevorc trevorc is offline vba coding for CrLf in text Windows 7 32bit vba coding for CrLf in text Office 2013
Competent Performer
vba coding for CrLf in text
 
Join Date: Jan 2017
Posts: 174
trevorc will become famous soon enoughtrevorc will become famous soon enough
Default

Thanks for that. new it was an easy one just forgot the syntax for it.
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
vba coding for CrLf in text Help on separate a single text cell into multi cells by coding Yasso Excel Programming 1 12-01-2015 05:45 PM
VBA coding for multiple drop-down lists to populate a text box for each list yeatropulo Word VBA 14 11-11-2015 01:08 PM
What kind of coding? ep2002 Excel 3 07-22-2014 07:52 AM
vba coding for CrLf in text text becomes pages of these *** and then coding EkkoJohnny Word 1 11-22-2013 12:37 AM
vba coding for CrLf in text Converting data-table into coding text niuri_cigarete Excel 2 12-10-2011 02:57 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 01:24 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft