<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to populate one time picker based on the selection of another time picker? in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600428#M49305</link>
    <description>&lt;P&gt;How can I achieve that using&amp;nbsp;&lt;SPAN&gt;change handler of timer1? Please share the code so that I can understand.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 03 Jun 2022 09:44:32 GMT</pubDate>
    <dc:creator>mnj1809</dc:creator>
    <dc:date>2022-06-03T09:44:32Z</dc:date>
    <item>
      <title>How to populate one time picker based on the selection of another time picker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600353#M49298</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;I've a requirement to populate the "Time2" time picker to be updated automatically based on the selection of "Time1" time picker. The "Time2" time picker should be = Time1- 1 day. for example, if I choose Today in Time1 then Time2 should be automatically populated as "Last 1 day". If I choose Yesterday in Time1 then Time2 should be automatically populated as "Last 2 days" (starting from 12:00 AM day before yesterday till end of yesterday.)&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mnj1809_0-1654202151115.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/19923i6ACAD7B68FCA5D51/image-size/medium?v=v2&amp;amp;px=400" role="button" title="mnj1809_0-1654202151115.png" alt="mnj1809_0-1654202151115.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/6367"&gt;@bowesmana&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jun 2022 21:52:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600353#M49298</guid>
      <dc:creator>mnj1809</dc:creator>
      <dc:date>2022-06-02T21:52:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to populate one time picker based on the selection of another time picker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600415#M49304</link>
      <description>&lt;P&gt;If you need a second pair of earliest and latest tokens, why not create this in the change handler of timer1?&lt;/P&gt;</description>
      <pubDate>Fri, 03 Jun 2022 09:19:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600415#M49304</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-06-03T09:19:48Z</dc:date>
    </item>
    <item>
      <title>Re: How to populate one time picker based on the selection of another time picker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600428#M49305</link>
      <description>&lt;P&gt;How can I achieve that using&amp;nbsp;&lt;SPAN&gt;change handler of timer1? Please share the code so that I can understand.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Jun 2022 09:44:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600428#M49305</guid>
      <dc:creator>mnj1809</dc:creator>
      <dc:date>2022-06-03T09:44:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to populate one time picker based on the selection of another time picker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600435#M49306</link>
      <description>&lt;P&gt;Try something like this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;    &amp;lt;input type="time" token="timepicker" searchWhenChanged="true"&amp;gt;
      &amp;lt;label&amp;gt;&amp;lt;/label&amp;gt;
      &amp;lt;default&amp;gt;
        &amp;lt;earliest&amp;gt;-24h@h&amp;lt;/earliest&amp;gt;
        &amp;lt;latest&amp;gt;now&amp;lt;/latest&amp;gt;
      &amp;lt;/default&amp;gt;
      &amp;lt;change&amp;gt;
        &amp;lt;condition&amp;gt;
          &amp;lt;eval token="earliestdaybefore"&amp;gt;relative_time(relative_time(now(),$timepicker.earliest$),"-1d")&amp;lt;/eval&amp;gt;
          &amp;lt;eval token="latestdaybefore"&amp;gt;relative_time(relative_time(now(),$timepicker.latest$),"-1d")&amp;lt;/eval&amp;gt;
        &amp;lt;/condition&amp;gt;
      &amp;lt;/change&amp;gt;
    &amp;lt;/input&amp;gt;&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 03 Jun 2022 10:03:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600435#M49306</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-06-03T10:03:51Z</dc:date>
    </item>
    <item>
      <title>Re: How to populate one time picker based on the selection of another time picker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600461#M49307</link>
      <description>&lt;P&gt;Thanks mate. It helped me.&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Jun 2022 12:24:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600461#M49307</guid>
      <dc:creator>mnj1809</dc:creator>
      <dc:date>2022-06-03T12:24:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to populate one time picker based on the selection of another time picker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600604#M49326</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I tried to set a default time on page load but I am getting below error:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mnj1809_0-1654427601710.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/19948i9A4D0575DEA3B0D0/image-size/medium?v=v2&amp;amp;px=400" role="button" title="mnj1809_0-1654427601710.png" alt="mnj1809_0-1654427601710.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Dashboard XML:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;form&amp;gt;&lt;BR /&gt;&amp;lt;label&amp;gt;Display Time Picker&amp;lt;/label&amp;gt;&lt;BR /&gt;&amp;lt;init&amp;gt;&lt;BR /&gt;&amp;lt;set token="earliestdaybefore"&amp;gt;-1d@d&amp;lt;/set&amp;gt;&lt;BR /&gt;&amp;lt;set token="latestdaybefore"&amp;gt;@d&amp;lt;/set&amp;gt;&lt;BR /&gt;&amp;lt;/init&amp;gt;&lt;BR /&gt;&amp;lt;fieldset submitButton="false"&amp;gt;&lt;BR /&gt;&amp;lt;input type="time" token="time" searchWhenChanged="true"&amp;gt;&lt;BR /&gt;&amp;lt;label&amp;gt;HVA Timeframe&amp;lt;/label&amp;gt;&lt;BR /&gt;&amp;lt;default&amp;gt;&lt;BR /&gt;&amp;lt;earliest&amp;gt;@d&amp;lt;/earliest&amp;gt;&lt;BR /&gt;&amp;lt;latest&amp;gt;now&amp;lt;/latest&amp;gt;&lt;BR /&gt;&amp;lt;/default&amp;gt;&lt;BR /&gt;&amp;lt;change&amp;gt;&lt;BR /&gt;&amp;lt;condition&amp;gt;&lt;BR /&gt;&amp;lt;eval token="earliestdaybefore"&amp;gt;relative_time(relative_time(now(),$time.earliest$),"-1d")&amp;lt;/eval&amp;gt;&lt;BR /&gt;&amp;lt;eval token="latestdaybefore"&amp;gt;relative_time(relative_time(now(),$time.latest$),"-1d")&amp;lt;/eval&amp;gt;&lt;BR /&gt;&amp;lt;/condition&amp;gt;&lt;BR /&gt;&amp;lt;/change&amp;gt;&lt;BR /&gt;&amp;lt;/input&amp;gt;&lt;BR /&gt;&amp;lt;/fieldset&amp;gt;&lt;BR /&gt;&amp;lt;row&amp;gt;&lt;BR /&gt;&amp;lt;panel&amp;gt;&lt;BR /&gt;&amp;lt;title&amp;gt;Previous Dates&amp;lt;/title&amp;gt;&lt;BR /&gt;&amp;lt;table&amp;gt;&lt;BR /&gt;&amp;lt;search&amp;gt;&lt;BR /&gt;&amp;lt;query&amp;gt;| makeresults&lt;BR /&gt;| eval earliestdaybefore= $earliestdaybefore$,&lt;BR /&gt;latestdaybefore=$latestdaybefore$&lt;BR /&gt;| eval earliest_time=strftime(earliestdaybefore,"%Y-%m-%dT%H:%M:%S"),&lt;BR /&gt;latest_time=strftime(latestdaybefore,"%Y-%m-%dT%H:%M:%S")&lt;BR /&gt;| table earliest_time, latest_time, earliestdaybefore, latestdaybefore&lt;BR /&gt;| fields - _time&amp;lt;/query&amp;gt;&lt;BR /&gt;&amp;lt;earliest&amp;gt;$earliestdaybefore$&amp;lt;/earliest&amp;gt;&lt;BR /&gt;&amp;lt;latest&amp;gt;$latestdaybefore$&amp;lt;/latest&amp;gt;&lt;BR /&gt;&amp;lt;/search&amp;gt;&lt;BR /&gt;&amp;lt;option name="drilldown"&amp;gt;none&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="refresh.display"&amp;gt;progressbar&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;/table&amp;gt;&lt;BR /&gt;&amp;lt;/panel&amp;gt;&lt;BR /&gt;&amp;lt;/row&amp;gt;&lt;BR /&gt;&amp;lt;/form&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 05 Jun 2022 11:16:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600604#M49326</guid>
      <dc:creator>mnj1809</dc:creator>
      <dc:date>2022-06-05T11:16:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to populate one time picker based on the selection of another time picker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600609#M49327</link>
      <description>&lt;P&gt;Change the token initialisation&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;init&amp;gt;
&amp;lt;eval token="earliestdaybefore"&amp;gt;relative_time(now(),"-1d@d")&amp;lt;/eval&amp;gt;
&amp;lt;eval token="latestdaybefore"&amp;gt;relative_time(now(),"@d")&amp;lt;/eval&amp;gt;
&amp;lt;/init&amp;gt;&lt;/LI-CODE&gt;</description>
      <pubDate>Sun, 05 Jun 2022 12:25:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600609#M49327</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-06-05T12:25:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to populate one time picker based on the selection of another time picker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600611#M49328</link>
      <description>&lt;P&gt;Thanks, It works &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;BR /&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 05 Jun 2022 12:30:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600611#M49328</guid>
      <dc:creator>mnj1809</dc:creator>
      <dc:date>2022-06-05T12:30:01Z</dc:date>
    </item>
    <item>
      <title>Re: How to populate one time picker based on the selection of another time picker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600633#M49329</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;The solution you provided to me is working well over my local environment (time zone is IST). I am successfully able to get the previous date wrt what is selected in the time picker.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mnj1809_4-1654455709561.png" style="width: 777px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/19955i2C46A01ED23A66E3/image-dimensions/777x96?v=v2" width="777" height="96" role="button" title="mnj1809_4-1654455709561.png" alt="mnj1809_4-1654455709561.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But over my production environment (time zone is EST), it's not showing me the correct timestamp.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mnj1809_5-1654456256036.png" style="width: 784px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/19956i2CD28655F5498895/image-dimensions/784x98?v=v2" width="784" height="98" role="button" title="mnj1809_5-1654456256036.png" alt="mnj1809_5-1654456256036.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Please suggest.&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 05 Jun 2022 19:12:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-populate-one-time-picker-based-on-the-selection-of/m-p/600633#M49329</guid>
      <dc:creator>mnj1809</dc:creator>
      <dc:date>2022-06-05T19:12:26Z</dc:date>
    </item>
  </channel>
</rss>

