Headsniper1997's post in GUICtrlSetData puts in a number was marked as the answer
February 2, 2023
Heyhey
i got a problem. whene i press the button on the second page, it should overwrite the Editbox with a exampletext. My Problem ist, that everytime i get a number first,
how to fix that? I only want a defined Text, when i press the Button at the 2. Tab "Aufnahme" and press the Button "Normalbefund"
Some solutions :)?
#include <ButtonConstants.au3>
#include <ComboConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <TabConstants.au3>
#include <File.au3>
#include <Date.au3>
#include <MsgBoxConstants.au3>
#include <GUIConstantsEx.au3>
#include <EditConstants.au3>
#Include <GUIEdit.au3>
#Include <ScrollBarConstants.au3>
#include <WindowsConstants.au3>
#include <FileConstants.au3>
#include <MsgBoxConstants.au3>
#include <WinAPIFiles.au3>
#Region ### START Koda GUI section ### Form=C:\Users\axelf\Desktop\Kildo Flensburg.kxf
$Form1 = GUICreate("Klinisches Dokumentationssystem - Flensburg", 1018, 801, 448, 123)
$Anamnese = GUICtrlCreateTab(0, 0, 1017, 800)
;//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////ANAMNESE/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
$Anamnes = GUICtrlCreateTabItem("Anamnese")
$Persdat = GUICtrlCreateLabel("Persönliche Daten", 24, 56, 190, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
$Anamkurz = GUICtrlCreateEdit("", 32, 312, 649, 169)
$Label1 = GUICtrlCreateLabel("Aufnahme - Kurz", 32, 272, 172, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
$Name1 = GUICtrlCreateInput("", 152, 96, 193, 21)
$Geburtsdatum = GUICtrlCreateInput("", 152, 120, 193, 21)
$Geschlecht = GUICtrlCreateInput("", 152, 144, 193, 21)
$Namelabel = GUICtrlCreateLabel("Name", 24, 96, 43, 21)
GUICtrlSetFont(-1, 11, 400, 0, "Arial")
$Gebursdatumlabel = GUICtrlCreateLabel("Gebursdatum", 24, 120, 93, 21)
GUICtrlSetFont(-1, 11, 400, 0, "Arial")
$Geschlechtslabel = GUICtrlCreateLabel("Geschlecht", 24, 144, 93, 21)
GUICtrlSetFont(-1, 11, 400, 0, "Arial")
$Behandlungsfachrichtungslabel = GUICtrlCreateLabel("Behandelnde Fachrichtung", 568, 64, 271, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
$Fachrichtung = GUICtrlCreateCombo("Fachrichtung", 568, 104, 193, 25, BitOR($CBS_DROPDOWN,$CBS_AUTOHSCROLL))
$Fachr = GUICtrlSetData($Fachrichtung, "Neurologie|Chirurgie|Internistisch|Gynäkologie|Psychiatrie|Urologie|Pulmologie")
;/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////AUFNAHME//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
$Aufnahme = GUICtrlCreateTabItem("Aufnahme")
$Label5 = GUICtrlCreateLabel("Anamnese", 24, 56, 112, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
$Label6 = GUICtrlCreateLabel("Sozialanamnese", 24, 280, 171, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
$Label7 = GUICtrlCreateLabel("EKG Befund", 24, 520, 129, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
$Anamnese = GUICtrlCreateEdit("", 24, 96, 649, 169)
$Sozialanamnese = GUICtrlCreateEdit("", 24, 328, 649, 169)
$EKGbefund = GUICtrlCreateEdit("", 24, 568, 649, 57)
$EKGButton = GUICtrlCreateButton("Normalbefund", 700, 570, 100, 50)
;////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////EREIGNISSE///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
$Ereignisse = GUICtrlCreateTabItem("Ereignisse")
$Vorerkrankung = GUICtrlCreateEdit("", 24, 96, 649, 169)
$Label8 = GUICtrlCreateLabel("Vorerkrankungen", 24, 56, 177, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
$Medikationsplan = GUICtrlCreateEdit("", 24, 328, 649, 169)
$Label8 = GUICtrlCreateLabel("Medikationsplan", 24, 280, 171, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
;/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////NEURO//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
$Neuro = GUICtrlCreateTabItem("Neuro")
$Label9 = GUICtrlCreateLabel("Neurostatus", 24, 56, 128, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
$Neuostatus = GUICtrlCreateEdit("", 24, 96, 649, 169)
$Neurobutton = GUICtrlCreateButton("Textbaustein", 700, 120, 150, 100)
;//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////CHIRURGIE/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
$Chirurgie = GUICtrlCreateTabItem("Chirurgie")
$Chir = GUICtrlCreateEdit("", 24, 96, 649, 169)
$Label10 = GUICtrlCreateLabel("Chirurgische Verletzungsmuster", 24, 56, 325, 30)
GUICtrlSetFont(-1, 17, 400, 0, "Arial")
;/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////FINALISIEREN//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
$TabSheet1 = GUICtrlCreateTabItem("Finalisieren")
$Button1 = GUICtrlCreateButton("Entlassbericht erstellen", 368, 280, 217, 129)
GUICtrlCreateTabItem("")
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Neurobutton
GUICtrlSetData($Neuostatus, 1 & @CRLF & "Gesicht: Kein Meningismus. Gesamtes Gesichtsfeld fingerperimetrisch frei. Pupillen isokor, mittelweit. " & @CRLF & "Motorik: MER der Arme und Beine seitengleich mittellebhaft. Kornealreflex bds. auslösbar. Bauchhautreflex bds. mittellebhaft." & @CRLF & "Sensibilität: Berührungssensibilität allseits intakt." & @CRLF & "Kraft: Kein Absinken im AHV 5/5 und BHV 5/5." & @CRLF & "Bewusstsein: Wach. Zu allen Qualitäten voll orientiert. " & @CRLF & "Stand und Gang: Stand sicher. Gang sicher. Romberg ungestört. Beidseits kein Tremor.")
Case $EKGButton
GUICtrlSetData($EKGbefund, -1 & @CRLF & "HF: 78/min. PQ-Zeit: 179 msek. SR. IT. QRS-Komplex-Breite: 84 msek. Regelr. Q-Zacken. R-/S-Umschlag in V2-V3. QT-Zeit: 429 msek. QTc-Zeit nach Bazett: 489 msek. Keine ERBS.")
Case $Button1
$Name2 = GUICtrlRead($Name1)
$Gebdatum = GUICtrlRead($Geburtsdatum)
$Fachr = GUICtrlRead($Fachrichtung)
$Anakurz = GUICtrlRead($Anamkurz)
$Geschl = GUICtrlRead ($Geschlecht)
$Analang = GUICtrlRead ($Anamnese)
$Sozanam = GUICtrlRead ($Sozialanamnese)
$EKGbef = GUICtrlRead ($EKGbefund)
$Vorerkr = GUICtrlRead ($Vorerkrankung)
$Mediplan = GUICtrlRead ($Medikationsplan)
$Neurost = GUICtrlRead ($Neuostatus)
$Chirurgie = GUICtrlRead ($Chir)
;/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////Anamnese////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
_FileCreate($Name2 & ".doc")
FileWrite ($Name2 & ".doc", "Gemeinschaftspraxis" & @CRLF & "Dr. med. Ulrich Schürcher" & @CRLF)
FileWrite ($Name2 & ".doc", "Falkenweg 2" & @CRLF)
FileWrite ($Name2 & ".doc", "24973 Flensburg " & @CRLF & @CRLF)
FileWrite ($Name2 & ".doc", "Sehr geehrte Kolleginnen und Kollegen," & @CRLF)
FileWrite ($Name2 & ".doc", "Wir berichten Ihnen über " & $Geschl & " " & $Name2 & ", geb. am: " & $Gebdatum & ", welche/r sich am " & _NowDate() & " in unserer Notaufnahme befand." & @CRLF & @CRLF)
FileWrite ($Name2 & ".doc", "Behandelnde Abteilung: " & $Fachr & @CRLF & @CRLF)
FileWrite ($Name2 & ".doc", "Aufnahme Kurz: " & @CRLF & $Anakurz)
; LABEL 1 ENDE
;/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////Aufnahme////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
FileWrite ($Name2 & ".doc", "Anamnese:" & @CRLF & $Analang & @CRLF & @CRLF)
FileWrite ($Name2 & ".doc", "Sozialanamnese:" & @CRLF & $Sozanam & @CRLF & @CRLF)
FileWrite ($Name2 & ".doc", "EKG Befund:" & @CRLF & $EKGbef & @CRLF & @CRLF)
;/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////Ereignis////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
FileWrite ($Name2 & ".doc", "Vorerkrankungen:" & @CRLF & $Vorerkr & @CRLF & @CRLF)
FileWrite ($Name2 & ".doc", "Medikationsplan: " & @CRLF & $Mediplan & @CRLF & @CRLF)
;/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////NEURO//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
FileWrite ($Name2 & ".doc", "Neurostatus: " & @CRLF & $Neurost & @CRLF & @CRLF)
;//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////CHIRURGIE//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
FileWrite ($Name2 & ".doc", "Chirurgische Befunderhebung: " & @CRLF & $Chirurgie & @CRLF & @CRLF)
Exit
EndSwitch
WEnd
Flensburg.au3