• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Fourth link

 
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I created a button to take me to another page and in that other page, there is another button that takes to another page, and another button to another page, so page1, page2, page3 and page 4 that is not working! This is a picture to see http://oi58.tinypic.com/10zty80.jpg .. when I click on "Fish guide" it takes me to the other one which has another button "Fish", when I click on "Fish" it takes me another page with "Arabian angelfile", when I click on it, it doesn't take me to another page i.e. page 4
File attached
 
sasa anali
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
File not attached?
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Not sure what kind of file you were trying to attach, but you can only attach images.

You can post relevant excerpts of your code right here; https://coderanch.com/how-to/java/UseCodeTags for that.
 
sasa anali
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
activity_main.xml (to show "Fish guide")



fishguide.xml (to show "Fish")



fish.xml (to show "Arabian angelfish")



arabianangelfish.xml (to show about the "Arabian angelfish" (it doesn't show))



MainActivity.java (for "fishguide.xml")



PageThree.java (for "fishguide.xml")



MainActivity2.java (for fish.xml)



PageFish.java (for fish.xml)



Here is the things I added but it doesn't go to the fourth button link

MainActivity3.java



PageFishLast.java



PageArabianangelfishies.java

 
Bartender
Posts: 4179
22
IntelliJ IDE Python Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You have a MainActivity which uses the activity_main.xml file and adds a click listener to the button:

This brings you to PageThree, which uses fishguide.xml, and adds a click listener to the button:

This brings you to PageFish which uses fish.xml, and doesn't do anything:


You need to make that third activity add a click listener to a button to direct to the fourth page.

You also have a handful of other Activities (MainActivity2, and MainActivity3, and PageFishLast) which use the same layouts but aren't actually displayed, you should get rid of them since they serve only to confuse.
 
sasa anali
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I got confused putting these 3 codes, but, can you please type the code for the 4th page? I mixed between what to add to it! Where even!
 
Steve Luke
Bartender
Posts: 4179
22
IntelliJ IDE Python Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

sasa anali wrote:I got confused putting these 3 codes, but, can you please type the code for the 4th page? I mixed between what to add to it! Where even!


Nope, I won't do your work for you. You have the code you need in the other two activities you use, and you have two activities you aren't using which you posted which has the exact code you need. You just need to put it in the correct place. And if I just post code for you to copy and paste, you won't learn where the correct place is yourself, so it would be a fruitless exercise.

So give it a try. Read my post, find the code, put it in the correct spot. Show us the results and we can help you fine tune it.
 
sasa anali
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I did check it and I'll check it again, I'll tell you what happens .. then I need more time .. thank you!
 
sasa anali
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Just in case, this is the file that I should add things to


 
sasa anali
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Steve, it worked

PageFish.java
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic