Hello, I am fairly new to BRA and would appreciate some help. I tried to search the forums but was not able to figure out the problem.
In my Project I have the following module
1. Main ->Activity Module
2. Starter -> Service module
3. AstreamsText -> Class Module
4. B4XMainPage -> Class Module
5. Overview -> New module
I have a button " "in B4XMainPage .
I have some variables in Main
Problem
When button "overview" is pressed I want to call / run a function in the OVERVIEW module
In that function I was to set some text for the labels Labelbedroomtemp
When I try to access the labels in module overview , IDE shows that the variables climate_temparature and labeldedroomtemp are not declared.
How can I fix this ? How can I share the variable from MAIN to Overview ?
Thank you
In my Project I have the following module
1. Main ->Activity Module
2. Starter -> Service module
3. AstreamsText -> Class Module
4. B4XMainPage -> Class Module
5. Overview -> New module
I have a button " "in B4XMainPage .
B4X:
Private Sub overview_Click
CallSub(overview,"Temperature_By_Room")
End Sub
I have some variables in Main
B4X:
Sub Globals
Private BTConnect As Button
Private overview As Button
Dim climate_temperature As Int
Dim climate_humidity As Int
Public Labelbedroomtemp As Label
Public Labelbathroomtemp As Label
End Sub
Problem
When button "overview" is pressed I want to call / run a function in the OVERVIEW module
In that function I was to set some text for the labels Labelbedroomtemp
When I try to access the labels in module overview , IDE shows that the variables climate_temparature and labeldedroomtemp are not declared.
How can I fix this ? How can I share the variable from MAIN to Overview ?
Thank you