Current DateTime


Node Information
Gets DateTime information of the current machine.
General Information
• This node doesn't have other available options.
Visual
Visual

Ports
Text Type DataType Accepts IsList CustomAcception
Year OUT Int32 MULTIPLE FALSE FALSE
Month OUT Int32 MULTIPLE FALSE FALSE
Day OUT Int32 MULTIPLE FALSE FALSE
Hour OUT Int32 MULTIPLE FALSE FALSE
Minute OUT Int32 MULTIPLE FALSE FALSE
Second OUT Int32 MULTIPLE FALSE FALSE
MonthName OUT String MULTIPLE FALSE FALSE
DayName OUT String MULTIPLE FALSE FALSE

Source
namespace Korduene.KGraph.Nodes.Win32.Information
{
    [IsNode("Current DateTime")]
    public class CurrentDateTime : Node
    {
        Port year = new Port(PortType.OUT, typeof(int), AcceptsLinks.MULTIPLE, "Year");
        Port month = new Port(PortType.OUT, typeof(int), AcceptsLinks.MULTIPLE, "Month");
        Port day = new Port(PortType.OUT, typeof(int), AcceptsLinks.MULTIPLE, "Day");
        Port hour = new Port(PortType.OUT, typeof(int), AcceptsLinks.MULTIPLE, "Hour");
        Port minute = new Port(PortType.OUT, typeof(int), AcceptsLinks.MULTIPLE, "Minute");
        Port second = new Port(PortType.OUT, typeof(int), AcceptsLinks.MULTIPLE, "Second");
        Port monthname = new Port(PortType.OUT, typeof(string), AcceptsLinks.MULTIPLE, "MonthName");
        Port dayname = new Port(PortType.OUT, typeof(string), AcceptsLinks.MULTIPLE, "DayName");
        public CurrentDateTime()
        {
            this.Name = "Current DateTime";
            AddPort(year);
            AddPort(month);
            AddPort(day);
            AddPort(hour);
            AddPort(minute);
            AddPort(second);
            AddPort(monthname);
            AddPort(dayname);
            year.Instructions = "DateTime.Now.Year";
            month.Instructions = "DateTime.Now.Month";
            day.Instructions = "DateTime.Now.Day";
            hour.Instructions = "DateTime.Now.Hour";
            minute.Instructions = "DateTime.Now.Minute";
            second.Instructions = "DateTime.Now.Second";
            monthname.Instructions = "DateTime.Now.ToString(" + q + "MMMM" + q + ")";
            dayname.Instructions = "DateTime.Now.ToString(" + q + "dddd" + q + ")";
            Information = "Gets DateTime information of the current machine.";
        }
    }
}