What does "Dialog Management" mean?

Post

Posted
Rating:
#1 (In Topic #966)
Enthusiast
gambafeliz is in the usergroup ‘Enthusiast’
Hello, Merry Christmas everyone.

I am creating a new form and at the time of its creation, I get this dialog that I will add your image.

Image

Capture

Capture

(Click to enlarge)



What does "Dialog Management" mean?
And if it is interesting to me how I mark this option in a form that I created in the past but that does not mark this option?

Thank you and happy day.

For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
Online now: No Back to the top

Post

Posted
Rating:
#2
Avatar
Guru
cogier is in the usergroup ‘Guru’
I tried this and got a couple of buttons on the form (OK and Cancel) and the following code was already created.

Code (gambas)

  1.  
  2.   Return Not Me.ShowModal()
  3.  
  4.  
  5. Public Sub btnOK_Click()
  6.  
  7.  
  8.  
  9. Public Sub btnCancel_Click()
  10.  
  11.  
Online now: No Back to the top

Post

Posted
Rating:
#3
Enthusiast
gambafeliz is in the usergroup ‘Enthusiast’
Aaah thank you :)

For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
Online now: No Back to the top

Post

Posted
Rating:
#4
Guru
BruceSteers is in the usergroup ‘Guru’

cogier said

I tried this and got a couple of buttons on the form (OK and Cancel) and the following code was already created.

Code (gambas)

  1.  
  2.   Return Not Me.ShowModal()
  3.  
  4.  
  5. Public Sub btnOK_Click()
  6.  
  7.  
  8.  
  9. Public Sub btnCancel_Click()
  10.  
  11.  

Yes it creates a Form with a Dialog template ready to go.

The default methods Cogier has shown there work like Dialog.OpenFile() in the way that the return is considered an error state so it returns false for an "okay" button press and true if the user presses Cancel. (always seems back to front to me but you can change it by switching the btnOk and btnCancel click event code)

But by default you can use the dialog form in your code like this…
(creating a Static variable in MyDialogWindow.class called StaticAnswerVar that get's filled when user presses okay in the dialog)

Code (gambas)

  1.  
  2. If MyDialogWindow.Run() Then
  3.   Print "User cancelled Dialog"
  4.   Print "Result was " & MyDialogWindow.StaticAnswerVar
  5.  
  6.  

The form, of course, will also be a Modal window so unlike a normal form it will lock your application while it's open.
Online now: No Back to the top

Post

Posted
Rating:
#5
Enthusiast
gambafeliz is in the usergroup ‘Enthusiast’
Thank you BruceS

 :shock:

It's interesting information.

For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
Online now: No Back to the top
1 guest and 0 members have just viewed this.