I have a series of Windows Forms that act like a web based application. I have a form that sets a label's text to a random number and I'm trying to pass that number across other forms and be sure it updates everywhere. I don't have the ability to create a database, so that's why I'm doing that.

The issue I have is that when I move around the application and use a button to take me back to the first page that would get the random number, the code runs again and the number changes.

```
private void goToPage2_Click(object sender, EventArgs e) 
{
    this.Hide();
    var form3 = new FORM3();
    form3.ShowDialog();
    this.Close();
}

```

I've commented out the Close and tried Show instead of ShowDialog, but the app crashes. 

Basically I just need to figure out how to go about detecting if the form has already been created once in the application's life for that time and only have the random code run that time and not every time I come back to the page via just using the app like I want it used.

I'm using Windows Forms to save time as it's just for demonstrational purposes and don't want to deal with CSS and Bootstrap. 

Thanks.