Probleme avec les fenetres
Posté : ven. 01 oct. 2021 14:22
Bonjour j'ai se petit bout de code :
D'abord _loadListeConfig()
La gui qui est en arrière plan et qui veut pas se fermer
Mais le hic c'est que ce la masque bien la GUI
Merci si vous pouvez m'aider.
D'abord _loadListeConfig()
Code : Tout sélectionner
Func _loadListeConfig()
$aFileList = _FileListToArray("Configs","*")
$sFilePath = @ScriptDir & "\Configs\"
GUIListeConfigs()
For $i = 0 To $aFileList[0]
$conf = $aFileList[$i]
If $conf == "Config" & $i & ".txt" Then
$patch = $sFilePath & $conf
Local $sRead = IniRead($patch, "1", "NOM", "Default Value")
$allConfigFile = "Config " & $i & " - " & $sRead & "|"
GUICtrlSetData($Combo1, $allConfigFile, "Config 1 - " & $sRead)
EndIf
Next
EndFunc
Code : Tout sélectionner
Func GUIListeConfigs()
Global $GUIListeConfigs = GUICreate("Configs", 319, 156, 684, 408)
$GroupBox1 = GUICtrlCreateGroup("", 8, 1, 305, 97)
Global $Combo1 = GUICtrlCreateCombo("", 72, 56, 169, 25)
$Label1 = GUICtrlCreateLabel("Selectionnez une Configuration", 48, 16, 226, 24)
GUICtrlSetFont(-1, 12, 400, 0, "MS Sans Serif")
GUICtrlCreateGroup("", -99, -99, 1, 1)
Global $ButtonChargerConfig = GUICtrlCreateButton("OK", 73, 107, 75, 25)
Global $ButtonAnnulerChargerConfig = GUICtrlCreateButton("Cancel", 170, 107, 75, 25)
GUISetState(@SW_HIDE, $GUIListeConfigs)
#EndRegion ### END Koda GUI secw²tion ###
EndFunc
Code : Tout sélectionner
While 1
Switch GUIGetMsg()
Case $ChargerChoixMenu
$choixMenu = GUICtrlRead($listMenu)
ConsoleWrite($choixMenu & @CRLF)
If $choixMenu = "Charger une image" Then
_loadListeConfig() ;Charge La liste des config
GUISetState(@SW_SHOW, $GUIListeConfigs)
EndIf
if ($choixMenu = "Créer un Trajet") Then
$msg = MsgBox(4, "Création d"une image ", "Bienvenue dans l'edition de vos fichier CONTINUER ?"
If ($msg <> 7) Then
_loadListeConfig()
GUISetState(@SW_SHOW, $GUIListeConfigs)
$read = GUICtrlRead($combo1)
testtest($read);
EndIf
EndIf
EndSwitch
WEnd
$GUIListeConfigs
mais je ne peux rien faire d'autre, la GUI 1 ne fonctionne plus.Merci si vous pouvez m'aider.