简体   繁体   中英

c# Passing an index of a list item from one form to another

In c#, how do you write the code so that when a user select an item in list box and click edit, it's data displays in separate textboxes in another windows form? I'm guessing the passing of the selected index between the two forms is required.

I think you can create a Form and set a String property. Every time you click edit button, just pass that item's text to the Form's contructor.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM