Advertisement
Guest User

Untitled

a guest
Jul 25th, 2016
47
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.86 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using System.Windows.Forms;
  7.  
  8. namespace SelectionPanel
  9. {
  10. public class SelectionPanel
  11. {
  12. private Panel selectionPanel;
  13. private Button ParseMessageButton;
  14. private Button AddTestCaseButton;
  15. private TextBox MessageTextBox;
  16. private Label MessageLabel;
  17. private Button BuildMessageButton;
  18.  
  19. public SelectionPanel()
  20. {
  21. this.selectionPanel = new Panel();
  22. this.MessageLabel = new Label();
  23. this.BuildMessageButton = new Button();
  24. this.ParseMessageButton = new Button();
  25. this.AddTestCaseButton = new Button();
  26. this.MessageTextBox = new TextBox();
  27. initializeComponents();
  28. }
  29.  
  30. private void initializeComponents()
  31. {
  32. createBuildButton();
  33. createeMessageLabel();
  34. createMessageTextBox();
  35. createParseMessageButton();
  36. createTestCaseButton();
  37. }
  38.  
  39. private void createeMessageLabel()
  40. {
  41. this.MessageLabel.AutoSize = true;
  42. this.MessageLabel.Location = new System.Drawing.Point(98, 3);
  43. this.MessageLabel.Name = "MessageLabel";
  44. this.MessageLabel.Size = new System.Drawing.Size(93, 13);
  45. this.MessageLabel.TabIndex = 4;
  46. this.MessageLabel.Text = "ISO Message field";
  47. }
  48.  
  49. private void createBuildButton()
  50. {
  51. this.BuildMessageButton.Location = new System.Drawing.Point(295, 15);
  52. this.BuildMessageButton.Name = "BuildMessageButton";
  53. this.BuildMessageButton.Size = new System.Drawing.Size(110, 24);
  54. this.BuildMessageButton.TabIndex = 3;
  55. this.BuildMessageButton.Text = "Build ISO Message";
  56. this.BuildMessageButton.UseVisualStyleBackColor = true;
  57. this.BuildMessageButton.Click += new System.EventHandler(this.BuildMessageButton_Click);
  58. }
  59.  
  60. private void BuildMessageButton_Click(object sender, EventArgs e)
  61. {
  62. MessageBox.Show("TEST");
  63. }
  64.  
  65. public void defineBuildMessageButton()
  66. {
  67.  
  68. }
  69.  
  70. private void createParseMessageButton()
  71. {
  72. this.ParseMessageButton.Location = new System.Drawing.Point(425, 15);
  73. this.ParseMessageButton.Name = "ParseMessageButton";
  74. this.ParseMessageButton.Size = new System.Drawing.Size(110, 24);
  75. this.ParseMessageButton.TabIndex = 2;
  76. this.ParseMessageButton.Text = "Parse ISO Message";
  77. this.ParseMessageButton.UseVisualStyleBackColor = true;
  78. this.ParseMessageButton.Click += new System.EventHandler(this.ParseMessageButton_Click);
  79. }
  80.  
  81. private void ParseMessageButton_Click(object sender, EventArgs e)
  82. {
  83.  
  84. }
  85.  
  86. private void createTestCaseButton()
  87. {
  88. this.AddTestCaseButton.Location = new System.Drawing.Point(554, 15);
  89. this.AddTestCaseButton.Name = "AddTestCaseButton";
  90. this.AddTestCaseButton.Size = new System.Drawing.Size(110, 24);
  91. this.AddTestCaseButton.TabIndex = 1;
  92. this.AddTestCaseButton.Text = "Add Test Case";
  93. this.AddTestCaseButton.UseVisualStyleBackColor = true;
  94. this.AddTestCaseButton.Click += new System.EventHandler(this.AddTestCaseButton_Click);
  95. }
  96.  
  97. private void AddTestCaseButton_Click(object sender, EventArgs e)
  98. {
  99.  
  100. }
  101.  
  102. private void createMessageTextBox()
  103. {
  104. this.MessageTextBox.Location = new System.Drawing.Point(14, 19);
  105. this.MessageTextBox.Name = "MessageTextBox";
  106. this.MessageTextBox.Size = new System.Drawing.Size(266, 20);
  107. this.MessageTextBox.TabIndex = 0;
  108. this.MessageTextBox.TextChanged += new System.EventHandler(this.MessageTextBox_TextChanged);
  109. }
  110.  
  111. private void MessageTextBox_TextChanged(object sender, EventArgs e)
  112. {
  113.  
  114. }
  115.  
  116.  
  117. public Panel createPanel()
  118. {
  119. this.selectionPanel.Controls.Add(this.MessageLabel);
  120. this.selectionPanel.Controls.Add(this.BuildMessageButton);
  121. this.selectionPanel.Controls.Add(this.ParseMessageButton);
  122. this.selectionPanel.Controls.Add(this.AddTestCaseButton);
  123. this.selectionPanel.Controls.Add(this.MessageTextBox);
  124. this.selectionPanel.Location = new System.Drawing.Point(13, 13);
  125. this.selectionPanel.Name = "SelectionPanel";
  126. this.selectionPanel.Size = new System.Drawing.Size(SystemInformation.VirtualScreen.Width, 45);
  127. this.selectionPanel.TabIndex = 0;
  128. return this.selectionPanel;
  129. }
  130. }
  131. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement