Choose the time in TextBox ASP.NET C #

1

Is it possible that in a TextBox you select only the time? Since I want to choose the time and that I get an example

  

17:36:34

Like the image:

    
asked by PieroDev 07.05.2017 в 02:47
source

2 answers

0

Good to perform we have to add a Plugin called ClockPicker so you can find it to download:

link

Quite apart we have to add both JS / JQUERY / CSS:

 <link href="assets/css/bootstrap.min.css" rel="stylesheet" />
    <link href="assets/css/github.min.css" rel="stylesheet" />
    <link href="dist/bootstrap-clockpicker.min.css" rel="stylesheet" />
    <script src="assets/js/bootstrap.min.js"></script>
    <script src="assets/js/jquery.min.js"></script>
    <script src="assets/js/highlight.min.js"></script>
    <script src="dist/jquery-clockpicker.min.js"></script>


<form id="form1" runat="server">
    <div class="container">
        <div class="form-group col-lg-2">


        <div class="input-group clockpicker" data-placement="bottom" data-alignment="left" data-donetext="Done">
           <input type="text" class="form-control" value="18:00"/>
            <span class="input-group-addon">

                    <span class="glyphicon glyphicon-time"></span>
            </span>
        </div>
            </div>

    </div>
        <script type="text/javascript">
            $('.clockpicker').clockpicker();
        </script>
    </form>
    
answered by 10.05.2017 / 04:45
source
0

In that case it will depend on the implementation of the browser.

Try using this plugin from JQuery.

$(document).ready(function(){
    $('input.timepicker').timepicker({});
});
    
answered by 08.05.2017 в 17:58