I am a big fan of VB6. And "was" as fan of B4A.
I started developing few apps for lowend devices those who have low ram. And now i am thinking that i should give up my idea of developing apps using B4A as they have very high ram usage & would be unfit to develop.
An small application with nearly no code uses 26MB of ram. And till now i haven't seen <20MB
Is this cost of using B4A or a RAD ?
I have attached screenshot you can compare it with many big apps. And below is code.
If you think i am going wrong point me in right direction, I will be thankful as you will save my 1000 line code
Main:
Service Module :
I started developing few apps for lowend devices those who have low ram. And now i am thinking that i should give up my idea of developing apps using B4A as they have very high ram usage & would be unfit to develop.
An small application with nearly no code uses 26MB of ram. And till now i haven't seen <20MB
Is this cost of using B4A or a RAD ?
I have attached screenshot you can compare it with many big apps. And below is code.
If you think i am going wrong point me in right direction, I will be thankful as you will save my 1000 line code
Main:
B4X:
#Region Project Attributes
#ApplicationLabel: B4A Example
#VersionCode: 1
#VersionName:
'SupportedOrientations possible values: unspecified, landscape or portrait.
#SupportedOrientations: unspecified
#CanInstallToExternalStorage: False
#End Region
#Region Activity Attributes
#FullScreen: False
#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
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
End Sub
Sub Activity_Create(FirstTime As Boolean)
'Do not forget to load the layout file created with the visual designer. For example:
'Activity.LoadLayout("Layout1")
StartService("test")
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Service Module :
B4X:
#Region Service Attributes
#StartAtBoot: False
#StartCommandReturnValue: android.app.Service.START_STICKY
#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 Service_Create
Service.StartForeground(0,Null)
End Sub
Sub Service_Start (StartingIntent As Intent)
End Sub
Sub Service_Destroy
End Sub