Advertisement
Guest User

Untitled

a guest
Sep 20th, 2017
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.18 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Data;
  5. using System.Drawing;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Windows.Forms;
  9. using System.IO;
  10. using System.Runtime.Serialization.Formatters.Binary;
  11.  
  12. namespace test
  13. {
  14. public partial class Form1 : Form
  15. {
  16. [Serializable]
  17. public class ore
  18. {
  19. public float Titan;
  20. public float Eperton;
  21. }
  22. ore b1 = null;
  23. ore b2 = null;
  24.  
  25. public Form1()
  26. {
  27. InitializeComponent();
  28. ore b2 = new ore();
  29. ore b1 = new ore();
  30. }
  31.  
  32. private void textBox1_TextChanged(object sender, EventArgs e)
  33. {
  34.  
  35. b1.Titan=float.Parse(textBox1.Text);
  36.  
  37.  
  38. }
  39.  
  40. private void textBox2_TextChanged(object sender, EventArgs e)
  41. {
  42.  
  43. b2.Eperton = float.Parse(textBox1.Text);
  44.  
  45. }
  46.  
  47.  
  48. private void button1_Click(object sender, EventArgs e)
  49. {
  50. List<ore> oreData = new List<ore>();
  51. oreData.Add(b1);
  52. oreData.Add(b2);
  53. }
  54. }
  55. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement