Dashboards & Visualizations

How to disable options in the time range picker through XML source code?

saransakthi83
New Member

I need turn off all timerange options in time picker menu through XML source code

0 Karma

Raghav2384
Motivator

Hello,

If you don't want time picker and yet give pre-defined time ranges to users, add the following xml below <form.......> tag

<fieldset submitButton="false">
    <input type="dropdown" token="earliestTime" searchWhenChanged="true">
      <label>Select a TimeWindow</label>
       <choice value="-24h@h">24 Hour Window</choice>
    <choice value="-48h@h">48 Hour Window</choice>
    <choice value="-72h@h">72 Hour Window</choice>
    <choice value="-7d@d">7 Day Window</choice>
    <default>24 Hour Window</default>

    </input>
  </fieldset>

Then you need to reference the token for each search/panel example: <earliest>$earliestTime$</earliest> etc. And offcourse you can modify the above xml snippet to match your requirements.

Hope this Helps!

Thanks,
Raghav

0 Karma
Get Updates on the Splunk Community!

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...

Splunk Custom Visualizations App End of Life

The Splunk Custom Visualizations apps End of Life for SimpleXML will reach end of support on Dec 21, 2024, ...