- Posts: 69
- 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 show pdfnav.xml(PDFNavAct) file in my app ?
- rachnasagar
- Topic Author
- Offline
- Senior Member
-
Less
More
9 years 7 months ago #11807
by rachnasagar
Replied by rachnasagar on topic How to show pdfnav.xml(PDFNavAct) file in my app ?
I know that ...
I want to call my apps activity in your viewlib.
When I am using
startActivity(new Intent(PDFNavAct.this,com.rachnasagar.MainActivity.class));--- I have to call this in your lib activity and its not working .
Because I have to go back to my Mainactivity.
com.rachnasagar cannot be resolved to a type
I want to call my apps activity in your viewlib.
When I am using
startActivity(new Intent(PDFNavAct.this,com.rachnasagar.MainActivity.class));--- I have to call this in your lib activity and its not working .
Because I have to go back to my Mainactivity.
com.rachnasagar cannot be resolved to a type
- rachnasagar
- Topic Author
- Offline
- Senior Member
-
Less
More
- Posts: 69
- Thank you received: 0
9 years 7 months ago #11812
by rachnasagar
Replied by rachnasagar on topic How to show pdfnav.xml(PDFNavAct) file in my app ?
See...
I have my project A in which I have used the library ViewLib .
In Viewlib (libraray) there is an activity name PDFNavAct.
I need to implement that when I back press in PDFNavAct activity, then it close and open my project A Mainactivity..
For this I wants to implement this method in PDFNavAct activity
@Override
public void onBackPressed() {
super.onBackPressed();
startActivity(new Intent(getApplicationContext(),com.example..Mainactivity));
this.finish();
}
But it is not working ...
Can you please tell me the solution for it , so that I will press back and I com to my home activity i.e Mainactivity.
I have my project A in which I have used the library ViewLib .
In Viewlib (libraray) there is an activity name PDFNavAct.
I need to implement that when I back press in PDFNavAct activity, then it close and open my project A Mainactivity..
For this I wants to implement this method in PDFNavAct activity
@Override
public void onBackPressed() {
super.onBackPressed();
startActivity(new Intent(getApplicationContext(),com.example..Mainactivity));
this.finish();
}
But it is not working ...
Can you please tell me the solution for it , so that I will press back and I com to my home activity i.e Mainactivity.
9 years 7 months ago #11825
by Davide
Replied by Davide on topic How to show pdfnav.xml(PDFNavAct) file in my app ?
Hi,
if your MainActivity is the caller activity you don't have to override the onBackPressed method, when you tap the back button the PDFNavAct will be closed as default Android activity behavior.
Make sure not to call finish in your MainActivity after starting PDFNavAct.
if your MainActivity is the caller activity you don't have to override the onBackPressed method, when you tap the back button the PDFNavAct will be closed as default Android activity behavior.
Make sure not to call finish in your MainActivity after starting PDFNavAct.
Time to create page: 0.356 seconds