Seite 1 von 1

Re: Button - Umschalten aktiv - wie Zustand auslesen?

Verfasst: Do, 19.06.2008 23:14
von komma4
Hallo Mario,

willkommen im Forum.
com.sun.star.awt.UnoControlButtonModel.html#Toggle hat geschrieben: specifies whether the button should toggle on a single operation.

If this property is set to true , a single operation of the button control (pressing space while it is focused, or clicking onto it) toggles it between a pressed and a not pressed state.

The default for this property is false , which means the button behaves like a usual push button.
Since OpenOffice 2.0
Hilft das weiter?

Re: Button - Umschalten aktiv - wie Zustand auslesen?

Verfasst: Do, 19.06.2008 23:27
von komma4
Ups,

Du wolltest den akt. Status auslesen...

das ist dann State:

Code: Alles auswählen

oDialog = LoadDialog( "Standard", "Dialog1")

' Schaltfläche
oSchalt_1 = oDialog.getControl( "CommandButton1" ) 

' gedrückt
oSchalt_1.getModel().State = 1

print oSchalt_1.getModel().getPropertyValue( "State" )

' Dialog anzeigen
oDialog.execute()[/
War es das?