App on IOS will crash on black screen

I need help! :frowning:

im sorry for the english!

in simulator and android device everything going well, but when i charge my app on my tablet with ios7 the app (in random time after it started) seems to go in standby whit a black screen…

the app didn’t really crash, in fact if i go exit without close it and reopen at the same status the app continue to work well from the status that it went in standby…

i hope someone can help me

thanks

You need to look for errors in your console log.  There is not enough information here to go on.  If you do not know how to read the console log for iOS apps, please read this tutorial:

http://coronalabs.com/blog/2013/07/09/tutorial-basic-debugging/

I saw it…
No error appears…

What version of Corona SDK are you running?

What device are you testing on?

What operating system is the device running?

Are you looking for any warnings?  There has to be something in the log file that indicates what is going on.  Most of the time this is a filename case sensitivity issue, but there should be a message.

it seems to work now… buh!  :huh:

I am also getting black screens with the latest builds. I have 4 storyboard scenes. There are two that turn black when entering from any of the other two. When black, the screens still are responsive. They spring to live when I tap on a spot where I know there is a button. Switching between these two (failing) screens do NOT turn them black. It’s only when switching from any of the other screens. To illustrate, let’s call the screens A, B, C and D. (B and C are the ones that turn black). I have an Overlay scene menu with four buttons that are used to switch between screens.

From A to B: B turns black.

From A to C: C turns black.

From A to D: – no problem.

From B to A: – no problem.

From B to D: – no problem.

From B to C: – no problem.

From C to A: – no problem.

From C to B: – no problem.

From C to D: – no problem.

From D to A: – no problem.

From D to B: B turns black.

From D to C: C turns black.

The console log does’t report anything at all. I have spent hours trying to find out what could possibly trigger the sudden black screens, but can’t find anything. I checked colors, positions, widget options, etc. There are no obvious errors in my code. I never saw black screens using the pre-2000 builds. The builds with the problem that I have downloaded and used are 2076, 2100 and 2239.

I am using 16GB Retina iPad, iOS version 7.1.

There must be some condition coming from screens A and D that cause a problem on screens B and C, but what?

All four scenes have virtually the same basic enterScene and exitScene events:

[lua]

function scene:enterScene(event)
    group.alpha = 1
    storyboard.purgeAll()
    storyboard.showOverlay( “menu” )
end

function scene:exitScene(event)

end
[/lua]

I am now going through a process of elimination, commenting out blocks of code, building and testing… hoping to stumble upon a solution.

_ Follow up: _ The native.newTextField was central to the “black screen” issue in my case. Specifically, I had various text fields inserted in a container. The Corona documentation warns against this. Not inserting the native textfields made the black screen problem go away. The textfields are on my scenes A and D. Since switching between scenes is essential in my app, I had to set these fields to .isVisible = false in the exitScene events and make them visible again in the enterScene events.

But there was still another black screen issue, in a separate scene which is a login screen. Here I had loginName.removeSelf() in my code. That line caused a black screen too, even when the textfields were NOT in a container or group. I replaced the .removeSelf() with .isVisible = false and that solved the problem.

I hope this experience is useful for any fellow Corona coder that happens to get a black screen. :slight_smile:

It should be: loginName:removeSelf() note the colon instead of a period.

Hope this helps.

You need to look for errors in your console log.  There is not enough information here to go on.  If you do not know how to read the console log for iOS apps, please read this tutorial:

http://coronalabs.com/blog/2013/07/09/tutorial-basic-debugging/

I saw it…
No error appears…

What version of Corona SDK are you running?

What device are you testing on?

What operating system is the device running?

Are you looking for any warnings?  There has to be something in the log file that indicates what is going on.  Most of the time this is a filename case sensitivity issue, but there should be a message.

it seems to work now… buh!  :huh:

I am also getting black screens with the latest builds. I have 4 storyboard scenes. There are two that turn black when entering from any of the other two. When black, the screens still are responsive. They spring to live when I tap on a spot where I know there is a button. Switching between these two (failing) screens do NOT turn them black. It’s only when switching from any of the other screens. To illustrate, let’s call the screens A, B, C and D. (B and C are the ones that turn black). I have an Overlay scene menu with four buttons that are used to switch between screens.

From A to B: B turns black.

From A to C: C turns black.

From A to D: – no problem.

From B to A: – no problem.

From B to D: – no problem.

From B to C: – no problem.

From C to A: – no problem.

From C to B: – no problem.

From C to D: – no problem.

From D to A: – no problem.

From D to B: B turns black.

From D to C: C turns black.

The console log does’t report anything at all. I have spent hours trying to find out what could possibly trigger the sudden black screens, but can’t find anything. I checked colors, positions, widget options, etc. There are no obvious errors in my code. I never saw black screens using the pre-2000 builds. The builds with the problem that I have downloaded and used are 2076, 2100 and 2239.

I am using 16GB Retina iPad, iOS version 7.1.

There must be some condition coming from screens A and D that cause a problem on screens B and C, but what?

All four scenes have virtually the same basic enterScene and exitScene events:

[lua]

function scene:enterScene(event)
    group.alpha = 1
    storyboard.purgeAll()
    storyboard.showOverlay( “menu” )
end

function scene:exitScene(event)

end
[/lua]

I am now going through a process of elimination, commenting out blocks of code, building and testing… hoping to stumble upon a solution.

_ Follow up: _ The native.newTextField was central to the “black screen” issue in my case. Specifically, I had various text fields inserted in a container. The Corona documentation warns against this. Not inserting the native textfields made the black screen problem go away. The textfields are on my scenes A and D. Since switching between scenes is essential in my app, I had to set these fields to .isVisible = false in the exitScene events and make them visible again in the enterScene events.

But there was still another black screen issue, in a separate scene which is a login screen. Here I had loginName.removeSelf() in my code. That line caused a black screen too, even when the textfields were NOT in a container or group. I replaced the .removeSelf() with .isVisible = false and that solved the problem.

I hope this experience is useful for any fellow Corona coder that happens to get a black screen. :slight_smile:

It should be: loginName:removeSelf() note the colon instead of a period.

Hope this helps.