Changing value from modules to another modules

henry1311

Member
Licensed User
Longtime User
Hello all!

I am not able to value other objects found in the Activity and / or in other layouts found in 'activity module' or by code module '
Example :

main module/activity :

Sub Activity_Create(FirstTime As Boolean)
' configurazione
Activity.LoadLayout("aConfig1")
' valorizzazione e traduzione variabili e oggetti
Activity.Title=main.trans.GetText("Configuration")
lblSelLingua.Text=main.trans.GetText("Language")
btnConfig1Memo.Text=main.trans.GetText("Save configuration")
btnConfig1Esce.Text=main.trans.GetText("Exit")
' menu
Activity.AddMenuItem2(main.trans.GetText("Save configuration"), "mnuSalvaConf", LoadBitmap(File.DirAssets, "save2.png"))
Activity.AddMenuItem2(main.trans.GetText("Help"), "mnuHelpConf", LoadBitmap(File.DirAssets, "help6.png"))
Activity.AddMenuItem2(main.trans.GetText("Exit"), "mnuEsceConf", LoadBitmap(File.DirAssets, "exit1.png"))
End Sub

From the module xmod1.bas (code or activity):
how do I change, for example, the value of btnConfig1Memo.Text?
how do I change, for example, the value of a menu item that is on the same Activity or from another module (module code or activity)?

I wrote basicppc : moduloName.objectName.Text="xxx"!

Thank you
Enrico

Sorry for my English. Translated with google translate
 

Wien.Mart

Member
Licensed User
Longtime User
I hope I am asking a question along the same lines. I want to pass a value from module a to module b. I read somewhere to declare the variable in

process_globals
hhid as int

and it hhid as
hhid = ScrvGetCell(rc.Row, rc.Col)
the result of the above comes from a query populated into a scrollview

I tried it and the project compiles. However, I get the error below.
upload_2013-11-26_18-47-0.png

I checked the sqlite data type and uploaded the database to the correct folder but still get the error. Am I doing it right?
 

Attachments

  • upload_2013-11-26_18-50-26.png
    upload_2013-11-26_18-50-26.png
    9.9 KB · Views: 153
Upvote 0

Wien.Mart

Member
Licensed User
Longtime User
Dear Klaus. Thank you. It worked. The return value is a number so i declared it as int. The intermediate variable worked.
 
Upvote 0
Top