Select to view content in your preferred language

Adding html link to AddMesage

809
4
02-09-2012 03:04 PM
PhilWilkes
New Contributor
Hello,

I would like to add an html link to a message that appears in the dialog box.

import arcpy
p2s = '-- For more info click <!!HTML_LINK!!> --'
arcpy.AddMessage(p2s)


Is this possible? When a geoprocessing error occurs there is a link to error description so it seems possible!

Thanks

Phil
Tags (2)
4 Replies
JasonScheirer
Regular Contributor II
This is not possible.
0 Kudos
StacyRendall1
Occasional Contributor III
You could just write the link out explicitly, and then the user could copy and paste it to their browser...
0 Kudos
PhilWilkes
New Contributor
Hi, thanks for your post Stacey. This would work but could look untidy, I was hoping for a way of adding a <a href="url">link</a> type html link! I think Jasons reply is the right answer...
0 Kudos
ChrisSnyder
Regular Contributor III
How about an automatic "pop up" upon failure?

import subprocess
subprocess.Popen('"C:\\Program Files\\Internet Explorer\\iexplore.exe" http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#/000001_Angle_should_be_greater_than_0_and_less_than_180/00vp00000002000001/')


There's some other ways too: http://stackoverflow.com/questions/1532884/open-ie-browser-window