Free Support Forum - aspose.com

Generate Text with Hyperlink to another Slide

Hi,

is there a possibility to add a hyperlink to a textframe to another slide with apose.slides?

best regards,
Oliver Kuntke

I found the solution myself :
public void SetInternalHyperlink(Slide);


Hi,

Thats good.

I got another problem now.

i want to go through a powerpoint table an want to add a link to all cells to a slide.
My code only adds a link to the last row of the table.

for (int i = 0; i < toc.Count; i++)
{
TextFrame tf = tblToc.GetCell(column, row).cell.TextFrame;
TocEntry[] tocArray = (TocEntry[])toc.ToArray(typeof(TocEntry));

if (tocArray[i].Title.IndexOf("[b]") > -1)
{
tf.Paragraphs[0].Portions[0].FontBold = true;
tf.Paragraphs[0].Portions[0].Text = (tocArray[i].Title).Replace("[b]", “”);
}
else
{
tf.Paragraphs[0].Portions[0].FontBold = false;
tf.Paragraphs[0].Portions[0].Text = tabSpaces + tocArray[i].Title;
}
tf.AddLink().SetInternalHyperlink(dstPres.GetSlideByPosition(Int32.Parse(tocArray[i].Page)-1).SlideId);
}

It seems to me that i can’t add a link to each textframe in each cell of a table

Hi,

There is no such issue. If you are using the evaluation version of Aspose.Slides for .NET, the columns that fall in the area of evaluation water mark don't hyperlink. So, there will be no issue in the licensed version.