using
System;
using
System.Collections.Generic;
using
System.ComponentModel;
using
System.Data;
using
System.Drawing;
using
System.Linq;
using
System.Text;
using
System.Threading.Tasks;
using
System.Windows.Forms;
namespace
WindowsFormsApp34 {
public
partial
class
Form1 : Form {
public
Form1()
{
InitializeComponent();
}
private
void
Form1_Load(
object
sender, EventArgs e)
{
Label l1 =
new
Label();
l1.Location =
new
Point(140, 122);
l1.Text = "Name";
this
.Controls.Add(l1);
TextBox box1 =
new
TextBox();
box1.Location =
new
Point(248, 119);
box1.BorderStyle = BorderStyle.FixedSingle;
this
.Controls.Add(box1);
Label l2 =
new
Label();
l2.Location =
new
Point(140, 152);
l2.Text = "Password";
this
.Controls.Add(l2);
TextBox box2 =
new
TextBox();
box2.Location =
new
Point(248, 145);
box2.BorderStyle = BorderStyle.FixedSingle;
this
.Controls.Add(box2);
ToolTip t_Tip =
new
ToolTip();
t_Tip.Active =
true
;
t_Tip.AutoPopDelay = 4000;
t_Tip.InitialDelay = 600;
t_Tip.IsBalloon =
true
;
t_Tip.ToolTipIcon = ToolTipIcon.Info;
t_Tip.SetToolTip(box1, "Name should start with Capital letter");
t_Tip.SetToolTip(box2, "Password should be greater than 8 words");
}
}
}