[C#問題] Form值互傳

作者: MOONY135 (談無慾)   2016-03-14 18:44:44
※ [本文轉錄自 C_Sharp 看板 #1MvfO6j3 ]
作者: MOONY135 (談無慾) 看板: C_Sharp
標題: [問題] Form值互傳
時間: Mon Mar 14 18:44:15 2016
想實作資料流是 FORM1 -> FORM2 -> FORM1
以下是結果
https://goo.gl/tgx3Bo
https://goo.gl/HYHddz
這是我的code Form1
https://gist.github.com/Aix-Shiao/85056db8bf235d6a9c0d
Form2
https://gist.github.com/Aix-Shiao/e002c526b91c54e4cc4b
然後我又看到這篇文章
https://dotblogs.com.tw/larrynung/archive/2009/03/24/7669.aspx
但我看不懂
Public Class Form2
{
...
Public Form1 MainForm;
...
//'Form2透過Form1傳進的物件參考控制Form1
MainForm.Value = this.NumericUpDown1.Value;
...
}
這段是甚麼意思 不知道有沒有人可以幫幫我 MainForm是一個特殊的物件嗎?
另外想請問如果有很多值要傳來傳去 那我的做法就沒有那麼好了
請問有沒有更好的方法

Links booklink

Contact Us: admin [ a t ] ucptt.com