Android Question Read only Preferences/Dialog form field

Startup

Active Member
Licensed User
Longtime User
Is it possible to create a Preferences/Dialog form that displays a field which is read-only?
 

Startup

Active Member
Licensed User
Longtime User
You can change the explanation item text before you show the dialog.

Thanks Erel! I want to change the explanation item text programmatically to reflect the current/latest value of a variable as the App is run. Do I do this by using JSONParser to deconstruct the JSON file (used by the form) and then JSONGenerator to reconstruct the file with the changed explanation item? Or is there a simpler/more direct way to change the explanation item programmatically?
 
Upvote 0

Startup

Active Member
Licensed User
Longtime User
You can change the explanation text with:
B4X:
Pref.SetExplanation("item key", "Explanation here")

Thanks again! But I want the value of the variable to show with the rest of the Dialog display like the other items show without having to press the title key and being taken to another screen to see it. Is this possible?
 
Upvote 0

Startup

Active Member
Licensed User
Longtime User
You can update the explanation item title like this:
B4X:
p.GetPrefItem("item key").Title = "new title"
p.CustomListView1.Clear
'show the form

OK. That's good. But if the user happens to touch the title it goes to the explanation screen. Could that, say be disabled, so the dialog stays displayed?
 
Upvote 0
Top