Manage PlItems

You may optionally enter a comparison operator (<, <=, >, >=, <> or =) at the beginning of each of your search values to specify how the comparison should be done.

Advanced Search
Displaying 221-230 of 300 results.
IDPlCodelangPlGroupPlItemTitleCode 
 
203JavaFilehandlingTernary operatorString thisVar = "OK"; boolean resultVar; resultVar = thisVar.equals("OK") ? true : false; // same as if-else construction if (thisVar.equals("OK")) { resultVar = true; } else { resultVar = false; }View Update Delete
26DelphiExceptionsTry Catch Excepttry // Code except // Handle the exception here... end; View Update Delete
27DelphiDatum, ZeitAktuelles Datum/Uhrzeitstr:=FormatDateTime('yyyymmdd hhnnss',now); // gibt aus 20100331 120723View Update Delete
28DelphiProzeduren, Funktionen, MethodenVerarbeitung gezielt beendenprocedure TForm1.Proz(Sender: TObject); begin If 1<>2 Then exit; ShowMessage('Test'); end;View Update Delete
44DelphiFilehandlingDatei auf dem Betriebssystem ausführenprocedure TForm1.MenuDummy1Click(Sender: TObject); var ExeName : array[0..255] of char; myFile : String; begin myFile:='winword.exe'; Showmessage('Starte: ' + myFile); StrPCopy(ExeName, myFile); ShellExecute(MainForm.Handle, 'open', ExeName, nil, nil, SW_SHOWNORMAL); // Drucken geht dann so (siehe auch Dateitypen im Windows Explorer): ShellExecute(MainForm.Handle, 'print', ExeName, nil, nil, SW_SHOWNORMAL); end;View Update Delete
55DelphiGUI, Komponenten allgemeinMit Return ein Ereignis im Textfeld auslösenprocedure TForm1.Edit1KeyPress(Sender: TObject; var Key: Char); begin if Key = #13 then begin Key := #0; ShowMessage('Auswerten ...'); end; end; View Update Delete
71DelphiSchleifenFor-Schleifefor i := 0 to 4 do Writeln(i); View Update Delete
72DelphiStringsReplaceprocedure foo() var str1: String; begin str1:=StringReplace('Hello World...','...',[rfReplaceAll, rfIgnoreCase]); // Output of str1 => "Hello World" endView Update Delete
73DelphiWindows - Prompt ErrorlevelErrorlevel setzen//... var errorlevel: Integer; begin if cond1=cond2 then errorlevel:=0; if cond1<>cond2 then errorlevel:=1; halt(errorlevel); end.View Update Delete
74DelphiTypenkonvertierungString in Integer konvertierenMyInt:=StrToInt('125');View Update Delete