Replace sticky note icon

273 views
Skip to first unread message

Linker IT

unread,
Mar 1, 2017, 8:30:31 PM3/1/17
to PDFTron PDFNet SDK
Hi,

I am looking to change the default icon I get when adding sticky notes
via code to the PDF. Currently I am using this function:

private async void SetBitmapSource(WriteableBitmap imageBitmap)
{
Windows.Storage.StorageFile file = await
Windows.Storage.StorageFile.GetFileFromApplicationUriAsync(new
Uri("ms-appx:///MyProject/MyStickyNote.png"));
using (Windows.Storage.Streams.IRandomAccessStream
fileStream = await
file.OpenAsync(Windows.Storage.FileAccessMode.Read))
{
try
{
await imageBitmap.SetSourceAsync(fileStream);
}
catch (TaskCanceledException)
{
// The async action to set the WriteableBitmap's
source may be canceled if the source is changed again while the action
is in progress
}
}
}


But it does not work. Is there any chance?

Thanks,

Ryan

unread,
Mar 2, 2017, 2:19:23 PM3/2/17
to PDFTron PDFNet SDK
This post shows how to customize the appearance of any annotation.
Reply all
Reply to author
Forward
0 new messages