- Posts: 8
- Thank you received: 0
Microsoft Windows Phone 8.1 support ends (13 Jul 2017)
Microsoft has ended support for Windows Phone 8.1
Questions about Android development and PDF
How to pass a asset file path in PDFReaderAct
- biplab2014
- Topic Author
- Offline
- New Member
-
Less
More
IP: 192.168.0.71
11 years 9 months ago #6363
by biplab2014
How to pass a asset file path in PDFReaderAct was created by biplab2014
Hi,
I want to get all the action is there in PDFReaderAct class. So how to pass a path for a pdf which is in android asset folder.
I want to get all the action is there in PDFReaderAct class. So how to pass a path for a pdf which is in android asset folder.
IP: 192.168.0.71
11 years 9 months ago #6364
by radaee
Replied by radaee on topic How to pass a asset file path in PDFReaderAct
declare member like this:
private PDFAssetStream stream = new PDFAssetStream();
and then:
stream.open(getAssets(), "test.PDF");
int ret = doc.OpenStream(stream, null);
switch( ret ) ...
when document closed, you shall:
if( stream != null )
{
stream.close();
stream = null;
}
private PDFAssetStream stream = new PDFAssetStream();
and then:
stream.open(getAssets(), "test.PDF");
int ret = doc.OpenStream(stream, null);
switch( ret ) ...
when document closed, you shall:
if( stream != null )
{
stream.close();
stream = null;
}
- biplab2014
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 8
- Thank you received: 0
IP: 192.168.0.71
11 years 9 months ago #6365
by biplab2014
Replied by biplab2014 on topic How to pass a asset file path in PDFReaderAct
this is not working. Crashing the application. Can i get the hole code with same function which is available in PDFReaderAct.
IP: 192.168.0.71
11 years 1 month ago - 11 years 1 month ago #8365
by efren
Replied by efren on topic How to pass a asset file path in PDFReaderAct
someone has this solution....?
my app crash after I call
doc.OpenStream(stream, password);
Why this is happening...?
If I open the same PDF from sdcard, it open normally
my app crash after I call
doc.OpenStream(stream, password);
Why this is happening...?
If I open the same PDF from sdcard, it open normally
Last edit: 11 years 1 month ago by efren.
Time to create page: 0.394 seconds