web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

How to set a hyperlink for a field?

(0) ShareShare
ReportReport
Posted on by 931

Hi,

VendTable has URL field with vendor URL's.

My requirement is i have to select a record from the grid and the selected record URL field should display in the next HTML tab with a hyperlink. So far i did display the selected record URL field to next tab, but i need that as a hyperlink. Please Help!

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Martin Dráb Profile Picture
    238,745 Most Valuable Professional on at

    Do I understand correctly that by "to display URL" you mean showing a hyperlink that users can click on?

    Then why don't you simply use a button with Style = Link?

  • ThivaKar Profile Picture
    931 on at

    As i said , i need the hyperlink on the HTML tabpage . After i select the record from the grid, selected record 'field'(URL from VendTable) should display as a hyperplink that users click on.

  • Suggested answer
    Vilmos Kintera Profile Picture
    46,149 on at

    Check AOT > Forms > tutorial_Form_Controls, on the HTML tab you have a hyperlink. That is a HTML control, which they populate in the run method like this:

    void run()
    {
        Html.setText(  "<html><body>" +
                        "<h3>The HTML Viewer/Editor</h3>" +
                        "<p>The HTML Control can Show and Edit HTML text.<p>" +
                        "<p>It supports images and <a href=www.microsoft.com/BusinessSolutions&gt;hyperlinks</a>" +
                        "</body></html>");
        super();
    }
  • Martin Dráb Profile Picture
    238,745 Most Valuable Professional on at

    Well, if you insist on the more complicated way, you surely can provide HTML code for the HTML control. I see that Vilmos already gave you an example.

  • ThivaKar Profile Picture
    931 on at

    Hello Vilmos , Thank You for the reply..

    In the <a href> how can i set the URL field , if u have read my requirement stated above, the selected record should come in the hyperlink .

    How can i make this possible ? i.e(<a href == (selected record 'field')>)

  • Verified answer
    Vilmos Kintera Profile Picture
    46,149 on at

    You could use stringformat, point to the record buffer of your vendor datasource, and write it to the HTML control in the active() method of the datasource. That will refresh the control whenever a new row is selected.

    strFmt('<a href=%1>Vendor URL</a>', VendTable.YourURLfield)

  • ThivaKar Profile Picture
    931 on at

    Thank you Vilmos. Worked Perfectly !

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Sagar Suman Profile Picture

Sagar Suman 2 Super User 2026 Season 1

#1
Alexey Lekanov Profile Picture

Alexey Lekanov 2

#1
Pratik Bhosle Profile Picture

Pratik Bhosle 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans