/[AnywhereTS-MSSQL]/trunk/CSDLL/frmConfigFreeServices.cs
ViewVC logotype

Contents of /trunk/CSDLL/frmConfigFreeServices.cs

Parent Directory Parent Directory | Revision Log Revision Log


Revision 4 - (show annotations) (download)
Wed Jul 11 14:19:13 2012 UTC (7 years, 7 months ago) by william
File size: 3286 byte(s)
imported from https://anywherets.svn.sourceforge.net/svnroot/anywherets/trunk/
Revision: 1
Author: beartown
Date: 3:10:40 AM, Monday, June 21, 2010
Message:
First upload. Still todo in order to get a fully working product: Replace Thinstation images with vanilla Thinstation, modify ImageDesigntimeConfig.cs, ImageRuntimeConfig.cs in order to support the Thinstation image
1 using System;
2 using System.Collections.Generic;
3 using System.ComponentModel;
4 using System.Data;
5 using System.Drawing;
6 using System.Text;
7 using System.Windows.Forms;
8 using System.Net;
9
10 namespace AnywhereTS
11 {
12 public partial class frmConfigFreeServices : Form
13 {
14 public frmConfigFreeServices()
15 {
16 InitializeComponent();
17 }
18
19 private void chkTFTPnet_CheckedChanged(object sender, EventArgs e)
20 {
21 if (chkTFTPnet.Checked)
22 {
23 cboTFTP.Enabled = true;
24 }
25 else
26 {
27 cboTFTP.Enabled = false;
28 }
29 }
30
31 private void btnOkDHCP_Click(object sender, EventArgs e)
32 {
33 // DHCP...
34 {
35 // Check valid IP pool start address
36 IPAddress ipValid;
37 if (ATSGlobals.dhcpConfig == 0) // If we are using the internal DHCP server
38 {
39 AtsDhcp.intDHCPon = 5;
40 }
41 else
42 {
43 AtsDhcp.intDHCPon = 1;
44 }
45 if (ATSGlobals.tftpConfig == 0) // If we are using the internal TFTP server
46 {
47 if (chkTFTPnet.Checked)
48 {
49 if (!IPAddress.TryParse(cboTFTP.Text, out ipValid))
50 {
51 MessageBox.Show("Please Select or enter a valid IP address");
52 {
53 cboTFTP.Focus();
54 return;
55 }
56 }
57 else
58 {
59 AtsDhcp.strTftpd32IP = cboTFTP.Text;
60 }
61 }
62 else
63 {
64 AtsDhcp.strTftpd32IP = "";
65 }
66 AtsDhcp.ConfTFTPD32(ATSGlobals.tftpConfig == 0);
67 { // Terminate this form
68 DialogResult = DialogResult.OK;
69 }
70 }
71 }
72 }
73 private void frmDHCPoptions_Load(object sender, EventArgs e)
74 {
75 helpProvider.HelpNamespace = ATSGlobals.strHelpFilePath; // Initiate helpProvider
76
77 // Disable controls that should not be used
78
79 if (ATSGlobals.tftpConfig != 0)
80 { // Other TFTP used, disable controls for internal TFTP.
81 grbTFTP.Enabled = false;
82 }
83 AtsDhcp.OpenTFTP32regKey();
84 if (AtsDhcp.strTftpd32IP == "")
85 {
86 cboTFTP.Text = "";
87 chkTFTPnet.Checked = false;
88 }
89 else
90 {
91 cboTFTP.Text = AtsDhcp.strTftpd32IP;
92 chkTFTPnet.Checked = true;
93 }
94 if (chkTFTPnet.Checked)
95 cboTFTP.Enabled = true;
96 else
97 cboTFTP.Enabled = false;
98 ProSupport.ThisComputerIp(cboTFTP,false);
99 cboTFTP.SelectedIndex = 0;
100 }
101 }
102 }

  ViewVC Help
Powered by ViewVC 1.1.22