[Gambas-user] OK click on Wizard
Rolf-Werner Eilert
rwe-sse at osnanet.de
Fri Sep 6 13:35:07 CEST 2019
Aaaah thank you Ian! That was it.
Thanks so much!
Rolf
Am 06.09.19 um 12:25 schrieb Ian Roper:
> Hi Rolf,
>
> I started to play with this and found that there is a Wizard_Close() event
>
> This is activated when the "Ok" button appears and is then clicked on.
>
> Public Sub Wizard_Close()
> Me.Close
> End
>
> The reason why my first response to your question was flawed was because
> I was loading the Wizard data dynamically from a text file and the final
> Index I created was blank
>
> so I observed what I expected to see but was closing one index early as
> you discovered.
>
>
> Cheers,
>
> Ian.
>
>
> On 6/9/19 5:39 pm, Rolf-Werner Eilert wrote:
>> Hi Ian,
>>
>> This doesn't work either. When I give ".Count -1" it is in fact
>> closed, but one too early, i. e. after the user clicks on the last
>> "Next" button.
>>
>> As soon as "OK" appears, the button doesn't react anymore.
>>
>> About the Wizard.ActionText, I know. But is there a special event for
>> this last button?
>>
>> Regards
>> Rolf
>>
>> Am 06.09.19 um 10:22 schrieb Ian Roper:
>>> Hi Rolf,
>>>
>>> This works to close the wizard on button click after the last 'page'
>>> as been reviewed.
>>>
>>> Public Sub Wizard_Change()
>>>
>>> If Wizard.Index = Wizard.Count - 1 Then Me.Close
>>>
>>> End
>>>
>>> if you want to change the text of the last button use
>>> Wizard.ActionText = "your close message"
>>>
>>> Please note; that if you code the change routine as 'Private' it will
>>> not trigger on a change event.
>>>
>>> It will only trigger if set to 'Public' as per the example.
>>>
>>>
>>> Cheers,
>>>
>>> Ian.
>>>
>>>
>>> On 6/9/19 3:24 pm, Fabien Bodard wrote:
>>>> And if you try that ? :
>>>>
>>>> http://gambaswiki.org/wiki/comp/gb.form/wizard/.change
>>>>
>>>>
>>>>
>>>> Le ven. 6 sept. 2019 à 09:20, Rolf-Werner Eilert <rwe-sse at osnanet.de
>>>> <mailto:rwe-sse at osnanet.de>> a écrit :
>>>>
>>>> In a Wizard with 5 steps, I want to close the dialog when the user
>>>> clicks the button on the last step, i. e. step 5 when "OK" is
>>>> shown.
>>>>
>>>> I tried Wizard_Click() and it reacts to every step
>>>>
>>>> Select Wizard.Index
>>>> Case 1
>>>> ...
>>>> Case 2
>>>> ...
>>>> Case 5
>>>> Me.Close
>>>> End Select
>>>>
>>>> But there is no reaction on step 5.
>>>>
>>>> Is there another event for the OK button?
>>>>
>>>> By the way, the documentation text for _Click is missing...
>>>>
>>>> Regards
>>>> Rolf
>>>>
>>>> ----[ Gambas mailing-list is hosted by https://www.hostsharing.net
>>>> ]----
>>>>
>>>>
>>>>
>>>> --
>>>> Fabien Bodard
>>>>
>>>> ----[ Gambas mailing-list is hosted byhttps://www.hostsharing.net ]----
>>>
>>>
>>> ----[ Gambas mailing-list is hosted by https://www.hostsharing.net ]----
>>>
>>
>>
>> ----[ Gambas mailing-list is hosted by https://www.hostsharing.net ]----
>
> ----[ Gambas mailing-list is hosted by https://www.hostsharing.net ]----
>
>
More information about the User
mailing list