Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6657565
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T01:47:02+00:00 2026-05-26T01:47:02+00:00

I have a text box contain links .the contents in the text are generated

  • 0

I have a text box contain links .the contents in the text are generated during run time.My problem is that the links inside the text is not clickable,how can make all links inside the text block clickable so that when i tap a link it should open the web browser.In android we can set it by using autolink.Is such option is available in wp7 or in wp7.1 mango?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T01:47:03+00:00Added an answer on May 26, 2026 at 1:47 am

    Use a HyperLink.

    <TextBlock>
        <Run>Pure Text</Run>
        <Hyperlink Command="{Binding HyperLinkTapped}">http://google.com</Hyperlink>
        <Run>Pure Text Again</Run>
    </TextBlock>
    

    This is supported from Windows Phone 7.1 (Mango).

    You can create your own FlowDocument from the your data, at runtime, if necessary.

    Example on how to generate a FlowDocument from a string:

    private void OnMessageReceived(string message)
    {
        var textBlock = new RichTextBox()
        {
            TextWrapping = TextWrapping.Wrap,
            IsReadOnly = true,
        };
    
        var paragraph = new Paragraph();
    
        var runs = new List<Inline>();
    
        foreach (var word in message.Split(' '))
        {
            Uri uri;
    
            if (Uri.TryCreate(word, UriKind.Absolute, out uri) ||
               (word.StartsWith("www.") && Uri.TryCreate("http://" + word, UriKind.Absolute, out uri)))
            {
                var link = new Hyperlink();
                link.Inlines.Add(new Run() { Text = word });
                link.Click += (sender, e) =>
                {
                    var hyperLink = (sender as Hyperlink);
                    new WebBrowserTask() { Uri = uri }.Show();
                };
    
                runs.Add(link);
            }
            else
            {
                runs.Add(new Run() { Text = word });
            }
    
            runs.Add(new Run() { Text = " "});
        }
    
        foreach (var run in runs)
            paragraph.Inlines.Add(run);
    
        textBlock.Blocks.Add(paragraph);
    
        MessagesListBox.Children.Add(textBlock);
        MessagesListBox.UpdateLayout();
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a text box that contains lines of data similar to this: sheep
I have two links called Read More (bottom of code) that contain different values.
I have this html page which is very simple, it contains a text box
I have text box to enter a phone number. I'm using AJAX MaskedEditExtender and
I have text box in which your adds values in comma separated values. Once
i have form where i have text box value and link (add). when user
I have a text-box into which a user can input a comment. The comment
I have 9000 PHP files , most of which contain the text foo .
I have a list of links, and I have this search box #reportname. When
I have a text field that is editable by the user and it contains

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.