Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3631380
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T00:23:23+00:00 2026-05-19T00:23:23+00:00

I will have a text box where user can enter 0-9999 . If the

  • 0

I will have a text box where user can enter 0-9999 . If the user enters 10 i would like to load a Form. This form will have some controls and buttons namely Save . If user enter data and click on save i would like to clear the fields and have to show that form again up to the number of times(as per i said 10) corresponding to the value entered by the user in the textbox.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T00:23:23+00:00Added an answer on May 19, 2026 at 12:23 am

    instead of showing the form 0-9999 times, you could pass the value (0-9999) to the form, and clear the fields on that form for 0-9999 times after user click on save and then close it.

    e.g:

    //on main form:
    int i = 0; 
    //parse the textbox1.text to int and check the result:
    if(!int.TryParse(textbox1.Text,out i)||i<0||i>9999)
    {
      //incorrect int value 
      MessageBox.Show("Please enter a valid value");
    }
    else //correct int value
    {
      subform mysub=new subform(i);
      subform.ShowDialog();
    }
    //on your subform:
    int timebeforeclose=0;
    public subform(int count)
    {
      timebeforeclose=count;
    }
    
    private void btnSave_Click(object sender, EventArgs e)
    {
      //1.save your data or whatever...
      //2.empty any fields you want..
      //update timebeforeclose:
      timebeforeclose--;
      //check the timebeforeclose:
    
      if(timebeforeclose==0)
      {
        this.Close(); //close this form when reaches the specified number.
      }      
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How can I have a datagridview that will autogenerate a textbox instead of a
Most python frameworks will have a development webserver of some kind that will have
I'm building a class library that will have some public & private methods. I
In Visual Studio as most of you will have noticed that related file can
Rules like A parent object will have up to 2 children could be enforced
I want to create a form which has a text entry box where a
I have a table where I display some information for a user to approve
I have extended a MaskedTextBox component to add some functionality. The text property of
I have a few text boxes and buttons on my form. Lets say txtBox1
i have the following jquery code. basically i will have several overlapped divs and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.