How to use toggle button(switch)

Posted by: jr.choi on 7 October 2019, 9:36 pm EST

    • Post Options:
    • Link

    Posted 7 October 2019, 9:36 pm EST

    hi.

    I want to use toggle button.

    Could you please tell me how to use toggle button?

    Thanks.!

  • Posted 9 October 2019, 6:52 am EST

    Hello,

    Sorry but there is no separate ToogleButton control available for now.

    In order to use Toggle Button like control, you can add the InputButton of C1InputPanel components and set the ‘CheckOnClick’ property of the InputButton to True. This property will make the normal button act like a Toggle Button control. Here is the code snippet for the same:

    private void Form1_Load(object sender, EventArgs e)
    {
        InputButton togglebutton = new InputButton();
        togglebutton.Text = "Toggle Button";
        togglebutton.CheckOnClick = true;
        c1InputPanel1.Items.Add(togglebutton);
    }
    

    Regards,

    Prabhat Sharma.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels