Gets or sets the full hyperlink address for a shape.
[Visual Basic]Public Property HRef As
String [C#]public
string HRef {get; set;}
Remarks
The default value is an empty string.
Below are examples of valid values for this property:
Full URI: http://www.aspose.com/.
Full file name: C:\\My Documents\\SalesReport.doc.
Relative URI: ../../../resource.txt
Relative file name: ..\\My Documents\\SalesReport.doc.
Bookmark within another document: http://www.aspose.com/Products/Default.aspx#Suites
Bookmark within this document: #BookmakName.
Example
Shows how to insert an image with a hyperlink.
[C#]
// This creates a builder and also an empty document inside the builder.
DocumentBuilder builder = new DocumentBuilder();
Shape shape = builder.InsertImage(MyDir + "Hammer.wmf");
shape.HRef = "http://www.aspose.com/Community/Forums/75/ShowForum.aspx";
shape.ScreenTip = "Aspose.Words Support Forums";
builder.Document.Save(MyDir + "Image.InsertImageWithHyperlink Out.doc");
[Visual Basic]
' This creates a builder and also an empty document inside the builder.
Dim builder As DocumentBuilder = New DocumentBuilder()
Dim shape As Shape = builder.InsertImage(MyDir & "Hammer.wmf")
shape.HRef = "http://www.aspose.com/Community/Forums/75/ShowForum.aspx"
shape.ScreenTip = "Aspose.Words Support Forums"
builder.Document.Save(MyDir & "Image.InsertImageWithHyperlink Out.doc")
See Also
ShapeBase Class | Aspose.Words.Drawing Namespace