Android Question Error with running app in new version of Basic4Android

Suzanne

Member
Licensed User
Longtime User
Hi,

i'm a newbie at creating apps and not sure why i'm receiving the errors when trying to running the following app:

#Region Project Attributes
#ApplicationLabel: eBay
#VersionCode: 3
#VersionName:
'SupportedOrientations possible values: unspecified, landscape or portrait.
#SupportedOrientations: portrait
#CanInstallToExternalStorage: False
#End Region
#Region Activity Attributes
#FullScreen: True
#IncludeTitle: True
#End Region
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
Dim WebView1 As WebView

End Sub
Sub Activity_Create(FirstTime As Boolean)
Activity.LoadLayout("ebay")


WebView1.Initialize("")
WebView1.LoadUrl("http://rover.ebay.com/rover/1/710-5...ep_vectorid=229508&kwid=902099&mtid=824&kw=lg")
Activity.AddView(WebView1,0dip, 0dip, 100%x, 100%y)
'Activity.AddView(WebView1,0dip, 0dip, 100%x, 100%y)
' apply webview settings AFTER the WebView has been added to the layout
Dim WebViewSettings1 As WebViewSettings
' possible values are "CLOSE", "FAR" & "MEDIUM"
' default is "MEDIUM"
WebViewSettings1.setDefaultZoom(WebView1, "MEDIUM")

WebViewSettings1.setLoadWithOverviewMode(WebView1, True)

WebViewSettings1.setUseWideViewPort(WebView1, True)





'



'If mmm.weconnected="NO" Then Activity.Title="( No Wifi ) Turn ON Your Wifi !!!"

' Button1.Initialize("")
'Activity.AddView(Button1,0, 0, 10%x, 10%y)
'Button1.SetBackgroundImage(LoadBitmap(File.DirAssets, "back.jpg"))

End Sub
Sub Activity_Resume





End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub




Running the app on the previous version of Basic4Android works fine and the error on the new version looks like a Java problem but i'm not quite sure how to rectify this??

Any help would be appreciated.
 

NJDude

Expert
Licensed User
Longtime User
Hi Suzanne,

A few things that will make us help you better:

1- When you have layouts in your app better to attach the project (on the IDE, click on File -> Export as ZIP)
2- When posting code use the [code] ... [/code] tags.

You mention "previous version" but you are not mentioning what's the version you currently have and what was the previous you had.

Welcome to B4A!.
 
Upvote 0

Suzanne

Member
Licensed User
Longtime User
Hi NJDude,

Thank you for your response....

I have exported as ZIP but not sure about
B4X:
 tags?!

Previous Version 2.52
Current Version 3.50

Many thanks!
 

Attachments

  • app.zip
    88 KB · Views: 128
Upvote 0

NJDude

Expert
Licensed User
Longtime User
I don't see any errors, you might need to update the "WebViewSettings" library.

A couple of suggestions

1- Change the package name, "ebay" is a registered trademark, so, your app having that name may cause a slap in the wrist from Google.
2- Change the app icon, it looks like the "official" app, that will also make Google a little angry.

There are other issues but let's take 1 step at a time.
 
Last edited:
Upvote 0

DonManfred

Expert
Licensed User
Longtime User
@Suzanne an example for you.

Without Code-Tags it looks like this

' DIM lists
Dim prova(10) As List
For i = 0 To 9
' Initialize list i
prova(i).Initialize
' Add items to list i
For o = 0 To 2
Dim val As Int = ((i+1)*1000)+o
prova(i).Add("Listitem "&val)
Next
Next

as you can see it is not really good readable...

You can use this button to get help creating the code-tags.

Using the Codetags it would look like this

B4X:
    ' DIM lists
    Dim prova(10) As List 
    For i = 0 To 9
        ' Initialize list i
        prova(i).Initialize
        ' Add items to list i
        For o = 0 To 2
            Dim val As Int = ((i+1)*1000)+o
            prova(i).Add("Listitem "&val)
        Next
    Next

PS: Welcome to B4A!
 
Upvote 0

Suzanne

Member
Licensed User
Longtime User
Thank you NJDude, that worked a treat, i've sent a little donation to yourself for your for help

Plus thank you DonManfred for your input on the Codetags, i see what you mean!

Suzanne @bb
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…