Filter löschen
Filter löschen

Info

Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.

Mapping toolbox and wmmarker: why doesn't the html link open its target file?

1 Ansicht (letzte 30 Tage)
Espen Donali
Espen Donali am 5 Dez. 2019
Geschlossen: MATLAB Answer Bot am 20 Aug. 2021
The function wmmarker in the Mapping toolbox can be used to set markers on a web map.
A marker made this way can be clicked to pop up a label window with text, where some of the text can be hyperlinks. In my case the hyper link is pointing to a local image file on my computer: \myImages\myImage.jpg.
My problem is that the hyper link does not open the file when used in the wmmarker function. The hyper link is defined in the html string markerDescr defined below.
close all
webmap('World Imagery');
markerName = 'ST01';
markerDescr = '<a href="matlab: winopen(''myFigures\minFigur.jpg'')">CLICKY</a>';
lat = 69.601142;
lon = 30.025769;
color = [0, 1, 0];
wmmarker(lat,lon,...
'FeatureName',markerName,...
'Description',markerDescr,...
'Color',color,...
'AutoFit',true);
However, if I execute the html variable (markerDescr) in the command window, the link produced will open my image file when clicked.
Why doesn't my html string work in wmmarker, but still work in the command window?
Do I have to change the html string to make it work in the wmmarker?

Antworten (0)

Diese Frage ist geschlossen.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by