<%@ Import Namespace="HTCOMNET.Main" %>
<%@ Page Language="vb" AutoEventWireup="false" Codebehind="groupsaccounts.aspx.vb" Inherits="HTCOMNET.groupsaccounts"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
	<HEAD>
		<title>Groups</title>
		<META content="NOINDEX,NOFOLLOW" name="ROBOTS">
		<META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE">
		<meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
		<meta content="Visual Basic .NET 7.1" name="CODE_LANGUAGE">
		<meta content="JavaScript" name="vs_defaultClientScript">
		<meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
	</HEAD>
	<body text="#ffffff" bgColor="#5a7dde">
		<strong><A href="adminpanel.aspx"><font face="Verdana, Arial, Helvetica, sans-serif" color="#ffffff" size="3">
					back to the Admin panel</font></A></strong><BR>
		<div id="NEtFrameworkNotInstalled" runat="server"><font size="3" face="Arial" color="#ffffff"><b>If 
					you see this label then you need to install .NET Framework 1.1 on the server 
					for correct running .ASPX pages. See ReadMe.htm</b></font></div>
		<form id="Form1" runat="server">
			<A href="usersaccounts.aspx"><IMG height="26" src="images/usgr.gif" width="21" border="0"></A>&nbsp;<A href="usersaccounts.aspx"><STRONG><FONT face="Verdana, Arial, Helvetica, sans-serif" color="#33ff99" size="4">View 
						Users</FONT></STRONG></A>
			<div id="INPUT" runat="server"><asp:label id="lblinfo" Text="" Runat="server" Font-Size="18px" ForeColor="#ffcc00" Font-Bold="True"></asp:label><BR>
				<BR>
				<asp:panel id="Panel1" Runat="server" Height="100" Width="600px" BorderStyle="Ridge" BorderWidth="1px">
					<STRONG><FONT face="Verdana, Arial, Helvetica, sans-serif" color="#ffffff" size="3">&nbsp;&nbsp;Add 
							new group:</FONT></STRONG><BR>
					<BR>
					<DIV align="center">
						<asp:table id="Table1" runat="server" BorderWidth="0px" BorderStyle="Solid" width="600px" cellPadding="5"
							GridLines="Both">
							<asp:TableRow Runat="server" ID="Tablerow1">
								<asp:TableCell Width="80" ID="UsernameCell" Runat="server">Group name:</asp:TableCell>
								<asp:TableCell Runat="server" ID="Tablecell1" name="Tablecell1">
									<asp:TextBox ID="inputname" Runat="server" MaxLength="255" width="150"></asp:TextBox>
								</asp:TableCell>
							</asp:TableRow>
						</asp:table><BR>
					</DIV>
					<TABLE width="600" border="0">
						<TR>
							<TD width="15" height="50"></TD>
							<TD>
								<asp:Button id="addnewgroupbutton" onclick="AddNewGroup" Runat="server" Text="Add group" name="Button1"></asp:Button></TD>
						</TR>
					</TABLE>
				</asp:panel><BR>
				<STRONG><FONT face="Verdana, Arial, Helvetica, sans-serif" color="#ffffff" size="3">&nbsp;&nbsp;Current 
						groups:</FONT></STRONG>
				<asp:datagrid id="grid" runat="server" Width="600px" BorderWidth="1px" CellPadding="10" BorderColor="Gainsboro"
					AllowSorting="True" AutoGenerateColumns="False" OnSortCommand="gridusers_SortCommand" OnEditCommand="gridusers_EditCommand"
					OnCancelCommand="gridusers_CancelCommand" OnUpdateCommand="gridusers_UpdateCommand" OnDeleteCommand="gridusers_DeleteCommand"
					PagerStyle-Font-Bold="True" PagerStyle-Font-Size="18px" PagerStyle-Mode="NumericPages" PagerStyle-ForeColor="#000000">
					<Columns>
						<asp:BoundColumn DataField="name" Visible="False" ReadOnly="True"></asp:BoundColumn>
						<asp:TemplateColumn SortExpression="name" HeaderText="Group name">
							<ItemStyle Font-Size="18px"></ItemStyle>
							<ItemTemplate>
								<%# Container.DataItem("name") %>
							</ItemTemplate>
							<EditItemTemplate>
								<asp:Literal Text='<%# Container.DataItem("name") %>' ID="txtoldname" Runat=server Visible=False />
								<asp:TextBox Text='<%# Container.DataItem("name") %>' id="txtname" runat=server /><br>
							</EditItemTemplate>
						</asp:TemplateColumn>
						<asp:EditCommandColumn ButtonType="PushButton" UpdateText="Update" CancelText="Cancel" EditText="Change name"></asp:EditCommandColumn>
						<asp:TemplateColumn>
							<ItemTemplate>
								<asp:Button CommandArgument='<%# Container.DataItem("name") %>' OnCommand="SelectBtn_Click" CommandName="Select" Runat="server" id="butselect" Text="View members" />
							</ItemTemplate>
						</asp:TemplateColumn>
						<asp:TemplateColumn>
							<ItemTemplate>
								<asp:Button CommandName="Delete" Runat="server" id="butDelete" Text="Delete this group!" />
							</ItemTemplate>
						</asp:TemplateColumn>
					</Columns>
					<PagerStyle Font-Size="18px" Font-Bold="True" ForeColor="Black" Mode="NumericPages"></PagerStyle>
				</asp:datagrid><br>
				<BR>
				Comment: Database stored in
				<asp:label id="shownUSERSANDGROUPSINFOFILE" Runat="server"></asp:label>file.<BR>
				<a href="mailto:sprunsky@http-com.com"><font color="#ffffff">Developer</font></a>
				can modify code for correct work with your own users and folders database!
			</div>
			<div id="ADMININPUT" runat="server"><font color="#ff9933"><b><asp:literal id="WRONGCOMBINATION" runat="server"></asp:literal></b></font><BR>
				Enter Administrator's name and password<br>
				<br>
				<table width="500" border="0">
					<tr>
						<td width="112">Name:</td>
						<td width="378"><input id="inputadminname" type="text" name="name" runat="server"></td>
					</tr>
					<tr>
						<td>Password:</td>
						<td><input id="inputadminpass" type="password" name="password" runat="server"></td>
					</tr>
				</table>
				<br>
				<asp:button id="sendnamepass" onclick="CheckAdminNamepass" runat="server" text="submit"></asp:button><br>
				<br>
				<br>
			</div>
			<asp:literal id="output" Runat="server"></asp:literal></form>
	</body>
</HTML>
