# Vline and hline don't work with ticks=:native Plotly

**URL:** <https://discourse.julialang.org/t/vline-and-hline-dont-work-with-ticks-native-plotly/81509>\
**Category:** General Usage\
**Tags:** question, bug, plots, plotlyjs\
**Created:** [May 23, 2022, 12:54pm UTC](https://discourse.julialang.org/t/vline-and-hline-dont-work-with-ticks-native-plotly/81509 "2022-05-23T12:54:02Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Wikunia](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/wikunia/32/2180_2.png) [@Wikunia](https://discourse.julialang.org/u/Wikunia)\
**Post date:** [May 23, 2022, 12:54pm UTC](https://discourse.julialang.org/t/vline-and-hline-dont-work-with-ticks-native-plotly/81509/1 "2022-05-23T12:54:02Z")

</div>

It seems like vline and hline have problems with `ticks=:native` in Plotly.

```julia
using Plots
plotly()
plt1 = plot(ticks=:native)
plot!(plt1, [now()], [1])
vline!(plt1, [now()])

```

Doesn’t work but without the `vline!` it does. The error is:

Failed to show value:

```julia
InexactError: Int64(NaN)

```

1. **Int64** @ _float.jl:812_ [inlined]
2. **convert** @ _number.jl:7_ [inlined]
3. **Millisecond** @ _types.jl:61_ [inlined]
4. **UTM** @ _types.jl:103_ [inlined]
5. **datetimeformatter** @ _recipes.jl:7_ [inlined]  
…

Similarly with `hline` which shouldn’t be affected by `DateTime` but seem to be affected by it.

---

<div class="post-metadata">

**Author:** ![rafael.guerra](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rafael.guerra/32/216610_2.png) [@rafael.guerra](https://discourse.julialang.org/u/rafael.guerra)\
**Post date:** [May 23, 2022, 5:34pm UTC](https://discourse.julialang.org/t/vline-and-hline-dont-work-with-ticks-native-plotly/81509/2 "2022-05-23T17:34:14Z")

</div>

Sounds like [this bug here](https://github.com/JuliaPlots/Plots.jl/issues/4176).
