Info

此问题已关闭。 请重新打开它进行编辑或回答。

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

1 次查看(过去 30 天)
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?

回答(0 个)

此问题已关闭。

Community Treasure Hunt

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

Start Hunting!

Translated by