Pdf Viewer LoadDocument doesn't work
I'm trying to display simply a PDF document with SfPdfViewerControl,
but LoadDocument method throws an exception and I don't know why, because I just copied and pasted the example from sample.
Here's my code:
var picker = new FileOpenPicker();
picker.SuggestedStartLocation = PickerLocationId.DocumentsLibrary;
picker.ViewMode = PickerViewMode.List;
picker.FileTypeFilter.Add(".pdf");
var filetest = await picker.PickSingleFileAsync();
var stream = await filetest.OpenAsync(Windows.Storage.FileAccessMode.Read);
Stream fileStream = stream.AsStreamForRead();
byte[] buffer = new byte[fileStream.Length];
fileStream.Read(buffer, 0, buffer.Length);
PdfLoadedDocument ldoc = new PdfLoadedDocument(buffer);
await pdfViewer.LoadDocumentAsync(ldoc); // Here is thrown an exception
The thrown exception's message is:
Object reference not set to an instance of an object.
Could somebody help me to find the solution?
Thanks very much.
Hi Oh,
Thank you
for your interest in Syncfusion products.
We are not
able to reproduce the issue “Null reference exception is thrown when using
LoadDocumentAsync method”. We tried with the sample available in the link
below, but threading exception occurs in the Viewer when using
LoadDocumentAsync method. We have logged an issue report for fixing this issue,
the fix for this issue will be available in our upcoming release.
Sample Link:
GappTestPdfViewer_LoadAsync.zip
Please let
us know if you have any concerns.
Thanks,
Suresh
I also facing same exception in Load Document. please tell me what the solution for this. I purchased license for this control.
Demo App for Pdfviewer_e4e90bea.rar
Thanks your reply! I already attached a demo app with my previous post. please find the attachment.
And one more question,
I am creating invoices as word document and excel document, I am not able to display image on these document at run time. Image is different for each invoice in both cases.
I am generating my invoice details for both format using template.
Hi Sandeep,
Thank you
for your response.
We are able
to reproduce the issue with the sample provided, the fix for this issue will be
available in our refresh release for WinRT and this is expected to be available
in the end of this week.
Regarding
the query about creating the invoice in Word and Excel, please follow the
solution for this in the forum
http://www.syncfusion.com/support/forums/metrostudio/109644
Please let
us know if you have any concerns.
Thanks,
Suresh
Hi Emi
The
issue LoadDocumentAsync method is fixed in our service pack. We are glad to
announce that our Essential Studio Vol 2 service pack 2013 is rolled out and is
available for download under the following link.
We thank
you for your support and appreciate your patience in waiting for this release.
Please get in touch with us if you would require any further assistance.
Regards,
Suresh
Thanks for your help. Can you tell me how to upgrade our syncfusion winrt? I already have purchased this.
And again thanks for given me a sample for display image in word and excel document.
And I have one more question for you. In my another app I am using
<editors:TextBoxExt x:Name="cmb_AC_ID" SearchItemPath="AC_ID" SuggestionPopupClosed="cmb_AC_ID_SuggestionPopupClosed"
Watermark="" FontSize="13" SuggestionMode="StartsWith" AutoCompleteMode="Suggest"/>
In this control, when I open this page in edit mode, This control filled with value but that seems to get stuck in the ON position.
I have attached a screenshot for you better understanding.pls find attachment. see Aircraft Type field in this screenshot.
Untitled_4cb44fa6.rar
Hi Sandeep,
Thank you for your reponse,
Regarding
Upgradation:
Whenever you upgrade to newer version it is not necessary to
uninstall the older version because Syncfusion supports multiple versions to be
installed in the same machine. So, you can install the latest version Essential
Studio WINRT(XAML) setup with the respective version unlock key as you wish.
Regarding issue
with SfTextBoxExt control
We
are unable to reproduce the reported SfTextBoxExt gets stuck in the ON position
issue. Please find the sample used for replication from the following location,
http://www.syncfusion.com/downloads/Support/DirectTrac/General/AutoCompleteSample-743188818.zip
Please
modify the sample to reproduce the issue or provide us more information to
assist you further with accurate solution.
Please
let us know if you have any concerns.
Thanks,
Suresh
Thanks for ur support. and also so much thanks for your reply of each questions.
Now I modified ur sample (AutoCompleteSample) and reproduc the same error which occurs at my end. pls find the attachment.
In this I filled this by country list and suppose I want "USA" selected by default or any other.
Waiting for your reply.
AutoCompleteSample_1c10661.rar
Can I make my app with this version of control for windows store without purchasing it ?
Or have to purchase ?
But your latest version of sync fusion is not free.
I want to ask you, your sync fusion latest update is free of cost on not? like beeta version.
- 18 Replies
- 5 Participants
-
OH OH
- May 27, 2013 02:26 PM UTC
- Aug 22, 2013 09:28 AM UTC