TimePicker
TsgcHTMLComponent_TimePicker — erzeugen Sie eine native HTML5-Zeiteingabe mit optionalen Min- und Max-Grenzen und sekundengenauer Granularität, in Delphi, C++ Builder und .NET.
TsgcHTMLComponent_TimePicker — erzeugen Sie eine native HTML5-Zeiteingabe mit optionalen Min- und Max-Grenzen und sekundengenauer Granularität, in Delphi, C++ Builder und .NET.
Eine beschriftete Eingabekomponente, die ein Bootstrap-form-control vom HTML5-Typ time ausgibt. Setzen Sie die Grenzen und lesen Sie dann die HTML-Eigenschaft (oder rufen Sie den statischen Build-Helfer auf).
TsgcHTMLComponent_TimePicker
Natives HTML5 <input type="time">
Delphi, C++ Builder, .NET
Setzen Sie FieldName, LabelText und die Grenzen MinTime/MaxTime, dann lesen Sie HTML — oder rufen Sie den statischen Build-Helfer für eine Einzeiler-Lösung auf.
uses
sgcHTML_Component_TimePicker;
var
oTime: TsgcHTMLComponent_TimePicker;
begin
oTime := TsgcHTMLComponent_TimePicker.Create(nil);
try
oTime.FieldName := 'appointment_time';
oTime.LabelText := 'Appointment time';
oTime.MinTime := '08:00';
oTime.MaxTime := '18:00';
oTime.Required := True;
WebModule.Response := oTime.HTML; // <input type="time">
finally
oTime.Free;
end;
end;
// Or the static one-liner (field name, label, value):
Result := TsgcHTMLComponent_TimePicker.Build('appointment_time', 'Appointment time');
// includes: sgcHTML_Component_TimePicker.hpp
TsgcHTMLComponent_TimePicker *oTime = new TsgcHTMLComponent_TimePicker(NULL);
try
{
oTime->FieldName = "appointment_time";
oTime->LabelText = "Appointment time";
oTime->MinTime = "08:00";
oTime->MaxTime = "18:00";
oTime->Required = true;
String html = oTime->HTML; // <input type="time">
}
__finally
{
delete oTime;
}
// Or the static one-liner:
String html = TsgcHTMLComponent_TimePicker::Build("appointment_time", "Appointment time");
using esegece.sgcWebSockets;
var time = new TsgcHTMLComponent_TimePicker();
time.FieldName = "appointment_time";
time.LabelText = "Appointment time";
time.MinTime = "08:00";
time.MaxTime = "18:00";
time.Required = true;
string html = time.HTML; // <input type="time">
// Or the static one-liner:
string html2 = TsgcHTMLComponent_TimePicker.Build("appointment_time", "Appointment time");
Die Member, die Sie am häufigsten verwenden.
Value füllt die Eingabe vor; FieldName setzt deren name; LabelText rendert ein form-label.
MinTime und MaxTime schränken den wählbaren Bereich über die nativen min/max-Attribute ein.
StepSeconds setzt das step-Attribut direkt; ShowSeconds (Standard False) ist eine Abkürzung, die eine Granularität von einer Sekunde anfordert, wenn StepSeconds bei 0 belassen wird.
Required und Disabled markieren die native Eingabe entsprechend.
Size (TsgcHTMLSize: hsExtraSmall…hsExtraLarge, Standard hsMedium) bildet auf Bootstraps form-control-sm/form-control-lg ab.
Build(fieldName, labelText, value) gibt das Markup in einer Zeile zurück, ohne eine Instanz zu verwalten.
| Online-HilfeVollständige API-Referenz und Verwendungshandbuch für diese Komponente. | Öffnen | |
| Alle sgcHTML-KomponentenDurchsuchen Sie die vollständige Funktionsmatrix von über 80 Komponenten. | Öffnen | |
| Kostenlose Testversion herunterladenDie 30-Tage-Testversion enthält die 60.HTML-Demoprojekte. | Öffnen | |
| PreiseSingle-, Team- und Site-Lizenzen mit vollständigem Quellcode. | Öffnen |