GetPart

The GetPart component enables the user to extract a specified part from given Date and time.

Screenshot

Ports

The GetPart component exposes the Control In, Control Out, Data In and Data Out ports by default.

Port Description
ControlIn Must be connected to the Control Out port of one or more components.
ControlOut Must be connected to the Control In port of any other component.
Data In The GetPart component exposes the following Data Inputs:
SourceDate: Specified the DateTime which user provide.
Format: Specifies the format to Get the Part of Date Time Source.
Data Out Return the specified part of Data time source.

Properties

To edit the properties of the GetPart component, in the Properties window, change the required property. User can edit the following properties..

Property Description
Search Search for the respective property.
Delay After Execution Specifies the wait time (in seconds) after the action is executed.
Delay Before Execution Specifies the wait time (in seconds) before the action is executed.

Example

Let us consider an example of the GetPart component.

Screenshot

To Get the Part From Date Time:

  1. In the Toolbox, expand Utilities and then expand DateTime.
  2. Drag the Now component and drop it on the Design surface.
  3. Drag the GetPart component and drop it on the Design surface.
  4. Double-click the Format box and enter the format to extract the date time.

    Date and Time Entry Legend:

    Constant Meaning
    MM Month
    dd Date
    yyyy Year
    hh Hours
    mm Minutes
    ss Seconds
    ms Milli Seconds

    Note

    User can Override the existing data source for format Data In port.

    • Right-click the required Data In port.
    • Click override and change the data source.
      To learn more about overriding the data source port, refer the override section.

    To enable display of the returned value, you can add a MessageBox component to the activity.

  5. To add the MessageBox component:

    • In the Toolbox, expand the General.
    • Expand the MessageBox component, drag the Show component and drop it on the Design surface.
  6. Connect the control ports and data ports in the activity.
  7. In the toolbar, click Run.
    The Messagebox displays the DateTime result, based on the given GetPart format.

    Screenshot