🔒 Closed C# usercontrol and form problem

Status
Not open for further replies.

FourBytes

Honorary Poster
Dear phc,
I have a problem with linking these two.
I created a usercontrol and a form. Inside the form code i declare a -public string itemID- the value of that variable will change when i click a certain button in the usercontrol. Here is the code and this code is inside the usercontrol code:
Screenshot (22).webp

And this one is inside the form Screenshot (23).webpScreenshot (24).webp

The problem is that the value showing is still null and does not change at all. Will you help me with this one? Thanks in advance.
 
You have instantiated your form_specs_burger twice in your filet_click event, hence the initialization of your variable resets to null.
 
Status
Not open for further replies.

About this Thread

  • 3
    Replies
  • 419
    Views
  • 2
    Participants
Last reply from:
aa1012

Trending Topics

Online now

Members online
409
Guests online
2,393
Total visitors
2,802

Forum statistics

Threads
2,331,537
Posts
29,258,780
Members
1,149,683
Latest member
xcalibur
Back
Top