Sub FImages1
FIPanel1.Initialize("fipanel1")
FIPanel1.Width = 100%x
FIPanel1.Height = FIPanel1.Width
FIPanel1.SetBackgroundImage(LoadBitmap(File.DirAssets, "ecf.png"))
Activity.AddView(FIPanel1, 0, 0, 100%x, 100%y)
End Sub
Sub FImages1
FIPanel1.Initialize("fipanel1")
Activity.AddView(FIPanel1, 0, 0, 100%x, 100%y)
FIPanel1.SetBackgroundImage(LoadBitmap(File.DirAss ets, "ecf.png"))
End Sub
Try this code:You shouldn't set FIPanel1.Width and FIPanel1.Height berfore the view is added to the Activity they are defined in the Activity.AddView method.B4X:Sub FImages1 FIPanel1.Initialize("fipanel1") Activity.AddView(FIPanel1, 0, 0, 100%x, 100%y) FIPanel1.SetBackgroundImage(LoadBitmap(File.DirAss ets, "ecf.png")) End Sub
Best regards.
Did you declare "fipanel1" somewhere else differently ?
Otherwise we need to see your code.
Best regards.
'Activity module
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
Dim FIPanel As ScrollView
End Sub
Sub Activity_Create(FirstTime As Boolean)
FIPanel.Initialize("fipanel")
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Without seeing your other code it's impossible to help you.
The most efficient way is to post your project as a zip file so we could have a look at it and test in the same conditions as you do (IDE menu Files / Export As Zip).
Otherwise we need to try to guess what it could be and play 'ping pong' for a while.
Best regards.
i create a new oneThat is probably not it, i create a new one, add in only those code compile successfully, install successfully, when open, it give a double error.
i create a new one
Can you post this project as a zip file.
it give a double error
What errors ?
i do not believe this happen with the previous version
If you send the project I can try it. I still have the previous versions.
Best regards.
I couldn't test the program in exactly the same conditions as you because you didn't provide the image file in your project and it's the version with ScrollView2D which works for you !?.
So how do you expect we could help.
You didn't even say what errors you get as I requested in my post.
So I modified your program :
- added an image file
- use two ScrollViews, a vertical ScrollView and a ScrollView2D to test both at the same time.
I tested on my devices:
- Nexus One Android 2.3.3
- Asus TF 700 tablet Android 4.0.3
The program works perfectly on both devices with B4A 2.2 !
So ScrollView has NO problems with B4A 2.2 as I expected.
Best regards.
Sorry about all this, but atleast we know scrollview probably cant handle big img file, or android cant handle big file with scrollview?
With such an image size, it's probably an Out of Memory error and is not related to ScrollView. A ScrollView can handle very large sizes (up to the maximum value of an integer).
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?