Showing Page

I seem to be having a issue loading a page. I have a login page with which the user logs in and it works fine.

I have a link on a page after the login that when clicked calls another page like so:

Dim myreportlist As New ReportListing myreportlist.Show

Most of the time it seems to kick me back to the login page but other times will load the page ok. The open event of the page that is suppose to open has some code for loading data from a db to a listbox.

I have debugged and all and cannot pinpoint what causes the link click to push me back to the login page.

Any ideas on what I could do to diagnose this?


I would say there’s something on your page that is closing it. Thus it’s going back to the login page.

How to diagnose: Start commenting out all the code in the ReportListing page until it stops and then you’ll find the culprit.

FWIW, the Page.Open event is not a great place to load data. The Shown event is the better choice.

I tried the commenting out of code, actually moved it all to the show event and then comment out from there, reran it it multiple times and it still will kick me back to the login screen even though there is no code associated with the loading of the page.

This is troubling and not sure where else to look?


Try opening another page instead, perhaps a blank one, and see if the login page is coming up still. Something else must be calling the login page.

The behavior is bizarre but I’m sure there is a good reason.

Unless it’s this.

The only thing I have for my login page is that its the default page upon starting. Other than that its not called elsewhere at all.

Even just adding a blank page and calling that instead of my other page produces the same bizarre behavior.

Even setting a break point in the shown method for the page I am calling when this occurs it will not even get to that code at all. Its almost like some place under the hood the page is going to be shown yet never makes it and just goes back to the login page. This is rather scary as there seems to be no way to really diagnose what is happening. Basically I feel I am at the mercy of the framework or something.

Is this something you can share? I’ll be happy to take a look at it. Send your project to support at bkeeney dot com.

So when I run your project it sits at the Report Listing page and doesn’t log out. I tried in 2012 R4 and 2014 R1 B3

After some back and forth on this issue having had some help from Bob Keeney I was able to resolve this issue by deleting the cache folder for xojo and restarting my mac. On the mac the folder is at ~user/Library/Caches/Xojo. Not sure where where it is for Win/Linux.

Thanks Bob.

Glad I could help. I need to write up a blog post on the “What to do if you think you’re either bat shit crazy or Xojo has a major bug in the framework” scenario.