Why App Won't Run

I click run button and it appears to compile and then seems to fail and close. Clicking ‘Build’ seems to make an app that doesn’t run. Tried disabling my AntiVirus.

How do I resolve this problem?

2015 R1
Windows 10

Thanks

Trying to run 64bit or 32bit?

64bit Windows 10 but it’s the old Xojo so it compiles to 32 bit.

I don’t care if Windows 10 is 64 bit. You are trying to run from the debugger which means your target needs to be 32bit.

Notice the first bullet in Current Known Issues:
http://developer.xojo.com/64-bit-guidelines

[quote=245208:@Bob Coleman]I don’t care if Windows 10 is 64 bit. You are trying to run from the debugger which means your target needs to be 32bit.

Notice the first bullet in Current Known Issues:
http://developer.xojo.com/64-bit-guidelines[/quote]
It’s a version of Xojo before 64-bit support. Thanks

Possibly project corruption? Try saving as binary, restart the IDE, reload the binary then try again.

place the word break on the very first line of your app.open event handler & try that.

And yet this is the most likely cause.
How many anti-virus tools do you have?
This is a classic example of Avast at work…

Does the compiled app work on a friend’s machine?

Wild goose chase if you ask me. Since we have absolutely no idea what the project is about and if it may contain code that simply crashes silently, any wild guess is good.

Does a simple “Hello World” program work on that machine with the same Xojo version ?

If it does not, uninstall Avast (pick your choice of pesky pest) or configure it to ignore your builds.

If it does work, what the heck is in the App.Open event or shortly after that crashes the project ? Any bizarre declares ? A few System.Debuglog can probably ascertain if the program indeed runs at all.

Last shot in the dark : is there a default window in App ?

[quote=245262:@Jeff Tullin]And yet this is the most likely cause.
How many anti-virus tools do you have?
This is a classic example of Avast at work…

Does the compiled app work on a friend’s machine?[/quote]
I use Avast.

[quote=245284:@Michel Bujardet]Wild goose chase if you ask me. Since we have absolutely no idea what the project is about and if it may contain code that simply crashes silently, any wild guess is good.

Does a simple “Hello World” program work on that machine with the same Xojo version ?

If it does not, uninstall Avast (pick your choice of pesky pest) or configure it to ignore your builds.

If it does work, what the heck is in the App.Open event or shortly after that crashes the project ? Any bizarre declares ? A few System.Debuglog can probably ascertain if the program indeed runs at all.

Last shot in the dark : is there a default window in App ?[/quote]
I’m going to have a look at this. And I am sorry for being vague. I was kind of needing suggestions such as what you gave me to help me think about how I am going to find the problem. When I get access to my PC, I am going to go through these suggestions and find what works. Hopefully, it’s just an issue with Avast.

Thanks

I have not used Avast in quite a while, but I know you can disable the feature that vets every new executable. There also may be a way to set it so it does not look at what happens within a given folder structure.

General Settings.

Their help page says this:

If it is Avast that is causing the trouble, its this Reputation Services option… it takes forever to go away and decide if your app is on its whitelist, and errs on the side of ‘If I dont know the name, I wont let it start’

Untick it.

Stupid question, but I do it once: Does your application display one window ?

If you forgot the default window, the application runs and quits…

Hi,
You can create method

Sub log(txt As String, Optional Title As String)
Soft Declare function OutputDebugString Lib “kernel32” Alias “OutputDebugStringA”(lpOutputString As CString) As Integer
Dim i As Integer = OutputDebugString(Title + ": " + txt)
End Sub

Download https://technet.microsoft.com/en-us/sysinternals/debugview
It’s for see kernel messages (I use it a lot )

Then put in App.Open something like log(“1”), Window.Open log(“2”) and so on. If you cannot see next number will give you idea of place of crash or quit.
There you can see some messages from Xojo too.

I don’t know if it is helpful for you

Regards,
Kris

System.debuglog basically does the same and you can view them using DebugView

System.debuglog displays just fine on DebugView. No need for any declare. But it won’t have a chance to display since Avast prevents the app from running entirely.

Seen this before https://forum.xojo.com/29087-avast-me-hearties-what-a-pain

I think the problem has something to do with spamming the System.DebugLog. I’m going to have a look at what could be causing issues. Thanks for all the suggestions.

It has to do with Dictionaries and using the Text type instead of the string type. Thanks for all the suggestions