How to add/display Hyperlink of folder/file in the App Designer?
8 views (last 30 days)
Show older comments
I'm building app in App Designer. i want to display/add Hyperlink to a folder or specific file from my PC.
I look and found something that works in standard matlab. when i tried to display it in my app, i see only the text itself and not link.
see code:
folder = uigetdir();
disp(['','<a href = "matlab: [s,r] = system(''explorer ',folder,' &'');">',folder,'</a>','']);
this code in the command line, shows hyper link (see picture 1.jpg)

but in my app, it shows as text (see picture 2.jpg)

can someone show me how to add in the app designer hyperlink?
the next step will be to know how to connect the hyperlink to an image...
Best Regards
0 Comments
Answers (1)
Jayanti
on 18 Dec 2024
Hi Gili,
To add hyperlink, you can use “web” function.
web(url)
This will open the page specified by “url” in a web browser.
And for release MATLAB R2021a or later, “uihyperlink” function can be used alternatively.
fig = uifigure;
hlink = uihyperlink(fig);
hlink.Text = " https://www.mathworks.com/";
hlink.URL = "https://www.mathworks.com/";
The above code will create a hyperlink component.
Please refer to below documentation links on “web” and “uihyperlink” for your reference.
Hope this is useful!
0 Comments
See Also
Categories
Find more on Migrate GUIDE Apps in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!