Avatar of telliot79
telliot79
 asked on

passing formatted text from one textbox to another

Experts:

I'm passing the text from one textbox, to a textbox on a usercontrol I've created. if the original text is formatted in anyway, once I pass it to the user control I lose the formatting and receive only the text. What's the best way for me to pass the formatted text from one control to another?

here's a snippet of my  code:

textbox txtnotes = (textbox)myctrl.FindControl("txtRecievingNotes")

txtnotes.Text = txtPassingNotes.Text

Thanks in advance for the help,
ASP.NETC#.NET Programming

Avatar of undefined
Last Comment
telliot79

8/22/2022 - Mon
SOLUTION
Kyle Abrahams

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
David Johnson, CD

Text boxes don't contain formatting. Rich Text Boxes do..
telliot79

ASKER
Sorry, I should have been clearer - I'm talking about line breaks, bullet points, tabs, etc.

when I populate the text from one control to the other, it just comes through as one long string of text and ignores the tabs and line breaks I've created.
SOLUTION
Kyle Abrahams

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
telliot79

ASKER
I'm just copy and pasting from word into the text box. it's asp.net and just an asp.net textbox control. the spacing is really the problem.
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck
ASKER CERTIFIED SOLUTION
telliot79

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
telliot79

ASKER
Thanks Kyle. your answers helped me understand my problem and find a solution.