Tech
Forums
Jobs
Books
Events
Videos
Live
More
Interviews
Certification
Training
Career
Members
News
Blogs
Contribute
An Article
A Blog
A Video
An Ebook
An Interview Question
Register
Login
1
Answer
Displaying Lines in separate message boxes
Muhammad Ali
7y
270
1
Reply
Hello everyone,
I am working on a UWP app. It consists of a multiline textbox. I want to display each of the line in a separate message box. I have tried the below code:
String[] lines = textBox.Text.Split(new char[] {'\n' }, StringSplitOptions.None);
foreach (string l in lines)
{
Windows.UI.Popups.MessageDialog dlg = new
Windows.UI.Popups.MessageDialog(l);
await dlg.ShowAsync();
}
But it is showing all the lines in a single texbox. And I also found that the Textbox.Lines property does not work in UWP. So kindly help me as how can I display each line in a Separate MessageBox.
Thanks.
Post
Reset
Cancel
Answers (
1
)
Next Recommended Forum
How to get value from two diffrent tables
Select a folder using OpenFileDialog folder