protected void CreateUserWizard1_CreatingUser(object sender, LoginCancelEventArgs e) { TextBox tb = ((TextBox)CreateUserWizard1.CreateUserStep.ContentTemplateContainer.FindControl("TextBox1")); if (tb.Text != "") { e.Cancel = true; } }