char[] Permissions = PermissionSet.ToCharArray();
chkAllowStoreFiles.Checked = Permissions[0] == '1';
chkAllowStoreFolders.Checked = Permissions[1] == '1';
chkAllowRenameFiles.Checked = Permissions[2] == '1';
chkAllowRenameFolders.Checked = Permissions[3] == '1';
chkAllowDeleteFiles.Checked = Permissions[4] == '1';
chkAllowDeleteFolders.Checked = Permissions[5] == '1';
chkAllowCopyFiles.Checked = Permissions[6] == '1';
chkAllowViewHiddenFiles.Checked = Permissions[7] == '1';
chkAllowViewHiddenFolders.Checked = Permissions[8] == '1';
}//为用户设置权限的初始值,1为打勾。
else
{
MessageBox.Show("The user with the name " + OldUserName + " dose not exist.", "Advanced FTP Server");
DialogResult = DialogResult.OK;
Close();
}
}
void BrowseRootFolder_Click(object sender, EventArgs e)
{
FolderBrowserDialog FBD = new FolderBrowserDialog();
FBD.Description = "Select the Root Folder for the user";
FBD.ShowNewFolderButton = true;
FBD.SelectedPath = txtStartUpPath.Text;
if (FBD.ShowDialog() == DialogResult.Cancel) return;
txtStartUpPath.Text = FBD.SelectedPath;
}//选择启动路径
void SaveUser_Click(object sender, EventArgs e)
{
txtUserName.Text = txtUserName.Text.Trim();
txtStartUpPath.Text = txtStartUpPath.Text.Trim();
string Message = string.Empty;
if (txtUserName.Text.Length < 2) Message = "User Name cannot be lesser than 2 chars\n ";
- 上一篇:造币机械生产车间信息管理系统分析与研究
- 下一篇:C#的家庭理财系统软件设计+ER图
-
-
-
-
-
-
-
电站锅炉暖风器设计任务书
河岸冲刷和泥沙淤积的监测国内外研究现状
杂拟谷盗体内共生菌沃尔...
十二层带中心支撑钢结构...
酸性水汽提装置总汽提塔设计+CAD图纸
java+mysql车辆管理系统的设计+源代码
当代大学生慈善意识研究+文献综述
乳业同业并购式全产业链...
大众媒体对公共政策制定的影响
中考体育项目与体育教学合理结合的研究