# How to set DateTimeInput None?

**URL:** <https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912>\
**Category:** Ignition\
**Tags:** perspective\
**Created:** [May 25, 2024, 11:46am UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912 "2024-05-25T11:46:21Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![taohongyu88](https://avatars.discourse-cdn.com/v4/letter/t/f05b48/32.png) [@taohongyu88](https://forum.inductiveautomation.com/u/taohongyu88)\
**Post date:** [May 25, 2024, 11:46am UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/1 "2024-05-25T11:46:21Z")

</div>

When I use DateTimeInput , edit of EndTime, How to set it None?  
I have to add a button , set value=None.

![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/8/e/8e744248539f7c9403f8984e45fee5bf240ec6f2.png)

Is there any other function or property by it self?

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [May 25, 2024, 11:57am UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/2 "2024-05-25T11:57:39Z")

</div>

![Clear datepicker](https://us1.discourse-cdn.com/inductiveautomation/original/3X/e/f/ef16d4973221e33543bd95653cf7f547f1bd971d.png)

1. Configure Events ... on the button. (You know this.)
2. Use onActionPerformed instead of onClick. onClick events always fire - even if the button is disabled. onActionPerformed events only fire if the button is enabled.
3. Script. (You know this.)
4. Use the Browse Properties button to find the path to the date picker.
5. The chosen path.

`self.getSibling("DateTimeInput").props.value = None`

You can also use [Component Message Handlers | Ignition User Manual](https://docs.inductiveautomation.com/docs/8.1/ignition-modules/perspective/scripting-in-perspective/component-message-handlers) if the path is complicated. It avoids all the getSibling / getChild path complexity.

---

<div class="post-metadata">

**Author:** ![taohongyu88](https://avatars.discourse-cdn.com/v4/letter/t/f05b48/32.png) [@taohongyu88](https://forum.inductiveautomation.com/u/taohongyu88)\
**Post date:** [May 25, 2024, 12:02pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/3 "2024-05-25T12:02:09Z")

</div>

Thank you!  
I want to know is there other idea in [DateTimeInput],  
not need to add a button?

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [May 25, 2024, 12:06pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/4 "2024-05-25T12:06:15Z")

</div>

The sensible thing to do is clear the date on view startup.  
You could also clear the date after the user presses the Submit button.

---

<div class="post-metadata">

**Author:** ![taohongyu88](https://avatars.discourse-cdn.com/v4/letter/t/f05b48/32.png) [@taohongyu88](https://forum.inductiveautomation.com/u/taohongyu88)\
**Post date:** [May 25, 2024, 12:13pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/5 "2024-05-25T12:13:34Z")

</div>

I already read endDT from mysql.  
This window is Edit .  
I want to clear this EndDate.  
But I find no way to clear this EndDate by it self.  
So I need to add a button to clear.  
In the Submit button I can't know the customer's clear or change demand.  
My Question is there other way to clear this EndDate by it self, not add a button?

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [May 25, 2024, 12:16pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/6 "2024-05-25T12:16:01Z")

</div>

So, you want the Edit form to open with EndDate = None?

---

<div class="post-metadata">

**Author:** ![taohongyu88](https://avatars.discourse-cdn.com/v4/letter/t/f05b48/32.png) [@taohongyu88](https://forum.inductiveautomation.com/u/taohongyu88)\
**Post date:** [May 25, 2024, 12:16pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/7 "2024-05-25T12:16:29Z")

</div>

set EndDate =None or edit it to the Selected Date.

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [May 25, 2024, 12:19pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/8 "2024-05-25T12:19:43Z")

</div>

> [@taohongyu88](#):
>
> I already read endDT from MySQL.

Can you modify your SQL to return the None?

```python
SELECT
    ...,
    NULL AS EndTime,
    ....

```

---

<div class="post-metadata">

**Author:** ![taohongyu88](https://avatars.discourse-cdn.com/v4/letter/t/f05b48/32.png) [@taohongyu88](https://forum.inductiveautomation.com/u/taohongyu88)\
**Post date:** [May 25, 2024, 12:20pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/9 "2024-05-25T12:20:30Z")

</div>

Let customer edit it.  
Not read it from Mysql.

---

<div class="post-metadata">

**Author:** ![taohongyu88](https://avatars.discourse-cdn.com/v4/letter/t/f05b48/32.png) [@taohongyu88](https://forum.inductiveautomation.com/u/taohongyu88)\
**Post date:** [May 25, 2024, 12:21pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/10 "2024-05-25T12:21:52Z")

</div>

![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/5/5/55f402772a02d64956cb7f4621d6ac2aca36d62b.png)

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [May 25, 2024, 12:23pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/11 "2024-05-25T12:23:18Z")

</div>

Sorry, I don't understand what the user is supposed to see or do.

Just use a button.

---

<div class="post-metadata">

**Author:** ![VinceV](https://avatars.discourse-cdn.com/v4/letter/v/bb73d2/32.png) [@VinceV](https://forum.inductiveautomation.com/u/VinceV)\
**Post date:** [January 27, 2026, 1:40pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/12 "2026-01-27T13:40:46Z")

</div>

I realize this is a very old thread, but I’m running into somewhat of a similar issue and I don’t think this is an unreasonable request.

The main culprit is that the DateTimeInput component does not have a **built-in _clear_ button** ; once a date is set (by a binding or by manually setting it) it cannot be **unset** by the user unless you specifically script an additional button to perform that action. And yet, null is a perfectly valid input for the component, since it also has a placeholder property that is utilized when the value is null. This puts a burden on the developer, who has to go out of their way to add a workaround for something that should work out of the box.

I think this is what one might realistically expect:

 ![afbeelding](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/5/35c4b38db358f42b1dfd3d4da8b2d6356277f42c.png)

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [January 27, 2026, 2:09pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/13 "2026-01-27T14:09:12Z")

</div>

> [@VinceV](#):
>
> does not have a **built-in _clear_ button**

This is a good idea. You should make a formal feature request at [the Ideas Portal](https://ideas.inductiveautomation.com). I'll vote for it. (Put reference links here and there.)

---

<div class="post-metadata">

**Author:** ![jonathanf](https://avatars.discourse-cdn.com/v4/letter/j/eb8c5e/32.png) [@jonathanf](https://forum.inductiveautomation.com/u/jonathanf)\
**Post date:** [February 9, 2026, 5:32pm UTC](https://forum.inductiveautomation.com/t/how-to-set-datetimeinput-none/90912/14 "2026-02-09T17:32:19Z")

</div>

I will also vote for this.
