Initial commit of version 0.9.5.2; no older versions exist for this repo.

This commit is contained in:
2016-11-05 12:02:02 -05:00
parent ea2f5b8a59
commit 98b3626154
111 changed files with 97171 additions and 0 deletions
@@ -0,0 +1,17 @@
using System;
using System.Collections.Generic;
using System.Data.OleDb;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AdvertsingProfitControl
{
internal class ApcDatabaseWriter
{
private readonly FrmLogConsole _logConsole = FrmLogConsole.GetStaticInstance;
private OleDbConnection oleDbConnection;
}
}
@@ -0,0 +1,25 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
internal class AdItemCollectionModel
{
private readonly List<string> AdItemCollection = new List<string>();
private readonly AutoCompleteStringCollection TrimmedAdItemCollection = new AutoCompleteStringCollection();
private readonly AutoCompleteStringCollection UsedAdItemCollection = new AutoCompleteStringCollection();
public AdItemCollectionModel()
{
//Start with filling the AdItemCollection array with the items from the database.
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
AdItemCollection = databaseReader.GetAdItemsSuggestionList(databaseTracker.DatabaseConnectionString);
}
}
}
@@ -0,0 +1,298 @@
using System;
using System.Drawing;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
internal class AdvertisingProfitControlTableHelper
{
/// <summary>
/// Paints rows according to their RowAttribute and detects whether or not they are part of a group.
/// This function offers a faster method of determining all of this by starting at the row index that
/// fired the row leave even. As opposed to the PaintRowGroups function which spins through all the
/// DataGridView's rows.
/// </summary>
/// <param name="startingIndex">The starting index (the row that fired the RowLeave event)</param>
/// <param name="dataGridView">The DataGridView to parse.</param>
public void PaintRowGroupsFromIndex(int startingIndex, DataGridView dataGridView)
{
var parser = new RowParsing();
int isHeaderColumn;
int isMemberColumn;
int adSpecialColumn;
if (dataGridView.Columns.Count == Enum.GetNames(typeof(SalesTableColumns)).Length)
{
isHeaderColumn = (int) SalesTableColumns.IsHeaderRow;
isMemberColumn = (int) SalesTableColumns.IsMemberRow;
adSpecialColumn = (int) SalesTableColumns.IsAdSpecialRow;
}
else
{
isHeaderColumn = (int)InventoryTableColumns.IsHeaderRow;
isMemberColumn = (int)InventoryTableColumns.IsMemberRow;
adSpecialColumn = (int) InventoryTableColumns.IsAdSpecialRow;
}
//If the current row is an Ad Special Row, the color code it and return as nothing further needs to be done.
if (parser.CheckForGroupKeyWord(dataGridView.Rows[startingIndex].Cells[(int) SalesTableColumns.AdItem].EditedFormattedValue.ToString()) != "NoGroupFound")
{
dataGridView.Rows[startingIndex].Cells[adSpecialColumn].Value = true;
dataGridView.Rows[startingIndex].DefaultCellStyle.BackColor = Color.Silver;
return;
}
//Spin through the dataGridView rows starting at the row that fired the event.
for (var i = startingIndex; i < (dataGridView.RowCount - 1); i++)
{
//Get the status of the current row.
var rowStatus = parser.GetRowAttribute(dataGridView.Rows[i]);
//IF the current row is a header row...
if (rowStatus == RowAttribute.HeaderRow)
{
//Then check to see if the next row is a row header.
rowStatus = parser.GetRowAttribute(dataGridView.Rows[i + 1]);
//IF so, color code this row as White, since it is not a true group header.
if (rowStatus != RowAttribute.HeaderRow)
{
//Clear the current row of its attributes.
dataGridView.Rows[i].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[i].Cells[isMemberColumn].Value = false;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.White;
}
//IF the current row is not the first row in the data grid (index zero)...
if (i > 0)
{
//The start by checking the previous row's status.
rowStatus = parser.GetRowAttribute(dataGridView.Rows[i - 1]);
//IF the previous row is a header row OR if the previous row is index zero AND a member row, clear its coloring.
if (rowStatus == RowAttribute.HeaderRow || rowStatus == RowAttribute.MemberRow && (i - 1) == 0)
{
//Clear the previous row of its attributes.
dataGridView.Rows[i - 1].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[i - 1].Cells[isMemberColumn].Value = false;
dataGridView.Rows[i - 1].DefaultCellStyle.BackColor = Color.White;
}
//IF the previous row is a header row AND has color coding saying it is a group header, then clear the previous row's color and apply it to this row (i).
else if (rowStatus == RowAttribute.HeaderRow && (bool)dataGridView.Rows[i - 1].Cells[isHeaderColumn].Value)
{
//Clear the previous row of its attributes.
dataGridView.Rows[i - 1].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[i - 1].Cells[isMemberColumn].Value = false;
dataGridView.Rows[i - 1].DefaultCellStyle.BackColor = Color.White;
//Set the current row as a header row.
dataGridView.Rows[i].Cells[isHeaderColumn].Value = true;
dataGridView.Rows[i].Cells[isMemberColumn].Value = false;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.LightGray;
}
//IF previous row is Incomplete, then call the stable PaintRowGroups function.
else if (rowStatus == RowAttribute.IncompleteRow)
{
PaintRowGroups(dataGridView);
}
}
else
{
//Then check to see if the next row is a member row
rowStatus = parser.GetRowAttribute(dataGridView.Rows[i + 1]);
if (rowStatus == RowAttribute.MemberRow)
{
//Set the previous row as a header row.
dataGridView.Rows[i].Cells[isHeaderColumn].Value = true;
dataGridView.Rows[i].Cells[isMemberColumn].Value = false;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.LightGray;
//Set the next row as a member row.
dataGridView.Rows[i + 1].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[i + 1].Cells[isMemberColumn].Value = true;
dataGridView.Rows[i + 1].DefaultCellStyle.BackColor = Color.LightBlue;
}
}
}
else if (rowStatus == RowAttribute.MemberRow)
{
if (i > 0)
{
//Check the previous row.
rowStatus = parser.GetRowAttribute(dataGridView.Rows[i - 1]);
//IF the previous row is a member row AND is the first row in the data grid, then remove the coloring for it and the current row (i).
if (rowStatus == RowAttribute.MemberRow && (i - 1) == 0)
{
//Clear the previous row of its attributes.
dataGridView.Rows[i - 1].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[i - 1].Cells[isMemberColumn].Value = false;
dataGridView.Rows[i - 1].DefaultCellStyle.BackColor = Color.White;
//Clear the current row of its attributes.
dataGridView.Rows[i].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[i].Cells[isMemberColumn].Value = false;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.White;
}
//IF the previous row is a member row AND it also has color coding suggesting that it is a member of a group, then add the current row (i) as well.
else if (rowStatus == RowAttribute.MemberRow && (bool)dataGridView.Rows[i - 1].Cells[isMemberColumn].Value)
{
//Set the current row as a member row.
dataGridView.Rows[i].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[i].Cells[isMemberColumn].Value = true;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.LightBlue;
}
//IF the previous row is simply a member row with no coloring at all, then remove the coloring from the current row (i).
else if (rowStatus == RowAttribute.MemberRow || rowStatus == RowAttribute.AdSpecialRow)
{
//Clear the current row of its attributes.
dataGridView.Rows[i].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[i].Cells[isMemberColumn].Value = false;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.White;
}
//IF the previous row is a header row, then color it as a group header and color the current row as a member of said group.
else if (rowStatus == RowAttribute.HeaderRow)
{
//Set the previous row as a header row.
dataGridView.Rows[i - 1].Cells[isHeaderColumn].Value = true;
dataGridView.Rows[i - 1].Cells[isMemberColumn].Value = false;
dataGridView.Rows[i - 1].DefaultCellStyle.BackColor = Color.LightGray;
//Set the current row as a member row.
dataGridView.Rows[i].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[i].Cells[isMemberColumn].Value = true;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.LightBlue;
}
//IF the previous row is incomplete, then call the stable PaintRowGroups function.
else if (rowStatus == RowAttribute.IncompleteRow)
{
PaintRowGroups(dataGridView);
}
}
//ELSE the current row is the first row in the data grid, therefore it can't be a member row so remove all coloring.
else
{
//Clear the current row of its attributes.
dataGridView.Rows[0].Cells[isHeaderColumn].Value = false;
dataGridView.Rows[0].Cells[isMemberColumn].Value = false;
dataGridView.Rows[0].DefaultCellStyle.BackColor = Color.White;
}
}
}
}
public void PaintRowGroups(DataGridView dataGridView)
{
var parser = new RowParsing();
var incompleteRowsFound = 0;
var lastHeaderIndex = -1;
var i = 0;
var adSpecialIndex = -1;
foreach (DataGridViewRow row in dataGridView.Rows)
{
//Get the current row's status.
var rowType = parser.GetRowAttribute(row);
//If the current row is not a group header, the first row in the grid, or a new row and in fact a member row...
if (i != 0 && rowType == RowAttribute.MemberRow && !row.IsNewRow && rowType != RowAttribute.IncompleteRow)
{
//Remove all coloring on the current row.
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.White;
//Check to make sure the numbers are within bounds, errors occurs when an incomplete row is found at index zero (0), and the current row is one (1).
if ((i - (1 + incompleteRowsFound)) > 0)
{
//Check to see if the previous row is a header row by subtracting the number of rows that are (incomplete + 1) from the total number of rows (i).
//Adding one (1) to the incomplete count allows for checking the row right before the first incomplete row found so far to see if it's a header row.
if (parser.GetRowAttribute(dataGridView.Rows[i - (1 + incompleteRowsFound)]) == RowAttribute.HeaderRow)
{
row.DefaultCellStyle.BackColor = Color.LightBlue; //Group member
dataGridView.Rows[lastHeaderIndex].DefaultCellStyle.BackColor = Color.LightGray; //Group header
}
//Else if a header row was not found from the previous operation but a header row is set, then its safe to assume that this row can be a member.
else if (lastHeaderIndex >= 0)
{
//Check to make sure that the last header index is underneath the Ad Special Row OR that the current row (i) is before the Ad Special Index.
if (lastHeaderIndex > adSpecialIndex || i < adSpecialIndex)
{
//Assume that the current row is a member of that group header and color it as such.
row.DefaultCellStyle.BackColor = Color.LightBlue;
}
}
}
}
//If the current row is a potential group header AND the next row is as well remove the coloring from the current row, no need for checks.
else if (rowType == RowAttribute.HeaderRow && parser.GetRowAttribute(dataGridView.Rows[i + 1]) == RowAttribute.HeaderRow)
{
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.White;
}
//Check to see if this row is the first row, a header index row, AND the next row is a MemberRow.
else if (rowType == RowAttribute.HeaderRow && parser.GetRowAttribute(dataGridView.Rows[i + 1]) == RowAttribute.MemberRow && i == 0)
{
//IF so, set the last header index, and color code of this row along with the next row which is a MemberRow.
lastHeaderIndex = 0;
dataGridView.Rows[0].DefaultCellStyle.BackColor = Color.LightGray;
dataGridView.Rows[i + 1].DefaultCellStyle.BackColor = Color.LightBlue;
}
//Check to see if this row is a group header.
else if (rowType == RowAttribute.HeaderRow)
{
//If so, reset the incomplete rows found count, set the lastHeaderIndex to this row's index (i) and change it's color to white.
incompleteRowsFound = 0;
lastHeaderIndex = i;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.White;
}
//If the current row is the first row in the grid AND is not a group header then remove all color from it, since its not allowed to be a header or a member.
else if (i == 0 && rowType == RowAttribute.MemberRow)
{
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.White;
}
//Mark an incomplete row to determine whether or not we found one and remove any coloring it may have, incomplete rows are not allowed to be members or headers.
if (rowType == RowAttribute.IncompleteRow)
{
incompleteRowsFound++;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.White;
}
//
if (rowType == RowAttribute.AdSpecialRow)
{
adSpecialIndex = i;
dataGridView.Rows[i].DefaultCellStyle.BackColor = Color.Silver;
}
i++;
}//end for-each
dataGridView.Refresh();
}//End PaintRowGroups
}
public enum SalesTableColumns
{
Id = 0,
AdItem = 1,
Sold = 2,
SalePrice = 3,
TotalSales = 4,
Cost = 5,
ProfitReturn = 6,
TotalProfitReturn = 7,
IsHeaderRow = 8,
IsMemberRow = 9,
IsAdSpecialRow = 10,
IsAdSpecialMember = 11,
IsDirty = 12,
IsInDatabase = 13
}
public enum InventoryTableColumns
{
Id = 0,
AdItem = 1,
BeginningInventory = 2,
Recieved = 3,
Total = 4,
EndingInventory = 5,
IsHeaderRow = 6,
IsMemberRow = 7,
IsAdSpecialRow = 8,
IsAdSpecialMember = 9,
IsDirty = 10,
IsInDatabase = 11
}
public enum TrimmingOperationResult
{
FailedToTrim = 0,
CreatedNewInsertionTable = 1,
CreatedUpdateTable = 2,
CreatedNewInsertionAndUpdateTables = 3
}
}
@@ -0,0 +1,244 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{4A45C665-5D02-4724-9CC5-C0C50CA44760}</ProjectGuid>
<OutputType>WinExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>AdvertsingProfitControl</RootNamespace>
<AssemblyName>AdvertsingProfitControl</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
<IsWebBootstrapper>false</IsWebBootstrapper>
<PublishUrl>C:\Users\glmcc\Desktop\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>1</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust>
<PublishWizardCompleted>true</PublishWizardCompleted>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>x64</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>true</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup>
<TargetZone>LocalIntranet</TargetZone>
</PropertyGroup>
<PropertyGroup>
<GenerateManifests>true</GenerateManifests>
</PropertyGroup>
<PropertyGroup />
<PropertyGroup>
<StartupObject>AdvertsingProfitControl.Program</StartupObject>
</PropertyGroup>
<PropertyGroup>
<ManifestCertificateThumbprint>43F3577995641EA2A08A4951340360E3396F8F04</ManifestCertificateThumbprint>
</PropertyGroup>
<PropertyGroup>
<ManifestKeyFile>AdvertsingProfitControl_TemporaryKey.pfx</ManifestKeyFile>
</PropertyGroup>
<PropertyGroup>
<SignManifests>false</SignManifests>
</PropertyGroup>
<PropertyGroup>
<SignAssembly>false</SignAssembly>
</PropertyGroup>
<!--<PropertyGroup>
<AssemblyOriginatorKeyFile>AdvertsingProfitControl_TemporaryKey.pfx</AssemblyOriginatorKeyFile>
</PropertyGroup>-->
<PropertyGroup>
<ApplicationIcon>Stretched Logo Collection.ico</ApplicationIcon>
</PropertyGroup>
<PropertyGroup>
<ApplicationManifest>app.manifest</ApplicationManifest>
</PropertyGroup>
<ItemGroup>
<Reference Include="HtmlRenderer, Version=1.5.0.5, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\HtmlRenderer.Core.1.5.0.5\lib\net45\HtmlRenderer.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="HtmlRenderer.WinForms, Version=1.5.0.6, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\HtmlRenderer.WinForms.1.5.0.6\lib\net45\HtmlRenderer.WinForms.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="PresentationCore" />
<Reference Include="System" />
<Reference Include="System.Configuration" />
<Reference Include="System.Data" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Transactions" />
<Reference Include="System.Web" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
<Reference Include="WindowsBase" />
</ItemGroup>
<ItemGroup>
<Compile Include="AdItemCollectionModel.cs" />
<Compile Include="AdvertisingProfitControlTableHelper.cs" />
<Compile Include="TextFormat.cs" />
<Compile Include="APCDatabaseWriter.cs" />
<Compile Include="BackPageGenerator.cs" />
<Compile Include="DatabaseReader.cs" />
<Compile Include="DatabaseTracker.cs" />
<Compile Include="DatabaseVersionControl.cs" />
<Compile Include="DatabaseWriter.cs" />
<Compile Include="FrmAddRecord.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmAddRecord.Designer.cs">
<DependentUpon>FrmAddRecord.cs</DependentUpon>
</Compile>
<Compile Include="FrmAdSpecialRegister.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmAdSpecialRegister.Designer.cs">
<DependentUpon>FrmAdSpecialRegister.cs</DependentUpon>
</Compile>
<Compile Include="FrmDeleteRecord.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmDeleteRecord.Designer.cs">
<DependentUpon>FrmDeleteRecord.cs</DependentUpon>
</Compile>
<Compile Include="FrmMain.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmMain.Designer.cs">
<DependentUpon>FrmMain.cs</DependentUpon>
</Compile>
<Compile Include="FrmManageAdItems.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmManageAdItems.Designer.cs">
<DependentUpon>FrmManageAdItems.cs</DependentUpon>
</Compile>
<Compile Include="FrmModifyRecord.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmModifyRecord.Designer.cs">
<DependentUpon>FrmModifyRecord.cs</DependentUpon>
</Compile>
<Compile Include="FrontPageGenerator.cs" />
<Compile Include="GlobalClasses.cs" />
<Compile Include="FrmLogConsole.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmLogConsole.Designer.cs">
<DependentUpon>FrmLogConsole.cs</DependentUpon>
</Compile>
<Compile Include="NewAddRecord.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="NewAddRecord.Designer.cs">
<DependentUpon>NewAddRecord.cs</DependentUpon>
</Compile>
<Compile Include="RowParsing.cs" />
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<EmbeddedResource Include="FrmAddRecord.resx">
<DependentUpon>FrmAddRecord.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmAdSpecialRegister.resx">
<DependentUpon>FrmAdSpecialRegister.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmDeleteRecord.resx">
<DependentUpon>FrmDeleteRecord.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmMain.resx">
<DependentUpon>FrmMain.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmLogConsole.resx">
<DependentUpon>FrmLogConsole.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmManageAdItems.resx">
<DependentUpon>FrmManageAdItems.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmModifyRecord.resx">
<DependentUpon>FrmModifyRecord.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="NewAddRecord.resx">
<DependentUpon>NewAddRecord.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
<SubType>Designer</SubType>
</EmbeddedResource>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Resources.resx</DependentUpon>
<DesignTime>True</DesignTime>
</Compile>
<None Include="AdvertsingProfitControl_TemporaryKey.pfx" />
<None Include="app.manifest" />
<None Include="packages.config" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.5">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.5 %28x86 and x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Client.3.5">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1 Client Profile</ProductName>
<Install>false</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
</ItemGroup>
<ItemGroup>
<Content Include="Stretched Logo Collection.ico" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
@@ -0,0 +1,662 @@
using System;
using System.Data;
using System.Windows.Forms;
using System.IO;
using System.Drawing.Imaging;
using System.Web.UI;
using TheArtOfDev.HtmlRenderer.WinForms;
namespace AdvertsingProfitControl
{
internal class BackPageGenerator
{
FrmLogConsole _console = FrmLogConsole.GetStaticInstance;
public void RenderHtmlToImage()
{
var htmlCode = File.ReadAllLines(Application.StartupPath + "\\BackPage.html");
var code = "";
foreach (var line in htmlCode)
{
code = code + "\r\n" + line;
}
try
{
var imageFromHtml = HtmlRender.RenderToImage(code);
imageFromHtml.Save(Application.StartupPath + "\\BackPage.png", ImageFormat.Png);
imageFromHtml.Dispose();
}
catch (Exception e)
{
_console.WriteToLog(FrmLogConsole.Level.Critical,
"Failed to generate an updated image for the back page of Advertising Profit Control.");
_console.WriteToLog(FrmLogConsole.Level.Debug, e.Message);
_console.WriteToLog(FrmLogConsole.Level.Info,
"This is most likely a screw you from the GDI+ subsystem of Windows.");
}
}
public void GenerateWeeklyInventoryControlPage(string dateId)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var invoiceTable = databaseReader.ReturnInvoiceTable(dateId, databaseTracker.DatabaseConnectionString);
var weeklySalesTable = databaseReader.ReturnWeeklySalesFromDateId(dateId,
databaseTracker.DatabaseConnectionString);
var stringWriter = new StringWriter();
var writer = new HtmlTextWriter(stringWriter);
writer.Write("<!DOCTYPE html>\n");
writer.RenderBeginTag(HtmlTextWriterTag.Html);
writer.RenderBeginTag(HtmlTextWriterTag.Head);
writer.AddAttribute(HtmlTextWriterAttribute.Type, "text/css");
writer.RenderBeginTag(HtmlTextWriterTag.Style);
writer.Write("td{margins:0px; padding:0; border:1px solid black; text-align:left} table{table-layout:fixed;} td{ width: 1px; white-space:nowrap; }");
writer.RenderEndTag();//style
writer.RenderEndTag();//Head
writer.RenderBeginTag(HtmlTextWriterTag.Body);
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-collapse: collapse");
writer.RenderBeginTag(HtmlTextWriterTag.Table);
//Create the header as the first row.
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "8");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; text-align:center; width:800px");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center>Weekly Inventory Control</center>");
writer.RenderEndTag();//td
//New row for Name & Location
writer.RenderEndTag();//tr (header row)
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "5");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; text-align:left"); //; width:560px
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Name & Location");
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none"); //; width:240px
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Week Ending <u>" + CleanDate(databaseReader.RetrieveDateStringById(dateId, databaseTracker.DatabaseConnectionString)) + "</u>");
writer.RenderEndTag();//td
writer.RenderEndTag();//tr
//Begin rendering the proper header row for the table itself.
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
//Purchases td
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "5");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "height:15px; font-size:10px; text-align:center");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center>Purchases</center>");
writer.RenderEndTag();//td
//Sales td
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "height:15px; font-size:10px; text-align:center");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center>Sales</center>");
writer.RenderEndTag();//td
writer.RenderEndTag();//tr
//Begin rendering the description row and the Sunday row in the sales table.
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
//Date td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:center"); //; width:100px
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Date");
writer.RenderEndTag();//td
//Supplier and invoices td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "font-size:10px; text-align:center"); //width:250px;
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Suppliers and Invoice Number");
writer.RenderEndTag();//td
//Net amount td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "font-size:10px; text-align:center");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Net Amount of Invoices At Cost");
writer.RenderEndTag();//td
//Net amount extended retail
writer.AddAttribute(HtmlTextWriterAttribute.Style, "font-size:10px; text-align:center"); //width:50px
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Net Amount of <br>Invoices<br> Extended Retail");
writer.RenderEndTag();//td
//Sunday td
//writer.AddAttribute(HtmlTextWriterAttribute.Style, "width:60px");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Sunday");
writer.RenderEndTag();//td
//Dollar amount for Sunday
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:right");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
var sundaySalesAmount = FormatNumberForDisplay(weeklySalesTable.Rows[0].ItemArray[0]).Split('.');
writer.Write(sundaySalesAmount[0]);
writer.RenderEndTag();//td
//cents amount td
//writer.AddAttribute(HtmlTextWriterAttribute.Style, "width:10px");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(sundaySalesAmount[1]);
writer.RenderEndTag();//td
writer.RenderEndTag();//tr
//Loop 35 times to build all the rows.
double totalCostsOfSales = 0; //holds the total value of all the invoices purchases.
foreach (DataRow row in invoiceTable.Rows)
{
//Index four (4) contains the Net Amount of Invoices Extended Retail values.
double parsedString = 0;
if (double.TryParse(row.ItemArray[4].ToString(), out parsedString))
{
totalCostsOfSales += parsedString;
}
}
for (var i = 0; i < 34; i++)
{
var purchasesColumnsRendered = false;
var salesColumnsRendered = false;
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
if (i < invoiceTable.Rows.Count)
{
purchasesColumnsRendered = RenderPurchasesColumns(i, writer, invoiceTable);
}
if ((i + 1) < 8)
{
//padding
if (purchasesColumnsRendered == false)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write((i + 1) + ".");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
}
//Generates the SALES columns.
salesColumnsRendered = RenderWeeklySalesColumns(i, writer, weeklySalesTable);
}
if (i == 7)
{
//padding
if (purchasesColumnsRendered == false)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write((i + 1) + ".");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
}
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:center");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Taxable");
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
if (i == 16)
{
//Gross Profit Row
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write((i + 1) + ".");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:center");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Gross Profit");
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
if (i == 19)
{
//Padding
if (purchasesColumnsRendered == false)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write((i + 1) + ".");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
}
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-bottom:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Dollar Gross Profit");
writer.RenderEndTag();//td
}
if (i == 20)
{
//Padding
if (purchasesColumnsRendered == false)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write((i + 1) + ".");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
}
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-top:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
double totalSales = 0;
if (double.TryParse(weeklySalesTable.Rows[0].ItemArray[7].ToString(), out totalSales))
{
var dollarGrossProfit = totalSales - totalCostsOfSales;
var dollarGrossProfitSplit = FormatNumberForDisplay(dollarGrossProfit).Split('.');
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:right");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(dollarGrossProfitSplit[0]);
writer.RenderEndTag(); //td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(dollarGrossProfitSplit[1]);
writer.RenderEndTag(); //td
}
else
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
}
}
if (i == 21)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Total Purchases");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("% Gross Profit 41.9%");
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
if (i == 22)
{
var dollarsAndCents = FormatNumberForDisplay(totalCostsOfSales).Split('.');
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Less Transfer & Credits");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "font-size:10px");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Est. Wkly. Dept. Expense");
writer.RenderEndTag();//td
//Align the text for the dollar amount to the ride side.
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:right");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(dollarsAndCents[0]);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(dollarsAndCents[1]);
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
if (i == 23)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("1.");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; font-size:12px");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("% Gross obtained by dividing<br>Total Sales into Gross Profit");
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
if (i == 24)
{
//padding
if (purchasesColumnsRendered == false)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("2.");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
}
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-right:1px solid black");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
}
if (i == 25)
{
//padding
if (purchasesColumnsRendered == false)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("3.");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
}
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Manager_____________");
writer.RenderEndTag();//td
}
if (i > 25 && i < 29)
{
//padding
if (purchasesColumnsRendered == false)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(i - 22);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
}
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
}
if (i == 29)
{
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Total Purchases");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
//
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
if (i == 30)
{
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Less Total Transfers & Credits");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
//
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
if (i == 31)
{
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Net Purchases of Week");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
//
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
if (i == 32)
{
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Sales Per Man Hour_____");
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Salary Percentage______");
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
if (i == 33)
{
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Salary Dollars_____");
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Supplies______");
writer.RenderEndTag();//td
purchasesColumnsRendered = true;
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "3");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
salesColumnsRendered = true;
}
//Padding
if (purchasesColumnsRendered == false && salesColumnsRendered == false)
{
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:left");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write((i + 1) + ".");
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
}
//End Padding
writer.RenderEndTag();//tr
}
writer.RenderEndTag();//table
writer.RenderEndTag();//body
writer.RenderEndTag();//html
using (var streamWriter = new StreamWriter(Application.StartupPath + "\\BackPage.html"))
{
streamWriter.WriteLine(stringWriter.ToString());
}
}
private bool RenderPurchasesColumns(int rowIndex, HtmlTextWriter writer, DataTable invoiceTable)
{
var purchasesColumsRender = false;
if (rowIndex < invoiceTable.Rows.Count)
{
//Grab the date
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(CleanDate(invoiceTable.Rows[rowIndex].ItemArray[2].ToString()));
writer.RenderEndTag();//td
//Grab the invoice number and the supplier's name
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write((rowIndex + 1) + ". " + invoiceTable.Rows[rowIndex].ItemArray[0] + " " + invoiceTable.Rows[rowIndex].ItemArray[1]);
writer.RenderEndTag();//td
//Get the net amount of invoices at cost
writer.RenderBeginTag(HtmlTextWriterTag.Td);
//For now, if the net amount of invoices at cost are empty, throw in the comments in place of a blank space.
writer.Write(invoiceTable.Rows[rowIndex].ItemArray[3].ToString() == ""
? invoiceTable.Rows[rowIndex].ItemArray[5]
: FormatNumberForDisplay(invoiceTable.Rows[rowIndex].ItemArray[3]));
writer.RenderEndTag();//td
//Get the net amount of invoices extended retail (InvoiceNetAmount in the Invoice table)
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:right"); //width:40px
writer.RenderBeginTag(HtmlTextWriterTag.Td);
var netAmountOfInvoicesExtendedRetail = FormatNumberForDisplay(invoiceTable.Rows[rowIndex].ItemArray[4]);
var splitDollarAmount = netAmountOfInvoicesExtendedRetail.Split('.');
writer.Write(splitDollarAmount[0]);
writer.RenderEndTag();//td
//Render the cents into their own column.
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:left; width:10px"); //width:10px
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(splitDollarAmount[1]);
writer.RenderEndTag();//td
purchasesColumsRender = true;
}
return purchasesColumsRender;
}
private bool RenderWeeklySalesColumns(int rowIndex, HtmlTextWriter writer, DataTable weeklySalesTable)
{
var salesColumnsRendered = false;
if ((rowIndex + 1) < 8)
{
//Generates the SALES columns.
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(weeklySalesTable.Columns[rowIndex + 1].ColumnName);
writer.RenderEndTag(); //td
var weeklySales = FormatNumberForDisplay(weeklySalesTable.Rows[0].ItemArray[rowIndex + 1]);
var splitWeeklySalesAMount = weeklySales.Split('.');
var dollarAmount = splitWeeklySalesAMount[0];
//Align the dollar amount column text to the right side.
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:right");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(dollarAmount);
writer.RenderEndTag(); //td
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(splitWeeklySalesAMount[1]);
writer.RenderEndTag(); //td
salesColumnsRendered = true;
}
return salesColumnsRendered;
}
private static string CleanDate(string date)
{
var tempDate = date.Split(' ');
date = tempDate[0];
return date;
}
private string FormatNumberForDisplay(object dollarAmount, bool includeCurrencySign = false)
{
var formattedNumber = "";
double parsedValue = 0;
if (double.TryParse(dollarAmount.ToString(), out parsedValue))
{
formattedNumber = parsedValue.ToString("C2");
if (includeCurrencySign == false)
{
formattedNumber = formattedNumber.Replace("$", "");
}
}
else
{
formattedNumber = "0.00";
}
return formattedNumber;
}
}
}
+887
View File
@@ -0,0 +1,887 @@
using System;
using System.Collections.Generic;
using System.Data.OleDb;
using System.Windows.Forms;
using System.Data;
namespace AdvertsingProfitControl
{
internal class DatabaseReader
{
public string GetDatabaseVersion(string connectionString)
{
var versionNumber = "0.0.0.0";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT VersionNumber FROM Version"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
versionNumber = reader[0].ToString();
}
}
}
}
return versionNumber;
}
#region Date Functions
/// <summary>
/// Retrieves the most recent date's ID from the database.
/// </summary>
/// <param name="connectionString">The connection string for the database.</param>
/// <returns>The ID number as a string.</returns>
public string RetrieveMostRecentDateId(string connectionString)
{
var dateId = "0";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT WeekEnding.ID FROM WeekEnding WHERE WeekEnding.EndOfWeekDate = (SELECT MAX(WeekEnding.EndOfWeekDate) FROM WeekEnding)"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
dateId = reader[0].ToString();
}
}
}
}
return dateId;
}
public string RetrieveDateIdByDateString(string dateString, string connectionString)
{
var dateId = "0";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT WeekEnding.ID FROM WeekEnding WHERE WeekEnding.EndOfWeekDate = ?"
};
oleDbCommand.Parameters.AddWithValue("DateString", dateString);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
dateId = reader[0].ToString();
}
}
}
}
return dateId;
}
public string RetrieveDateStringById(string dateId, string connectionString)
{
string dateString = "";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT WeekEnding.EndOfWeekDate FROM WeekEnding WHERE WeekEnding.ID = ? ORDER BY EndOfWeekDate ASC"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
dateString = reader[0].ToString();
}
}
}
}
return dateString;
}
public List<string> RetrieveUniqueYearsList(string connectionString)
{
var datesList = new List<string>();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT Distinct YEAR(EndOfWeekDate) FROM WeekEnding"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
datesList.Add(reader[0].ToString());
}
}
}
}
return datesList;
}
public List<string> RetrieveUniqueMonthsList(string year, string connectionString)
{
var datesList = new List<string>();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT Distinct MONTH(EndOfWeekDate) FROM WeekEnding WHERE YEAR(EndOfWeekDate) = ?"
};
oleDbCommand.Parameters.AddWithValue("Year", year);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
datesList.Add(reader[0].ToString());
}
}
}
}
return datesList;
}
public DateTime RetrieveMostRecentDateString(string connectionString)
{
DateTime dateTimeObject = new DateTime();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT WeekEnding.EndOfWeekDate FROM WeekEnding WHERE WeekEnding.EndOfWeekDate = (SELECT MAX(WeekEnding.EndOfWeekDate) FROM WeekEnding)"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
dateTimeObject = (DateTime) reader[0];
}
}
}
}
return dateTimeObject;
}
/// <summary>
/// Returns a list of dates by the year supplied.
/// </summary>
/// <returns></returns>
public List<DateTime> RetrieveDateListByYear(string year, string connectionString)
{
var datesList = new List<DateTime>();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT EndOfWeekDate FROM WeekEnding WHERE YEAR(EndOfWeekDate) = ? ORDER BY EndOfWeekDate ASC"
};
oleDbCommand.Parameters.AddWithValue("Year", year);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
datesList.Add((DateTime)reader[0]);
}
}
}
}
return datesList;
}
#endregion
#region Ad Item Functions
public Dictionary<int, string> GetAdItemsSuggestionDictionary(string connectionString)
{
var adItemDictionary = new Dictionary<int, string>();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdItem.ID, AdItem.AdItem FROM AdItem ORDER BY AdItem.AdItem ASC"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
adItemDictionary.Add(int.Parse(reader["ID"].ToString()), reader["AdItem"].ToString());
}
}
}
}
return adItemDictionary;
}
public int GetLargestKeyValueForAdItems(string connectionString)
{
var id = -1;
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT MAX(AdItem.ID) FROM AdItem"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
int.TryParse(reader[0].ToString(), out id);
}
}
}
}
return id;
}
public string RetrieveAdItemId(string adItemName, string connectionString)
{
var id = "0";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdItem.ID FROM AdItem WHERE UCASE(AdItem.AdItem) = UCASE(?)" //JUST MAKE A CUSTOM PARSING ENGINE
};
oleDbCommand.Parameters.AddWithValue("AdItemName", adItemName);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
id = reader[0].ToString();
}
}
}
}
return id;
}
public List<string> RetrieveUsedAdItemListByDateId(string dateId, string connectionString)
{
var adItemList = new List<string>();
var oleDbCommand = new OleDbCommand
{
CommandText = "SELECT AdItem.AdItem, ActualSales.RowAttribute, ActualSales.FK_AdSpecialGroupName FROM (ActualSales INNER JOIN AdItem ON ActualSales.FK_AdItemID = AdItem.ID) WHERE FK_DateID = ? ORDER BY RowPosition ASC"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
if (reader["FK_AdSpecialGroupName"].ToString() != "" && int.Parse(reader["FK_AdSpecialGroupName"].ToString()) >= 3)
{
adItemList.Add(reader[0] + ":2");
}
else
{
adItemList.Add(reader[0] + ":1");
}
}
}
}
}
return adItemList;
}
public List<string> RetrieveAdItemListByLetter(string connectionString, string letterFilter = "All")
{
var adItemsList = new List<string>();
var oleDbCommand = new OleDbCommand();
if(letterFilter == "All")
{
oleDbCommand.CommandText = "SELECT AdItem FROM AdItem ORDER BY AdItem ASC";
}
else
{
oleDbCommand.CommandText = "SELECT AdItem FROM AdItem WHERE LEFT(AdItem, 1) = ? ORDER BY AdItem ASC";
oleDbCommand.Parameters.AddWithValue("Filter", letterFilter);
}
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
adItemsList.Add((reader[0].ToString()));
}
}
}
}
return adItemsList;
}
#endregion
#region Comment Functions
public string RetrieveComments(string dateId, string connectionString)
{
var comments = "";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT Comment.Comment FROM Comment WHERE Comment.FK_DateID = ?"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
comments = reader[0].ToString();
}
}
}
}
return comments;
}
#endregion
#region Ad Special Functions
public string RetrieveGroupIdByString(string groupName, string connectionString)
{
var groupId = "0";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdSpecialName.ID FROM AdSpecialName WHERE AdSpecialName.AdSpecialName = ?"
};
oleDbCommand.Parameters.AddWithValue("AdSpecialName", groupName);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
groupId = reader[0].ToString();
}
}
}
}
return groupId;
}
public string ReturnAdSpecialDescriptionByAdSpecialName(string adSpecialString, string connectionString)
{
var descriptionString = "";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdSpecialName.AdSpecialDescription FROM AdSpecialName WHERE AdSpecialName.AdSpecialDescription = ?"
};
oleDbCommand.Parameters.AddWithValue("AdspecialName", adSpecialString);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
descriptionString = reader[0].ToString();
}
}
}
}
return descriptionString;
}
public List<string> ReturnGroupNameList(string connectionString)
{
var groupNames = new List<string>();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdSpecialName.AdSpecialName FROM AdSpecialName"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
groupNames.Add(reader[0].ToString());
}
}
}
}
return groupNames;
}
public string ReturnGroupNameFromGroupId(string id, string connectionString)
{
var name = "";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdSpecialName FROM AdSpecialName WHERE ID = ?"
};
oleDbCommand.Parameters.AddWithValue("AdspecialName", id);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
name = reader[0].ToString();
}
}
}
}
return name;
}
public AutoCompleteStringCollection RetrieveAdSpecialList(string connectionString)
{
var adSpecialList = new AutoCompleteStringCollection();
var oleDbCommand = new OleDbCommand()
{
CommandText = "Select AdSpecialName FROM AdSpecialName"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var reader = oleDbCommand.ExecuteReader())
{
while (reader != null && reader.Read())
{
adSpecialList.Add(reader[0].ToString());
}
}
}
}
return adSpecialList;
}
#endregion
#region AutoComplete Functions
public List<string> GetAdItemsSuggestionList(string connectionString)
{
var autoCompleteList = new List<string>();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdItem.AdItem FROM AdItem ORDER BY AdItem.AdItem ASC"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
autoCompleteList.Add(reader[0].ToString());
}
}
}
}
return autoCompleteList;
}
public AutoCompleteStringCollection GetSupplierSuggestionList(string connectionString)
{
var autoCompleteList = new AutoCompleteStringCollection();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT SupplierName FROM Supplier ORDER BY SupplierName ASC"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
autoCompleteList.Add(reader[0].ToString());
}
}
}
}
return autoCompleteList;
}
#endregion
#region Table Return Functions
public DataTable ReturnApcTableForReport(string dateId, string connectionString)
{
var dataTable = new DataTable();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdItem.AdItem, APC.ProjectionSold, APC.ProjectionSalePrice, APC.ProjectionTotalSales, APC.ProjectionCost, APC.ProjectionProfitReturn, APC.ProjectionTotalProfitReturn, APC.BeginingInventory, APC.Received, APC.TotalInventory, APC.EndingInventory, APC.ActualSold, APC.ActualSalePrice, APC.ActualTotalSales, APC.ActualCost, APC.ActualProfitReturn, APC.ActualTotalProfitReturn, APC.GroupNumber, APC.FK_AdSpecialName FROM (AdItem INNER JOIN APC ON AdItem.ID = APC.FK_AdItemID) WHERE FK_DateID = ? ORDER BY RowPosition ASC"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var dataAdapter = new OleDbDataAdapter(oleDbCommand))
{
dataAdapter.Fill(dataTable);
}
}
}
return dataTable;
}
public DataTable ReturnProjectionsTable(string dateId, string connectionString)
{
var dataTable = new DataTable();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdItem.AdItem, Projections.Sold, Projections.SalePrice, Projections.TotalSales, Projections.Cost, Projections.ProfitReturn, Projections.TotalProfitReturn, Projections.RowAttribute, Projections.FK_AdSpecialGroupName FROM (AdItem INNER JOIN Projections ON AdItem.ID = Projections.FK_AdItemID) WHERE FK_DateID = ? ORDER BY RowPosition ASC"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var dataAdapter = new OleDbDataAdapter(oleDbCommand))
{
dataAdapter.Fill(dataTable);
}
}
}
return dataTable;
}
public DataTable ReturnActualSales(string dateId, string connectionString)
{
var dataTable = new DataTable();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdItem.AdItem, ActualSales.Sold, ActualSales.SalePrice, ActualSales.TotalSales, ActualSales.Cost, ActualSales.ProfitReturn, ActualSales.TotalProfitReturn, ActualSales.RowAttribute, ActualSales.FK_AdSpecialGroupName FROM (AdItem INNER JOIN ActualSales ON AdItem.ID = ActualSales.FK_AdItemID) WHERE FK_DateID = ? ORDER BY RowPosition ASC"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var dataAdapter = new OleDbDataAdapter(oleDbCommand))
{
dataAdapter.Fill(dataTable);
}
}
}
return dataTable;
}
public DataTable ReturnInventoryTable(string dateId, string connectionString)
{
var dataTable = new DataTable();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT AdItem.AdItem, Inventory.BeginningInventory, Inventory.Received, Inventory.TotalInventory, Inventory.EndingInventory, Inventory.RowAttribute, Inventory.FK_AdSpecialGroupName FROM (AdItem INNER JOIN Inventory ON AdItem.ID = Inventory.FK_AdItemID) WHERE FK_DateID = ? ORDER BY RowPosition ASC"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var dataAdapter = new OleDbDataAdapter(oleDbCommand))
{
dataAdapter.Fill(dataTable);
}
}
}
return dataTable;
}
public DataTable ReturnInvoiceTable(string dateId, string connectionString)
{
var dataTable = new DataTable();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT Supplier.SupplierName, Invoice.InvoiceNumber, Invoice.InvoiceDate, Invoice.InvoiceNetAmountAtCost, Invoice.InvoiceNetAmount, Invoice.InvoiceNote FROM (Supplier INNER JOIN Invoice ON Supplier.ID = Invoice.FK_Supplier) WHERE FK_DateID = ?"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
using(var adapter = new OleDbDataAdapter(oleDbCommand))
{
adapter.Fill(dataTable);
}
}
}
return dataTable;
}
public DataTable ReturnWeeklySalesFromDateId(string dateId, string connectionString)
{
var dataTable = new DataTable();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT WeeklySales.Sunday, WeeklySales.Monday, WeeklySales.Tuesday, WeeklySales.Wednesday, WeeklySales.Thursday, WeeklySales.Friday, WeeklySales.Saturday, WeeklySales.TotalSales FROM WeeklySales WHERE FK_DateID = ?"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var dataAdapter = new OleDbDataAdapter(oleDbCommand))
{
dataAdapter.Fill(dataTable);
}
}
}
return dataTable;
}
public DataTable ReturnTaxableFromDateId(string dateId, string connectionString)
{
var dataTable = new DataTable();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT Taxable.Sunday, Taxable.Monday, Taxable.Tuesday, Taxable.Wednesday, Taxable.Thursday, Taxable.Friday, Taxable.Saturday, Taxable.Total FROM Taxable WHERE FK_DateID = ?"
};
oleDbCommand.Parameters.AddWithValue("DateID", dateId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using (var dataAdapter = new OleDbDataAdapter(oleDbCommand))
{
dataAdapter.Fill(dataTable);
}
}
}
return dataTable;
}
public DataTable ReturnWeekEndingTable(string connectionString)
{
var dataTable = new DataTable();
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT EndOfWeekDate FROM WeekEnding ORDER BY EndOfWeekDate ASC"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var dataAdapter = new OleDbDataAdapter(oleDbCommand))
{
dataAdapter.Fill(dataTable);
}
}
}
return dataTable;
}
#endregion
#region Supplier And Invoices Functions
public string RetrieveSupplierNameById(string supplierId, string connectionString)
{
var supplierName = "";
var oleDbCommand = new OleDbCommand()
{
CommandText = "SELECT SupplierName FROM Supplier WHERE ID = ?"
};
oleDbCommand.Parameters.AddWithValue("ID", supplierId);
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
using (connection)
{
using (oleDbCommand)
{
connection.Open();
using(var reader = oleDbCommand.ExecuteReader())
{
while(reader != null && reader.Read())
{
supplierName = reader[0].ToString();
}
}
}
}
return supplierName;
}
#endregion
}
}
@@ -0,0 +1,22 @@
using System.Configuration;
using System.IO;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
class DatabaseTracker
{
//private string _DatabaseProvider = "Provider=Microsoft.ACE.OLEDB.12.0;";
//private string _SecuritySettings = "Persist Security Info=False";
public DatabaseTracker()
{
}
public string DatabaseConnectionString
{
get { return "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=APCDatabase.accdb;Persist Security Info=False"; }
}
}
}
@@ -0,0 +1,197 @@
using System;
using System.IO;
using System.Collections.Generic;
using System.Data;
using System.Data.Common;
using System.Data.OleDb;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
internal class DatabaseVersionControl
{
FrmLogConsole _console = FrmLogConsole.GetStaticInstance;
public string GetDatabaseVerionNumber(string connectionString)
{
var versionNumber = "0.0.0.0";
var oleDbCommand = new OleDbCommand
{
CommandText = "SELECT VersionNumber FROM Version"
};
var connection = new OleDbConnection(connectionString);
oleDbCommand.Connection = connection;
try
{
connection.Open();
var reader = oleDbCommand.ExecuteReader();
while(reader != null && reader.Read())
{
versionNumber = reader[0].ToString();
}
}
catch (OleDbException e)
{
//Due to primitive nature of the original database (v0.3.0.0), which did not contain a Version table, an error
//will be kicked out trying to extract the version number from the database. So, just assume this isn't an
//OleDb error of some type.
_console.WriteToLog(FrmLogConsole.Level.Warning, "Testing for the database's version yielded an error.\nVersion number will be assumed to be 0.3.0.0.");
_console.WriteToLog(FrmLogConsole.Level.Debug, e.Message);
versionNumber = "0.3.0.0";
}
finally
{
connection.Close();
}
return versionNumber;
}
public bool UpdateVersionPointFive(string connectionString, out string versionNumber)
{
var updated = false;
//Create a backup of the database
File.Copy(Application.StartupPath + "\\APCDatabase.accdb", Application.StartupPath + "\\APCDatabase.bak", true);
var connection = new OleDbConnection(connectionString);
var oleDbCommand = new OleDbCommand
{
CommandText = "SELECT FK_AdItemID, FK_DateID, FK_GroupID FROM APC",
Connection = connection
};
using (connection)
{
connection.Open();
var apcReturnTable = new List<string>();
using(var reader = oleDbCommand.ExecuteReader())
{
//Each record's structure is as follows (index based):
// 0 - FK_AdItemID, 1 - FK_DateID and 2 - FK_GroupID
var groupID = 0;
var rowAttribute = 0;
var adItemID = "";
var dateID = "";
while(reader != null && reader.Read())
{
apcReturnTable.Add(reader[0] + "," + reader[1] + "," + reader[2]);
}
reader?.Close();
//Update the FK_GroupID's data type.
//oleDbCommand.CommandText = "ALTER TABLE APC ALTER COLUMN FK_GroupID NUMBER";
//oleDbCommand.ExecuteNonQuery();
//Insert the new columns into the APC table.
oleDbCommand.CommandText = "ALTER TABLE APC ADD COLUMN RowPosition NUMBER, RowAttribute NUMBER";
oleDbCommand.ExecuteNonQuery();
//Change the object to update mode
oleDbCommand.CommandText =
"UPDATE APC SET RowAttribute = ?, RowPosition = ?, FK_GroupID = ? WHERE FK_AdItemID = ? AND FK_DateID = ?";
var rowPosition = 1;
foreach (var splitRow in apcReturnTable.Select(row => row.Split(',')))
{
if (splitRow[1] != dateID)
{
rowPosition = 1;
}
groupID = 0;
rowAttribute = 0;
if (splitRow.Length == 3)
{
adItemID = splitRow[0];
dateID = splitRow[1];
var splitGroupIDs = splitRow[2].Split('|');
if (splitGroupIDs.Length == 2)
{
if (splitGroupIDs[1] != "")
{
groupID = int.Parse(splitGroupIDs[1]);
}
if (splitGroupIDs[0] != "")
{
rowAttribute = int.Parse(splitGroupIDs[0]);
}
}
else if (splitGroupIDs.Length == 1)
{
//Try parsing the value to an int and check how big it is.
//Less then three (3) means either a header or member row identifier, whereas a three (3) or greater means an ad special row.
var parsedVal = 0;
if (int.TryParse(splitGroupIDs[0], out parsedVal))
{
if (parsedVal > 2)
{
groupID = parsedVal;
}
else if (parsedVal < 3)
{
rowAttribute = parsedVal;
}
}
}
}
else
{
adItemID = splitRow[0];
dateID = splitRow[1];
}
//Update the new row with the information.
oleDbCommand.Parameters.Clear();
if (rowAttribute == 0)
{
oleDbCommand.Parameters.AddWithValue("RowAttribute", OleDbType.Empty);
}
else
{
oleDbCommand.Parameters.AddWithValue("RowAttribute", rowAttribute);
}
oleDbCommand.Parameters.AddWithValue("RowPosition", rowPosition);
if (groupID == 0)
{
oleDbCommand.Parameters.AddWithValue("RowAttribute", OleDbType.Empty);
}
else
{
oleDbCommand.Parameters.AddWithValue("GroupID", groupID);
}
oleDbCommand.Parameters.AddWithValue("AdItemID", adItemID);
oleDbCommand.Parameters.AddWithValue("DateID", dateID);
if (oleDbCommand.ExecuteNonQuery() != 1)
{
MessageBox.Show("An error has occurred trying to upgrade the database", "Fatal Error");
break;
}
rowPosition++;
}
//Update the FK_GroupID's data type.
oleDbCommand.Parameters.Clear();
oleDbCommand.CommandText = "ALTER TABLE APC ALTER COLUMN FK_GroupID NUMBER";
oleDbCommand.ExecuteNonQuery();
oleDbCommand.CommandText = "ALTER TABLE APC ALTER COLUMN ProjectionSold TEXT";
oleDbCommand.ExecuteNonQuery();
//Apply an update patch for version 0.3.0.0 database by adding a version table and inserting the version number into the database.
oleDbCommand.CommandText = "CREATE TABLE Version (ID AUTOINCREMENT PRIMARY KEY, VersionNumber TEXT)";
oleDbCommand.ExecuteNonQuery();
//Insert the version number into the new table
oleDbCommand.CommandText = "INSERT INTO Version (VersionNumber) VALUES ('0.5.0.0')";
oleDbCommand.ExecuteNonQuery();
versionNumber = "0.5.0.0";
updated = true;
}
}
return updated;
}
}
}
File diff suppressed because it is too large Load Diff
+179
View File
@@ -0,0 +1,179 @@
namespace AdvertsingProfitControl
{
partial class FrmAdSpecialRegister
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmAdSpecialRegister));
this.mainLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.currentAdSpecialKeyWords = new System.Windows.Forms.Label();
this.adSpecialKeyWordsListBox = new System.Windows.Forms.ListBox();
this.registerAdSpecialPanel = new System.Windows.Forms.Panel();
this.enterNewKeyWordTextBox = new System.Windows.Forms.TextBox();
this.registerKeyWordButton = new System.Windows.Forms.Button();
this.enterKeyWordHeaderLabel = new System.Windows.Forms.Label();
this.DELETE = new System.Windows.Forms.Button();
this.notificationLabel = new System.Windows.Forms.Label();
this.mainLayoutPanel.SuspendLayout();
this.registerAdSpecialPanel.SuspendLayout();
this.SuspendLayout();
//
// mainLayoutPanel
//
this.mainLayoutPanel.ColumnCount = 2;
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.mainLayoutPanel.Controls.Add(this.currentAdSpecialKeyWords, 1, 0);
this.mainLayoutPanel.Controls.Add(this.adSpecialKeyWordsListBox, 1, 1);
this.mainLayoutPanel.Controls.Add(this.registerAdSpecialPanel, 0, 1);
this.mainLayoutPanel.Controls.Add(this.enterKeyWordHeaderLabel, 0, 0);
this.mainLayoutPanel.Controls.Add(this.DELETE, 0, 2);
this.mainLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainLayoutPanel.Location = new System.Drawing.Point(0, 0);
this.mainLayoutPanel.Name = "mainLayoutPanel";
this.mainLayoutPanel.RowCount = 3;
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 35F));
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.mainLayoutPanel.Size = new System.Drawing.Size(749, 563);
this.mainLayoutPanel.TabIndex = 0;
//
// currentAdSpecialKeyWords
//
this.currentAdSpecialKeyWords.AutoSize = true;
this.currentAdSpecialKeyWords.Dock = System.Windows.Forms.DockStyle.Fill;
this.currentAdSpecialKeyWords.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.currentAdSpecialKeyWords.Location = new System.Drawing.Point(377, 0);
this.currentAdSpecialKeyWords.Name = "currentAdSpecialKeyWords";
this.currentAdSpecialKeyWords.Size = new System.Drawing.Size(369, 35);
this.currentAdSpecialKeyWords.TabIndex = 0;
this.currentAdSpecialKeyWords.Text = "Registered Key Words:";
//
// adSpecialKeyWordsListBox
//
this.adSpecialKeyWordsListBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.adSpecialKeyWordsListBox.FormattingEnabled = true;
this.adSpecialKeyWordsListBox.ItemHeight = 20;
this.adSpecialKeyWordsListBox.Location = new System.Drawing.Point(377, 38);
this.adSpecialKeyWordsListBox.Name = "adSpecialKeyWordsListBox";
this.mainLayoutPanel.SetRowSpan(this.adSpecialKeyWordsListBox, 2);
this.adSpecialKeyWordsListBox.Size = new System.Drawing.Size(369, 522);
this.adSpecialKeyWordsListBox.Sorted = true;
this.adSpecialKeyWordsListBox.TabIndex = 1;
//
// registerAdSpecialPanel
//
this.registerAdSpecialPanel.Controls.Add(this.notificationLabel);
this.registerAdSpecialPanel.Controls.Add(this.enterNewKeyWordTextBox);
this.registerAdSpecialPanel.Controls.Add(this.registerKeyWordButton);
this.registerAdSpecialPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.registerAdSpecialPanel.Location = new System.Drawing.Point(3, 38);
this.registerAdSpecialPanel.Name = "registerAdSpecialPanel";
this.registerAdSpecialPanel.Size = new System.Drawing.Size(368, 258);
this.registerAdSpecialPanel.TabIndex = 3;
//
// enterNewKeyWordTextBox
//
this.enterNewKeyWordTextBox.Location = new System.Drawing.Point(3, 14);
this.enterNewKeyWordTextBox.Name = "enterNewKeyWordTextBox";
this.enterNewKeyWordTextBox.Size = new System.Drawing.Size(257, 26);
this.enterNewKeyWordTextBox.TabIndex = 0;
//
// registerKeyWordButton
//
this.registerKeyWordButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.registerKeyWordButton.Location = new System.Drawing.Point(170, 211);
this.registerKeyWordButton.Name = "registerKeyWordButton";
this.registerKeyWordButton.Size = new System.Drawing.Size(195, 44);
this.registerKeyWordButton.TabIndex = 2;
this.registerKeyWordButton.Text = "Add new Key Word";
this.registerKeyWordButton.UseVisualStyleBackColor = true;
this.registerKeyWordButton.Click += new System.EventHandler(this.registerKeyWordButton_Click);
//
// enterKeyWordHeaderLabel
//
this.enterKeyWordHeaderLabel.AutoSize = true;
this.enterKeyWordHeaderLabel.Dock = System.Windows.Forms.DockStyle.Fill;
this.enterKeyWordHeaderLabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.enterKeyWordHeaderLabel.Location = new System.Drawing.Point(3, 0);
this.enterKeyWordHeaderLabel.Name = "enterKeyWordHeaderLabel";
this.enterKeyWordHeaderLabel.Size = new System.Drawing.Size(368, 35);
this.enterKeyWordHeaderLabel.TabIndex = 4;
this.enterKeyWordHeaderLabel.Text = "Enter New Ad Special Key Word:";
//
// DELETE
//
this.DELETE.Enabled = false;
this.DELETE.Location = new System.Drawing.Point(3, 302);
this.DELETE.Name = "DELETE";
this.DELETE.Size = new System.Drawing.Size(164, 36);
this.DELETE.TabIndex = 5;
this.DELETE.Text = "Delete Ad Special";
this.DELETE.UseVisualStyleBackColor = true;
this.DELETE.Click += new System.EventHandler(this.DELETE_Click);
//
// notificationLabel
//
this.notificationLabel.AutoSize = true;
this.notificationLabel.Location = new System.Drawing.Point(9, 83);
this.notificationLabel.Name = "notificationLabel";
this.notificationLabel.Size = new System.Drawing.Size(0, 20);
this.notificationLabel.TabIndex = 3;
//
// FrmAdSpecialRegister
//
this.AcceptButton = this.registerKeyWordButton;
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(749, 563);
this.Controls.Add(this.mainLayoutPanel);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.Fixed3D;
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Name = "FrmAdSpecialRegister";
this.Text = "Register Ad Specials";
this.Load += new System.EventHandler(this.frmAdSpecialRegister_Load);
this.mainLayoutPanel.ResumeLayout(false);
this.mainLayoutPanel.PerformLayout();
this.registerAdSpecialPanel.ResumeLayout(false);
this.registerAdSpecialPanel.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.TableLayoutPanel mainLayoutPanel;
private System.Windows.Forms.Label currentAdSpecialKeyWords;
private System.Windows.Forms.ListBox adSpecialKeyWordsListBox;
private System.Windows.Forms.Panel registerAdSpecialPanel;
private System.Windows.Forms.TextBox enterNewKeyWordTextBox;
private System.Windows.Forms.Button registerKeyWordButton;
private System.Windows.Forms.Label enterKeyWordHeaderLabel;
private System.Windows.Forms.Button DELETE;
private System.Windows.Forms.Label notificationLabel;
}
}
@@ -0,0 +1,93 @@
using System;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
public partial class FrmAdSpecialRegister : Form
{
public FrmAdSpecialRegister()
{
InitializeComponent();
}
private void frmAdSpecialRegister_Load(object sender, EventArgs e)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var groupNameCollection = databaseReader.ReturnGroupNameList(databaseTracker.DatabaseConnectionString);
adSpecialKeyWordsListBox.SelectedIndexChanged += AdSpecialKeyWordsListBox_SelectedIndexChanged;
foreach (var groupName in groupNameCollection)
{
adSpecialKeyWordsListBox.Items.Add(groupName);
}
}
private void AdSpecialKeyWordsListBox_SelectedIndexChanged(object sender, EventArgs e)
{
var listBox = (ListBox) sender;
if (listBox.SelectedIndex == -1)
{
DELETE.Enabled = false;
return;
}
DELETE.Enabled = true;
}
private void registerKeyWordButton_Click(object sender, EventArgs e)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var databaseWriter = new DatabaseWriter(databaseTracker.DatabaseConnectionString);
int rowsEffected = 0;
if (enterNewKeyWordTextBox.Text == "") return;
rowsEffected = databaseWriter.RedundantlessInsertIntoGroupCategory(enterNewKeyWordTextBox.Text);
if (rowsEffected == 1)
{
RowParsing.AdSpecialGroups.Add(enterNewKeyWordTextBox.Text);
var groupNameCollection = databaseReader.ReturnGroupNameList(databaseTracker.DatabaseConnectionString);
adSpecialKeyWordsListBox.Items.Clear();
foreach (var groupName in groupNameCollection)
{
adSpecialKeyWordsListBox.Items.Add(groupName);
}
enterNewKeyWordTextBox.Text = "";
enterNewKeyWordTextBox.Focus();
}
else
{
MessageBox.Show(
"An error has occurred trying to write " + enterNewKeyWordTextBox.Text + " to the database.",
"Unknown Write Error");
}
}
private void DELETE_Click(object sender, EventArgs e)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var databaseWriter = new DatabaseWriter(databaseTracker.DatabaseConnectionString);
var adSpecial = adSpecialKeyWordsListBox.SelectedItem.ToString();
var rowsEffected = databaseWriter.RemoveAdSpecialMember(adSpecial);
if (rowsEffected == 0)
{
notificationLabel.Text = "Failed to delete " + adSpecial + " from the database.";
}
else if (rowsEffected > 0)
{
notificationLabel.Text = "Successfully deleted " + adSpecial + " from the database.";
}
adSpecialKeyWordsListBox.Items.Clear();
var groupNameCollection = databaseReader.ReturnGroupNameList(databaseTracker.DatabaseConnectionString);
foreach (var groupName in groupNameCollection)
{
adSpecialKeyWordsListBox.Items.Add(groupName);
}
DELETE.Enabled = false;
}
}
}
File diff suppressed because it is too large Load Diff
+409
View File
@@ -0,0 +1,409 @@
namespace AdvertsingProfitControl
{
partial class FrmAddRecord
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmAddRecord));
this.mainLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.addRecordTabControl = new System.Windows.Forms.TabControl();
this.projectionsTabPage = new System.Windows.Forms.TabPage();
this.projectionsDataGridView = new System.Windows.Forms.DataGridView();
this.actualSalesTabPage = new System.Windows.Forms.TabPage();
this.actualSalesDataGridView = new System.Windows.Forms.DataGridView();
this.suppliersTabPage = new System.Windows.Forms.TabPage();
this.suppliersDataGridView = new System.Windows.Forms.DataGridView();
this.weeklySalesTabPage = new System.Windows.Forms.TabPage();
this.weeklySalesDataGridView = new System.Windows.Forms.DataGridView();
this.mainMenu = new System.Windows.Forms.MenuStrip();
this.fileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.clearFormFileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.closeFormFileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.commentsAndDateLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.dateGroupBox = new System.Windows.Forms.GroupBox();
this.dateFormatLabel = new System.Windows.Forms.Label();
this.weekEndingDateMaskedTextBox = new System.Windows.Forms.MaskedTextBox();
this.commentsGroupBox = new System.Windows.Forms.GroupBox();
this.commentsTextBox = new System.Windows.Forms.TextBox();
this.errorReportingLabel = new System.Windows.Forms.Label();
this.addRecordsButton = new System.Windows.Forms.Button();
this.mainLayoutPanel.SuspendLayout();
this.addRecordTabControl.SuspendLayout();
this.projectionsTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.projectionsDataGridView)).BeginInit();
this.actualSalesTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.actualSalesDataGridView)).BeginInit();
this.suppliersTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.suppliersDataGridView)).BeginInit();
this.weeklySalesTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.weeklySalesDataGridView)).BeginInit();
this.mainMenu.SuspendLayout();
this.commentsAndDateLayoutPanel.SuspendLayout();
this.dateGroupBox.SuspendLayout();
this.commentsGroupBox.SuspendLayout();
this.SuspendLayout();
//
// mainLayoutPanel
//
this.mainLayoutPanel.ColumnCount = 1;
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 37F));
this.mainLayoutPanel.Controls.Add(this.addRecordTabControl, 0, 1);
this.mainLayoutPanel.Controls.Add(this.mainMenu, 0, 0);
this.mainLayoutPanel.Controls.Add(this.commentsAndDateLayoutPanel, 0, 2);
this.mainLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainLayoutPanel.Location = new System.Drawing.Point(0, 0);
this.mainLayoutPanel.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.mainLayoutPanel.Name = "mainLayoutPanel";
this.mainLayoutPanel.RowCount = 3;
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 46F));
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 80F));
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
this.mainLayoutPanel.Size = new System.Drawing.Size(1562, 894);
this.mainLayoutPanel.TabIndex = 0;
//
// addRecordTabControl
//
this.addRecordTabControl.Controls.Add(this.projectionsTabPage);
this.addRecordTabControl.Controls.Add(this.actualSalesTabPage);
this.addRecordTabControl.Controls.Add(this.suppliersTabPage);
this.addRecordTabControl.Controls.Add(this.weeklySalesTabPage);
this.addRecordTabControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.addRecordTabControl.Location = new System.Drawing.Point(5, 52);
this.addRecordTabControl.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.addRecordTabControl.Name = "addRecordTabControl";
this.addRecordTabControl.SelectedIndex = 0;
this.addRecordTabControl.Size = new System.Drawing.Size(1552, 666);
this.addRecordTabControl.TabIndex = 1;
//
// projectionsTabPage
//
this.projectionsTabPage.Controls.Add(this.projectionsDataGridView);
this.projectionsTabPage.Location = new System.Drawing.Point(4, 33);
this.projectionsTabPage.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.projectionsTabPage.Name = "projectionsTabPage";
this.projectionsTabPage.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.projectionsTabPage.Size = new System.Drawing.Size(1544, 629);
this.projectionsTabPage.TabIndex = 0;
this.projectionsTabPage.Text = "Projections";
this.projectionsTabPage.UseVisualStyleBackColor = true;
//
// projectionsDataGridView
//
this.projectionsDataGridView.AllowUserToResizeRows = false;
this.projectionsDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.projectionsDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.projectionsDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.projectionsDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.projectionsDataGridView.Location = new System.Drawing.Point(5, 6);
this.projectionsDataGridView.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.projectionsDataGridView.MultiSelect = false;
this.projectionsDataGridView.Name = "projectionsDataGridView";
this.projectionsDataGridView.Size = new System.Drawing.Size(1534, 617);
this.projectionsDataGridView.TabIndex = 0;
//
// actualSalesTabPage
//
this.actualSalesTabPage.Controls.Add(this.actualSalesDataGridView);
this.actualSalesTabPage.Location = new System.Drawing.Point(4, 33);
this.actualSalesTabPage.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.actualSalesTabPage.Name = "actualSalesTabPage";
this.actualSalesTabPage.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.actualSalesTabPage.Size = new System.Drawing.Size(1544, 629);
this.actualSalesTabPage.TabIndex = 1;
this.actualSalesTabPage.Text = "Actual Sales";
this.actualSalesTabPage.UseVisualStyleBackColor = true;
//
// actualSalesDataGridView
//
this.actualSalesDataGridView.AllowUserToResizeRows = false;
this.actualSalesDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.actualSalesDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.actualSalesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.actualSalesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.actualSalesDataGridView.Location = new System.Drawing.Point(5, 6);
this.actualSalesDataGridView.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.actualSalesDataGridView.MultiSelect = false;
this.actualSalesDataGridView.Name = "actualSalesDataGridView";
this.actualSalesDataGridView.Size = new System.Drawing.Size(1534, 617);
this.actualSalesDataGridView.TabIndex = 0;
//
// suppliersTabPage
//
this.suppliersTabPage.Controls.Add(this.suppliersDataGridView);
this.suppliersTabPage.Location = new System.Drawing.Point(4, 33);
this.suppliersTabPage.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.suppliersTabPage.Name = "suppliersTabPage";
this.suppliersTabPage.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.suppliersTabPage.Size = new System.Drawing.Size(1544, 629);
this.suppliersTabPage.TabIndex = 2;
this.suppliersTabPage.Text = "Suppliers";
this.suppliersTabPage.UseVisualStyleBackColor = true;
//
// suppliersDataGridView
//
this.suppliersDataGridView.AllowUserToResizeRows = false;
this.suppliersDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.suppliersDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.suppliersDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.suppliersDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.suppliersDataGridView.Location = new System.Drawing.Point(5, 6);
this.suppliersDataGridView.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.suppliersDataGridView.MultiSelect = false;
this.suppliersDataGridView.Name = "suppliersDataGridView";
this.suppliersDataGridView.Size = new System.Drawing.Size(1534, 617);
this.suppliersDataGridView.TabIndex = 0;
//
// weeklySalesTabPage
//
this.weeklySalesTabPage.Controls.Add(this.weeklySalesDataGridView);
this.weeklySalesTabPage.Location = new System.Drawing.Point(4, 33);
this.weeklySalesTabPage.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.weeklySalesTabPage.Name = "weeklySalesTabPage";
this.weeklySalesTabPage.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.weeklySalesTabPage.Size = new System.Drawing.Size(1544, 629);
this.weeklySalesTabPage.TabIndex = 3;
this.weeklySalesTabPage.Text = "Weekly Sales";
this.weeklySalesTabPage.UseVisualStyleBackColor = true;
//
// weeklySalesDataGridView
//
this.weeklySalesDataGridView.AllowUserToAddRows = false;
this.weeklySalesDataGridView.AllowUserToDeleteRows = false;
this.weeklySalesDataGridView.AllowUserToResizeRows = false;
this.weeklySalesDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.weeklySalesDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.weeklySalesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.weeklySalesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.weeklySalesDataGridView.Location = new System.Drawing.Point(5, 6);
this.weeklySalesDataGridView.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.weeklySalesDataGridView.MultiSelect = false;
this.weeklySalesDataGridView.Name = "weeklySalesDataGridView";
this.weeklySalesDataGridView.Size = new System.Drawing.Size(1534, 617);
this.weeklySalesDataGridView.TabIndex = 0;
//
// mainMenu
//
this.mainMenu.ImageScalingSize = new System.Drawing.Size(24, 24);
this.mainMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.fileMainMenu});
this.mainMenu.Location = new System.Drawing.Point(0, 0);
this.mainMenu.Name = "mainMenu";
this.mainMenu.Padding = new System.Windows.Forms.Padding(11, 4, 0, 4);
this.mainMenu.Size = new System.Drawing.Size(1562, 42);
this.mainMenu.TabIndex = 2;
this.mainMenu.Text = "menuStrip1";
//
// fileMainMenu
//
this.fileMainMenu.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.clearFormFileMainMenu,
this.closeFormFileMainMenu});
this.fileMainMenu.Name = "fileMainMenu";
this.fileMainMenu.Size = new System.Drawing.Size(56, 34);
this.fileMainMenu.Text = "&File";
//
// clearFormFileMainMenu
//
this.clearFormFileMainMenu.Name = "clearFormFileMainMenu";
this.clearFormFileMainMenu.Size = new System.Drawing.Size(208, 34);
this.clearFormFileMainMenu.Text = "C&lear Form";
this.clearFormFileMainMenu.Click += new System.EventHandler(this.clearFormFileMainMenu_Click);
//
// closeFormFileMainMenu
//
this.closeFormFileMainMenu.Name = "closeFormFileMainMenu";
this.closeFormFileMainMenu.Size = new System.Drawing.Size(208, 34);
this.closeFormFileMainMenu.Text = "&Close Form";
this.closeFormFileMainMenu.Click += new System.EventHandler(this.closeFileMainMenu_Click);
//
// commentsAndDateLayoutPanel
//
this.commentsAndDateLayoutPanel.AutoSize = true;
this.commentsAndDateLayoutPanel.ColumnCount = 4;
this.commentsAndDateLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 15F));
this.commentsAndDateLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 35F));
this.commentsAndDateLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 40F));
this.commentsAndDateLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 10F));
this.commentsAndDateLayoutPanel.Controls.Add(this.dateGroupBox, 0, 0);
this.commentsAndDateLayoutPanel.Controls.Add(this.commentsGroupBox, 1, 0);
this.commentsAndDateLayoutPanel.Controls.Add(this.errorReportingLabel, 2, 0);
this.commentsAndDateLayoutPanel.Controls.Add(this.addRecordsButton, 3, 0);
this.commentsAndDateLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentsAndDateLayoutPanel.Location = new System.Drawing.Point(5, 730);
this.commentsAndDateLayoutPanel.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.commentsAndDateLayoutPanel.Name = "commentsAndDateLayoutPanel";
this.commentsAndDateLayoutPanel.RowCount = 1;
this.commentsAndDateLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.commentsAndDateLayoutPanel.Size = new System.Drawing.Size(1552, 158);
this.commentsAndDateLayoutPanel.TabIndex = 3;
//
// dateGroupBox
//
this.dateGroupBox.Controls.Add(this.dateFormatLabel);
this.dateGroupBox.Controls.Add(this.weekEndingDateMaskedTextBox);
this.dateGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.dateGroupBox.Location = new System.Drawing.Point(5, 6);
this.dateGroupBox.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.dateGroupBox.Name = "dateGroupBox";
this.dateGroupBox.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.dateGroupBox.Size = new System.Drawing.Size(222, 146);
this.dateGroupBox.TabIndex = 0;
this.dateGroupBox.TabStop = false;
this.dateGroupBox.Text = "Week Ending Date";
//
// dateFormatLabel
//
this.dateFormatLabel.AutoSize = true;
this.dateFormatLabel.Location = new System.Drawing.Point(35, 32);
this.dateFormatLabel.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.dateFormatLabel.Name = "dateFormatLabel";
this.dateFormatLabel.Size = new System.Drawing.Size(138, 50);
this.dateFormatLabel.TabIndex = 1;
this.dateFormatLabel.Text = "Date Format: \r\nMM/DD/YYYY";
//
// weekEndingDateMaskedTextBox
//
this.weekEndingDateMaskedTextBox.Font = new System.Drawing.Font("Times New Roman", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.weekEndingDateMaskedTextBox.Location = new System.Drawing.Point(32, 92);
this.weekEndingDateMaskedTextBox.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.weekEndingDateMaskedTextBox.Mask = "00/00/0000";
this.weekEndingDateMaskedTextBox.Name = "weekEndingDateMaskedTextBox";
this.weekEndingDateMaskedTextBox.Size = new System.Drawing.Size(141, 40);
this.weekEndingDateMaskedTextBox.TabIndex = 0;
this.weekEndingDateMaskedTextBox.ValidatingType = typeof(System.DateTime);
//
// commentsGroupBox
//
this.commentsGroupBox.Controls.Add(this.commentsTextBox);
this.commentsGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentsGroupBox.Location = new System.Drawing.Point(237, 6);
this.commentsGroupBox.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.commentsGroupBox.Name = "commentsGroupBox";
this.commentsGroupBox.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.commentsGroupBox.Size = new System.Drawing.Size(533, 146);
this.commentsGroupBox.TabIndex = 1;
this.commentsGroupBox.TabStop = false;
this.commentsGroupBox.Text = "Comments";
//
// commentsTextBox
//
this.commentsTextBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentsTextBox.Location = new System.Drawing.Point(5, 28);
this.commentsTextBox.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.commentsTextBox.Multiline = true;
this.commentsTextBox.Name = "commentsTextBox";
this.commentsTextBox.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
this.commentsTextBox.Size = new System.Drawing.Size(523, 112);
this.commentsTextBox.TabIndex = 0;
//
// errorReportingLabel
//
this.errorReportingLabel.AutoSize = true;
this.errorReportingLabel.Location = new System.Drawing.Point(780, 0);
this.errorReportingLabel.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
this.errorReportingLabel.Name = "errorReportingLabel";
this.errorReportingLabel.Size = new System.Drawing.Size(0, 25);
this.errorReportingLabel.TabIndex = 2;
//
// addRecordsButton
//
this.addRecordsButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.addRecordsButton.Location = new System.Drawing.Point(1400, 110);
this.addRecordsButton.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.addRecordsButton.Name = "addRecordsButton";
this.addRecordsButton.Size = new System.Drawing.Size(147, 42);
this.addRecordsButton.TabIndex = 3;
this.addRecordsButton.Text = "Add Records";
this.addRecordsButton.UseVisualStyleBackColor = true;
this.addRecordsButton.Click += new System.EventHandler(this.addRecordsButton_Click);
//
// FrmAddRecord
//
this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 24F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1562, 894);
this.Controls.Add(this.mainLayoutPanel);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.MainMenuStrip = this.mainMenu;
this.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.MaximumSize = new System.Drawing.Size(1631, 1059);
this.MinimumSize = new System.Drawing.Size(1448, 874);
this.Name = "FrmAddRecord";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "Add New Records";
this.Load += new System.EventHandler(this.frmAddRecord_Load);
this.mainLayoutPanel.ResumeLayout(false);
this.mainLayoutPanel.PerformLayout();
this.addRecordTabControl.ResumeLayout(false);
this.projectionsTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.projectionsDataGridView)).EndInit();
this.actualSalesTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.actualSalesDataGridView)).EndInit();
this.suppliersTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.suppliersDataGridView)).EndInit();
this.weeklySalesTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.weeklySalesDataGridView)).EndInit();
this.mainMenu.ResumeLayout(false);
this.mainMenu.PerformLayout();
this.commentsAndDateLayoutPanel.ResumeLayout(false);
this.commentsAndDateLayoutPanel.PerformLayout();
this.dateGroupBox.ResumeLayout(false);
this.dateGroupBox.PerformLayout();
this.commentsGroupBox.ResumeLayout(false);
this.commentsGroupBox.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.TableLayoutPanel mainLayoutPanel;
private System.Windows.Forms.TabControl addRecordTabControl;
private System.Windows.Forms.TabPage projectionsTabPage;
private System.Windows.Forms.DataGridView projectionsDataGridView;
private System.Windows.Forms.TabPage actualSalesTabPage;
private System.Windows.Forms.DataGridView actualSalesDataGridView;
private System.Windows.Forms.TabPage suppliersTabPage;
private System.Windows.Forms.DataGridView suppliersDataGridView;
private System.Windows.Forms.MenuStrip mainMenu;
private System.Windows.Forms.ToolStripMenuItem fileMainMenu;
private System.Windows.Forms.ToolStripMenuItem closeFormFileMainMenu;
private System.Windows.Forms.TableLayoutPanel commentsAndDateLayoutPanel;
private System.Windows.Forms.GroupBox dateGroupBox;
private System.Windows.Forms.MaskedTextBox weekEndingDateMaskedTextBox;
private System.Windows.Forms.GroupBox commentsGroupBox;
private System.Windows.Forms.TextBox commentsTextBox;
private System.Windows.Forms.Label errorReportingLabel;
private System.Windows.Forms.TabPage weeklySalesTabPage;
private System.Windows.Forms.DataGridView weeklySalesDataGridView;
private System.Windows.Forms.Button addRecordsButton;
private System.Windows.Forms.ToolStripMenuItem clearFormFileMainMenu;
private System.Windows.Forms.Label dateFormatLabel;
}
}
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+505
View File
@@ -0,0 +1,505 @@
namespace AdvertsingProfitControl
{
partial class FrmDeleteRecord
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmDeleteRecord));
this.mainTableLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.mainMenu = new System.Windows.Forms.MenuStrip();
this.fileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.exitFileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.mainTabControl = new System.Windows.Forms.TabControl();
this.projectionsTabPage = new System.Windows.Forms.TabPage();
this.projectionsDataGridView = new System.Windows.Forms.DataGridView();
this.inventoryTabPage = new System.Windows.Forms.TabPage();
this.inventoryDataGridView = new System.Windows.Forms.DataGridView();
this.actualTabPage = new System.Windows.Forms.TabPage();
this.actualSalesDataGridView = new System.Windows.Forms.DataGridView();
this.suppliersTabPage = new System.Windows.Forms.TabPage();
this.suppliersDataGridView = new System.Windows.Forms.DataGridView();
this.weeklySalesTabPage = new System.Windows.Forms.TabPage();
this.weeklySalesDataGridView = new System.Windows.Forms.DataGridView();
this.secondaryLayOutPanel = new System.Windows.Forms.TableLayoutPanel();
this.commmentsGroupBox = new System.Windows.Forms.GroupBox();
this.commentsTextBox = new System.Windows.Forms.TextBox();
this.datePickerGroupBox = new System.Windows.Forms.GroupBox();
this.informationLabel = new System.Windows.Forms.Label();
this.dateSelectorFormatLable = new System.Windows.Forms.Label();
this.yearComboBox = new System.Windows.Forms.ComboBox();
this.monthComboBox = new System.Windows.Forms.ComboBox();
this.dayComboBox = new System.Windows.Forms.ComboBox();
this.clearSelectedYearGroupBox = new System.Windows.Forms.GroupBox();
this.yearClearingWarningLabel = new System.Windows.Forms.Label();
this.clearSelectedYearInfoLabel = new System.Windows.Forms.Label();
this.DELETE = new System.Windows.Forms.Button();
this.mainTableLayoutPanel.SuspendLayout();
this.mainMenu.SuspendLayout();
this.mainTabControl.SuspendLayout();
this.projectionsTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.projectionsDataGridView)).BeginInit();
this.inventoryTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.inventoryDataGridView)).BeginInit();
this.actualTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.actualSalesDataGridView)).BeginInit();
this.suppliersTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.suppliersDataGridView)).BeginInit();
this.weeklySalesTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.weeklySalesDataGridView)).BeginInit();
this.secondaryLayOutPanel.SuspendLayout();
this.commmentsGroupBox.SuspendLayout();
this.datePickerGroupBox.SuspendLayout();
this.clearSelectedYearGroupBox.SuspendLayout();
this.SuspendLayout();
//
// mainTableLayoutPanel
//
this.mainTableLayoutPanel.ColumnCount = 1;
this.mainTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.mainTableLayoutPanel.Controls.Add(this.mainMenu, 0, 0);
this.mainTableLayoutPanel.Controls.Add(this.mainTabControl, 0, 1);
this.mainTableLayoutPanel.Controls.Add(this.secondaryLayOutPanel, 0, 2);
this.mainTableLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainTableLayoutPanel.Location = new System.Drawing.Point(0, 0);
this.mainTableLayoutPanel.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.mainTableLayoutPanel.Name = "mainTableLayoutPanel";
this.mainTableLayoutPanel.RowCount = 3;
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 23F));
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 70F));
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 30F));
this.mainTableLayoutPanel.Size = new System.Drawing.Size(889, 564);
this.mainTableLayoutPanel.TabIndex = 0;
//
// mainMenu
//
this.mainMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.fileMainMenu});
this.mainMenu.Location = new System.Drawing.Point(0, 0);
this.mainMenu.Name = "mainMenu";
this.mainMenu.Padding = new System.Windows.Forms.Padding(4, 1, 0, 1);
this.mainMenu.Size = new System.Drawing.Size(889, 23);
this.mainMenu.TabIndex = 0;
this.mainMenu.Text = "menuStrip1";
//
// fileMainMenu
//
this.fileMainMenu.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.exitFileMainMenu});
this.fileMainMenu.Name = "fileMainMenu";
this.fileMainMenu.Size = new System.Drawing.Size(35, 21);
this.fileMainMenu.Text = "&File";
//
// exitFileMainMenu
//
this.exitFileMainMenu.Name = "exitFileMainMenu";
this.exitFileMainMenu.Size = new System.Drawing.Size(92, 22);
this.exitFileMainMenu.Text = "E&xit";
//
// mainTabControl
//
this.mainTabControl.Controls.Add(this.projectionsTabPage);
this.mainTabControl.Controls.Add(this.inventoryTabPage);
this.mainTabControl.Controls.Add(this.actualTabPage);
this.mainTabControl.Controls.Add(this.suppliersTabPage);
this.mainTabControl.Controls.Add(this.weeklySalesTabPage);
this.mainTabControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainTabControl.Location = new System.Drawing.Point(2, 25);
this.mainTabControl.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.mainTabControl.Name = "mainTabControl";
this.mainTabControl.SelectedIndex = 0;
this.mainTabControl.Size = new System.Drawing.Size(885, 374);
this.mainTabControl.TabIndex = 1;
//
// projectionsTabPage
//
this.projectionsTabPage.Controls.Add(this.projectionsDataGridView);
this.projectionsTabPage.Location = new System.Drawing.Point(4, 22);
this.projectionsTabPage.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.projectionsTabPage.Name = "projectionsTabPage";
this.projectionsTabPage.Padding = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.projectionsTabPage.Size = new System.Drawing.Size(877, 348);
this.projectionsTabPage.TabIndex = 0;
this.projectionsTabPage.Text = "Projections";
this.projectionsTabPage.UseVisualStyleBackColor = true;
//
// projectionsDataGridView
//
this.projectionsDataGridView.AllowUserToAddRows = false;
this.projectionsDataGridView.AllowUserToResizeRows = false;
this.projectionsDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.projectionsDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.projectionsDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.projectionsDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.projectionsDataGridView.Location = new System.Drawing.Point(2, 2);
this.projectionsDataGridView.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.projectionsDataGridView.MultiSelect = false;
this.projectionsDataGridView.Name = "projectionsDataGridView";
this.projectionsDataGridView.ReadOnly = true;
this.projectionsDataGridView.RowTemplate.Height = 28;
this.projectionsDataGridView.ShowEditingIcon = false;
this.projectionsDataGridView.Size = new System.Drawing.Size(873, 344);
this.projectionsDataGridView.TabIndex = 0;
//
// inventoryTabPage
//
this.inventoryTabPage.Controls.Add(this.inventoryDataGridView);
this.inventoryTabPage.Location = new System.Drawing.Point(4, 22);
this.inventoryTabPage.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.inventoryTabPage.Name = "inventoryTabPage";
this.inventoryTabPage.Padding = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.inventoryTabPage.Size = new System.Drawing.Size(866, 335);
this.inventoryTabPage.TabIndex = 1;
this.inventoryTabPage.Text = "Inventory";
this.inventoryTabPage.UseVisualStyleBackColor = true;
//
// inventoryDataGridView
//
this.inventoryDataGridView.AllowUserToAddRows = false;
this.inventoryDataGridView.AllowUserToResizeRows = false;
this.inventoryDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.inventoryDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.inventoryDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.inventoryDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.inventoryDataGridView.Location = new System.Drawing.Point(2, 2);
this.inventoryDataGridView.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.inventoryDataGridView.Name = "inventoryDataGridView";
this.inventoryDataGridView.ReadOnly = true;
this.inventoryDataGridView.RowTemplate.Height = 28;
this.inventoryDataGridView.ShowEditingIcon = false;
this.inventoryDataGridView.Size = new System.Drawing.Size(862, 331);
this.inventoryDataGridView.TabIndex = 0;
//
// actualTabPage
//
this.actualTabPage.Controls.Add(this.actualSalesDataGridView);
this.actualTabPage.Location = new System.Drawing.Point(4, 22);
this.actualTabPage.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.actualTabPage.Name = "actualTabPage";
this.actualTabPage.Size = new System.Drawing.Size(866, 335);
this.actualTabPage.TabIndex = 2;
this.actualTabPage.Text = "Actual Sales";
this.actualTabPage.UseVisualStyleBackColor = true;
//
// actualSalesDataGridView
//
this.actualSalesDataGridView.AllowUserToAddRows = false;
this.actualSalesDataGridView.AllowUserToResizeRows = false;
this.actualSalesDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.actualSalesDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.actualSalesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.actualSalesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.actualSalesDataGridView.Location = new System.Drawing.Point(0, 0);
this.actualSalesDataGridView.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.actualSalesDataGridView.Name = "actualSalesDataGridView";
this.actualSalesDataGridView.ReadOnly = true;
this.actualSalesDataGridView.RowTemplate.Height = 28;
this.actualSalesDataGridView.ShowEditingIcon = false;
this.actualSalesDataGridView.Size = new System.Drawing.Size(866, 335);
this.actualSalesDataGridView.TabIndex = 0;
//
// suppliersTabPage
//
this.suppliersTabPage.Controls.Add(this.suppliersDataGridView);
this.suppliersTabPage.Location = new System.Drawing.Point(4, 22);
this.suppliersTabPage.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.suppliersTabPage.Name = "suppliersTabPage";
this.suppliersTabPage.Size = new System.Drawing.Size(866, 335);
this.suppliersTabPage.TabIndex = 3;
this.suppliersTabPage.Text = "Suppliers";
this.suppliersTabPage.UseVisualStyleBackColor = true;
//
// suppliersDataGridView
//
this.suppliersDataGridView.AllowUserToAddRows = false;
this.suppliersDataGridView.AllowUserToResizeRows = false;
this.suppliersDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.suppliersDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.suppliersDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.suppliersDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.suppliersDataGridView.Location = new System.Drawing.Point(0, 0);
this.suppliersDataGridView.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.suppliersDataGridView.Name = "suppliersDataGridView";
this.suppliersDataGridView.ReadOnly = true;
this.suppliersDataGridView.RowTemplate.Height = 28;
this.suppliersDataGridView.ShowEditingIcon = false;
this.suppliersDataGridView.Size = new System.Drawing.Size(866, 335);
this.suppliersDataGridView.TabIndex = 0;
//
// weeklySalesTabPage
//
this.weeklySalesTabPage.Controls.Add(this.weeklySalesDataGridView);
this.weeklySalesTabPage.Location = new System.Drawing.Point(4, 22);
this.weeklySalesTabPage.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.weeklySalesTabPage.Name = "weeklySalesTabPage";
this.weeklySalesTabPage.Size = new System.Drawing.Size(866, 335);
this.weeklySalesTabPage.TabIndex = 4;
this.weeklySalesTabPage.Text = "Weekly Sales";
this.weeklySalesTabPage.UseVisualStyleBackColor = true;
//
// weeklySalesDataGridView
//
this.weeklySalesDataGridView.AllowUserToAddRows = false;
this.weeklySalesDataGridView.AllowUserToDeleteRows = false;
this.weeklySalesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.weeklySalesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.weeklySalesDataGridView.Enabled = false;
this.weeklySalesDataGridView.Location = new System.Drawing.Point(0, 0);
this.weeklySalesDataGridView.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.weeklySalesDataGridView.Name = "weeklySalesDataGridView";
this.weeklySalesDataGridView.ReadOnly = true;
this.weeklySalesDataGridView.RowTemplate.Height = 28;
this.weeklySalesDataGridView.ShowEditingIcon = false;
this.weeklySalesDataGridView.Size = new System.Drawing.Size(866, 335);
this.weeklySalesDataGridView.TabIndex = 0;
//
// secondaryLayOutPanel
//
this.secondaryLayOutPanel.ColumnCount = 3;
this.secondaryLayOutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.secondaryLayOutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.secondaryLayOutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.secondaryLayOutPanel.Controls.Add(this.commmentsGroupBox, 0, 0);
this.secondaryLayOutPanel.Controls.Add(this.datePickerGroupBox, 1, 0);
this.secondaryLayOutPanel.Controls.Add(this.clearSelectedYearGroupBox, 2, 0);
this.secondaryLayOutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.secondaryLayOutPanel.Location = new System.Drawing.Point(2, 403);
this.secondaryLayOutPanel.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.secondaryLayOutPanel.Name = "secondaryLayOutPanel";
this.secondaryLayOutPanel.RowCount = 1;
this.secondaryLayOutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.secondaryLayOutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 13F));
this.secondaryLayOutPanel.Size = new System.Drawing.Size(885, 159);
this.secondaryLayOutPanel.TabIndex = 2;
//
// commmentsGroupBox
//
this.commmentsGroupBox.Controls.Add(this.commentsTextBox);
this.commmentsGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commmentsGroupBox.Location = new System.Drawing.Point(2, 2);
this.commmentsGroupBox.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.commmentsGroupBox.Name = "commmentsGroupBox";
this.commmentsGroupBox.Padding = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.commmentsGroupBox.Size = new System.Drawing.Size(291, 155);
this.commmentsGroupBox.TabIndex = 0;
this.commmentsGroupBox.TabStop = false;
this.commmentsGroupBox.Text = "Comments";
//
// commentsTextBox
//
this.commentsTextBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentsTextBox.Location = new System.Drawing.Point(2, 15);
this.commentsTextBox.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.commentsTextBox.Multiline = true;
this.commentsTextBox.Name = "commentsTextBox";
this.commentsTextBox.Size = new System.Drawing.Size(287, 138);
this.commentsTextBox.TabIndex = 0;
//
// datePickerGroupBox
//
this.datePickerGroupBox.Controls.Add(this.informationLabel);
this.datePickerGroupBox.Controls.Add(this.dateSelectorFormatLable);
this.datePickerGroupBox.Controls.Add(this.yearComboBox);
this.datePickerGroupBox.Controls.Add(this.monthComboBox);
this.datePickerGroupBox.Controls.Add(this.dayComboBox);
this.datePickerGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.datePickerGroupBox.Location = new System.Drawing.Point(297, 2);
this.datePickerGroupBox.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.datePickerGroupBox.Name = "datePickerGroupBox";
this.datePickerGroupBox.Padding = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.datePickerGroupBox.Size = new System.Drawing.Size(291, 155);
this.datePickerGroupBox.TabIndex = 1;
this.datePickerGroupBox.TabStop = false;
this.datePickerGroupBox.Text = "Select A Date:";
//
// informationLabel
//
this.informationLabel.AutoSize = true;
this.informationLabel.Location = new System.Drawing.Point(1, 110);
this.informationLabel.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.informationLabel.Name = "informationLabel";
this.informationLabel.Size = new System.Drawing.Size(0, 13);
this.informationLabel.TabIndex = 4;
//
// dateSelectorFormatLable
//
this.dateSelectorFormatLable.AutoSize = true;
this.dateSelectorFormatLable.Location = new System.Drawing.Point(84, 32);
this.dateSelectorFormatLable.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.dateSelectorFormatLable.Name = "dateSelectorFormatLable";
this.dateSelectorFormatLable.Size = new System.Drawing.Size(91, 13);
this.dateSelectorFormatLable.TabIndex = 3;
this.dateSelectorFormatLable.Text = "MM / DD / YYYY";
//
// yearComboBox
//
this.yearComboBox.FormattingEnabled = true;
this.yearComboBox.Location = new System.Drawing.Point(173, 55);
this.yearComboBox.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.yearComboBox.Name = "yearComboBox";
this.yearComboBox.Size = new System.Drawing.Size(103, 21);
this.yearComboBox.TabIndex = 2;
//
// monthComboBox
//
this.monthComboBox.FormattingEnabled = true;
this.monthComboBox.Location = new System.Drawing.Point(3, 55);
this.monthComboBox.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.monthComboBox.Name = "monthComboBox";
this.monthComboBox.Size = new System.Drawing.Size(82, 21);
this.monthComboBox.TabIndex = 1;
//
// dayComboBox
//
this.dayComboBox.FormattingEnabled = true;
this.dayComboBox.Location = new System.Drawing.Point(87, 55);
this.dayComboBox.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.dayComboBox.Name = "dayComboBox";
this.dayComboBox.Size = new System.Drawing.Size(82, 21);
this.dayComboBox.TabIndex = 0;
//
// clearSelectedYearGroupBox
//
this.clearSelectedYearGroupBox.Controls.Add(this.yearClearingWarningLabel);
this.clearSelectedYearGroupBox.Controls.Add(this.clearSelectedYearInfoLabel);
this.clearSelectedYearGroupBox.Controls.Add(this.DELETE);
this.clearSelectedYearGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.clearSelectedYearGroupBox.Location = new System.Drawing.Point(592, 2);
this.clearSelectedYearGroupBox.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.clearSelectedYearGroupBox.Name = "clearSelectedYearGroupBox";
this.clearSelectedYearGroupBox.Padding = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.clearSelectedYearGroupBox.Size = new System.Drawing.Size(291, 155);
this.clearSelectedYearGroupBox.TabIndex = 2;
this.clearSelectedYearGroupBox.TabStop = false;
//
// yearClearingWarningLabel
//
this.yearClearingWarningLabel.AutoSize = true;
this.yearClearingWarningLabel.ForeColor = System.Drawing.Color.Red;
this.yearClearingWarningLabel.Location = new System.Drawing.Point(69, 72);
this.yearClearingWarningLabel.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.yearClearingWarningLabel.Name = "yearClearingWarningLabel";
this.yearClearingWarningLabel.Size = new System.Drawing.Size(152, 13);
this.yearClearingWarningLabel.TabIndex = 7;
this.yearClearingWarningLabel.Text = "This action cannot be undone!";
//
// clearSelectedYearInfoLabel
//
this.clearSelectedYearInfoLabel.AutoSize = true;
this.clearSelectedYearInfoLabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.clearSelectedYearInfoLabel.Location = new System.Drawing.Point(13, 14);
this.clearSelectedYearInfoLabel.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.clearSelectedYearInfoLabel.Name = "clearSelectedYearInfoLabel";
this.clearSelectedYearInfoLabel.Size = new System.Drawing.Size(279, 34);
this.clearSelectedYearInfoLabel.TabIndex = 6;
this.clearSelectedYearInfoLabel.Text = "Clearing the selected date will remove ALL \r\nentries for that date from the datab" +
"ase.";
//
// DELETE
//
this.DELETE.Location = new System.Drawing.Point(82, 109);
this.DELETE.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.DELETE.Name = "DELETE";
this.DELETE.Size = new System.Drawing.Size(121, 27);
this.DELETE.TabIndex = 5;
this.DELETE.Text = "Clear Selected Date";
this.DELETE.UseVisualStyleBackColor = true;
this.DELETE.Click += new System.EventHandler(this.DELETE_Click);
//
// FrmDeleteRecord
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(889, 564);
this.Controls.Add(this.mainTableLayoutPanel);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.MainMenuStrip = this.mainMenu;
this.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.MaximizeBox = false;
this.MaximumSize = new System.Drawing.Size(895, 589);
this.MinimumSize = new System.Drawing.Size(895, 589);
this.Name = "FrmDeleteRecord";
this.Text = "Delete Existing Records";
this.Load += new System.EventHandler(this.frmDeleteRecord_Load);
this.mainTableLayoutPanel.ResumeLayout(false);
this.mainTableLayoutPanel.PerformLayout();
this.mainMenu.ResumeLayout(false);
this.mainMenu.PerformLayout();
this.mainTabControl.ResumeLayout(false);
this.projectionsTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.projectionsDataGridView)).EndInit();
this.inventoryTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.inventoryDataGridView)).EndInit();
this.actualTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.actualSalesDataGridView)).EndInit();
this.suppliersTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.suppliersDataGridView)).EndInit();
this.weeklySalesTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.weeklySalesDataGridView)).EndInit();
this.secondaryLayOutPanel.ResumeLayout(false);
this.commmentsGroupBox.ResumeLayout(false);
this.commmentsGroupBox.PerformLayout();
this.datePickerGroupBox.ResumeLayout(false);
this.datePickerGroupBox.PerformLayout();
this.clearSelectedYearGroupBox.ResumeLayout(false);
this.clearSelectedYearGroupBox.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.TableLayoutPanel mainTableLayoutPanel;
private System.Windows.Forms.MenuStrip mainMenu;
private System.Windows.Forms.ToolStripMenuItem fileMainMenu;
private System.Windows.Forms.ToolStripMenuItem exitFileMainMenu;
private System.Windows.Forms.TabControl mainTabControl;
private System.Windows.Forms.TabPage projectionsTabPage;
private System.Windows.Forms.TabPage inventoryTabPage;
private System.Windows.Forms.TabPage actualTabPage;
private System.Windows.Forms.TabPage suppliersTabPage;
private System.Windows.Forms.TabPage weeklySalesTabPage;
private System.Windows.Forms.TableLayoutPanel secondaryLayOutPanel;
private System.Windows.Forms.GroupBox commmentsGroupBox;
private System.Windows.Forms.TextBox commentsTextBox;
private System.Windows.Forms.DataGridView projectionsDataGridView;
private System.Windows.Forms.DataGridView inventoryDataGridView;
private System.Windows.Forms.DataGridView actualSalesDataGridView;
private System.Windows.Forms.DataGridView suppliersDataGridView;
private System.Windows.Forms.DataGridView weeklySalesDataGridView;
private System.Windows.Forms.GroupBox datePickerGroupBox;
private System.Windows.Forms.Label dateSelectorFormatLable;
private System.Windows.Forms.ComboBox yearComboBox;
private System.Windows.Forms.ComboBox monthComboBox;
private System.Windows.Forms.ComboBox dayComboBox;
private System.Windows.Forms.Label informationLabel;
private System.Windows.Forms.Button DELETE;
private System.Windows.Forms.GroupBox clearSelectedYearGroupBox;
private System.Windows.Forms.Label yearClearingWarningLabel;
private System.Windows.Forms.Label clearSelectedYearInfoLabel;
}
}
+443
View File
@@ -0,0 +1,443 @@
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Windows.Forms;
using System.Text.RegularExpressions;
namespace AdvertsingProfitControl
{
public partial class FrmDeleteRecord : Form
{
readonly FrmLogConsole _console = FrmLogConsole.GetStaticInstance;
private List<string> _gDateStringCollection = new List<string>();
private string _lastComment = "";
public FrmDeleteRecord()
{
InitializeComponent();
}
private void frmDeleteRecord_Load(object sender, EventArgs e)
{
FillDateSuggestionComboBoxes();
BuildAndFillDataGridViews();
//Setup event handlers
projectionsDataGridView.UserDeletingRow += ClearRecordFromDatabaseOnRemoving;
inventoryDataGridView.UserDeletingRow += ClearRecordFromDatabaseOnRemoving;
actualSalesDataGridView.UserDeletingRow += ClearRecordFromDatabaseOnRemoving;
suppliersDataGridView.UserDeletingRow += ClearInvoiceFromDatabaseOnRemoving;
commentsTextBox.Leave += UpdateCommentsOnLeave;
}
/// <summary>
/// Event USed: UserDeletingRow
///
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void ClearInvoiceFromDatabaseOnRemoving(object sender, DataGridViewRowCancelEventArgs e)
{
var dataGridView = (DataGridView) sender;
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var databaseWriter = new DatabaseWriter(databaseTracker.DatabaseConnectionString);
var dateId = databaseReader.RetrieveDateIdByDateString(monthComboBox.Text + "/" + dayComboBox.Text + "/" + yearComboBox.Text, databaseTracker.DatabaseConnectionString);
if (dateId == "0")
{
informationLabel.Text = "An error has occurred trying to obtain the ID\nfor the date " +
monthComboBox.Text + "/" + dayComboBox.Text + "/" + yearComboBox.Text + ".";
}
var supplierName = dataGridView.Rows[e.Row.Index].Cells[0].EditedFormattedValue.ToString();
var invoiceNumber = dataGridView.Rows[e.Row.Index].Cells[1].EditedFormattedValue.ToString();
var count = databaseWriter.RemoveInvoice(invoiceNumber, dateId);
if (count == 1)
{
informationLabel.Text = "Successfully removed the invoice from " + supplierName +
" with\nthe invoice number of " + invoiceNumber + ".";
}
else if(count == 0)
{
informationLabel.Text = "Failed to remove the invoice from " + supplierName + " from the database.";
e.Cancel = true;
}
}
/// <summary>
/// Event Used: Leave
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void UpdateCommentsOnLeave(object sender, EventArgs e)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var datbaseWriter = new DatabaseWriter(databaseTracker.DatabaseConnectionString);
if (commentsTextBox.Text == _lastComment)
{
return;
}
var dateId =
databaseReader.RetrieveDateIdByDateString(monthComboBox.Text + "/" + dayComboBox.Text + "/" +
yearComboBox.Text, databaseTracker.DatabaseConnectionString);
if (dateId == "0"){ informationLabel.Text = "unable to find date in database."; return; }
var recordsAffected = datbaseWriter.UpdateCommentsByDateId(commentsTextBox.Text, dateId);
if (recordsAffected == true)
{
informationLabel.Text = "Successfully updated the comments for the selected date.";
}
else
{
informationLabel.Text = "Failed to update the comments for the selected date.";
}
_lastComment = commentsTextBox.Text;
}
/// <summary>
/// Event Used: UserDeletingRow
/// Clears the record in the row being deleted from the database.
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void ClearRecordFromDatabaseOnRemoving(object sender, DataGridViewRowCancelEventArgs e)
{
var dataGridView = (DataGridView) sender;
var databaseTracker = new DatabaseTracker();
var databaseWriter = new DatabaseWriter(databaseTracker.DatabaseConnectionString);
var databaseReader = new DatabaseReader();
var dateId = databaseReader.RetrieveDateIdByDateString(monthComboBox.Text + "/" + dayComboBox.Text + "/" + yearComboBox.Text, databaseTracker.DatabaseConnectionString);
var adItemName = e.Row.Cells[0].EditedFormattedValue.ToString();
var adItemId = databaseReader.RetrieveAdItemId(adItemName, databaseTracker.DatabaseConnectionString);
var count = databaseWriter.RemoveRecord(adItemId, dateId);
if (count == 1)
{
informationLabel.Text = "Successfully removed " + adItemName + " from the database.";
//
projectionsDataGridView.UserDeletingRow -= ClearRecordFromDatabaseOnRemoving;
inventoryDataGridView.UserDeletingRow -= ClearRecordFromDatabaseOnRemoving;
actualSalesDataGridView.UserDeletingRow -= ClearRecordFromDatabaseOnRemoving;
//Maybe make this based on tab page index.
if (dataGridView.Name == "projectionsDataGridView")
{
inventoryDataGridView.Rows.RemoveAt(e.Row.Index);
actualSalesDataGridView.Rows.RemoveAt(e.Row.Index);
}
else if (dataGridView.Name == "inventoryDataGridView")
{
projectionsDataGridView.Rows.RemoveAt(e.Row.Index);
actualSalesDataGridView.Rows.RemoveAt(e.Row.Index);
}
else if (dataGridView.Name == "actualSalesDataGridView")
{
projectionsDataGridView.Rows.RemoveAt(e.Row.Index);
inventoryDataGridView.Rows.RemoveAt(e.Row.Index);
}
}
else
{
informationLabel.Text = "Failed to remove " + adItemName + " from the database.";
e.Cancel = true;
}
projectionsDataGridView.UserDeletingRow += ClearRecordFromDatabaseOnRemoving;
inventoryDataGridView.UserDeletingRow += ClearRecordFromDatabaseOnRemoving;
actualSalesDataGridView.UserDeletingRow += ClearRecordFromDatabaseOnRemoving;
}
private void UpdateDataGridViewInformation(object sender, EventArgs e)
{
string dateString = monthComboBox.Text + "/" + dayComboBox.Text + "/" + yearComboBox.Text;
BuildAndFillDataGridViews(dateString);
}
private void BuildAndFillDataGridViews(string dateString = "")
{
var databaseTracker = new DatabaseTracker();
var dataBaseReader = new DatabaseReader();
string dateId;
//Check to see if a parameter has been passed.
if (dateString == "")
{
//IF non were, then grab the most recent date ID from the database and use that.
dateId = dataBaseReader.RetrieveMostRecentDateId(databaseTracker.DatabaseConnectionString);
_console.WriteToLog(FrmLogConsole.Level.Info, dateId != "0" ? "Most recent date ID is " + dateId : "Most recent date ID is unavailable.");
}
else
{
//ELSE IF one was passed, then use it's ID to build the tables.
dateId = dataBaseReader.RetrieveDateIdByDateString(dateString, databaseTracker.DatabaseConnectionString);
_console.WriteToLog(FrmLogConsole.Level.Info, dateId != "0" ? "Date ID for " + dateString + " is resolved to have the ID of " + dateId + "." : "The date " + dateString + " could not be found in the database.");
if (dateId == "0")
{
_gDateStringCollection.Remove(dateString);
}
}
//Now check to make sure there were no errors grabbing the ID, IF there were return.
if (dateId == "0") return;
//Clear all DataGridViews since the date supplied is valid and in the database.
projectionsDataGridView.DataSource = null;
inventoryDataGridView.DataSource = null;
actualSalesDataGridView.DataSource = null;
suppliersDataGridView.DataSource = null;
weeklySalesDataGridView.DataSource = null;
//Fill the tables from the database.
projectionsDataGridView.DataSource = CleanDataTable(dataBaseReader.ReturnProjectionsTable(dateId, databaseTracker.DatabaseConnectionString));
inventoryDataGridView.DataSource = CleanDataTable(dataBaseReader.ReturnInventoryTable(dateId, databaseTracker.DatabaseConnectionString));
actualSalesDataGridView.DataSource = CleanDataTable(dataBaseReader.ReturnActualSales(dateId, databaseTracker.DatabaseConnectionString));
suppliersDataGridView.DataSource = dataBaseReader.ReturnInvoiceTable(dateId, databaseTracker.DatabaseConnectionString);
weeklySalesDataGridView.DataSource = dataBaseReader.ReturnWeeklySalesFromDateId(dateId, databaseTracker.DatabaseConnectionString);
commentsTextBox.Text = dataBaseReader.RetrieveComments(dateId, databaseTracker.DatabaseConnectionString);
if (commentsTextBox.Text.StartsWith("No comments"))
{
commentsTextBox.Enabled = false;
}
else
{
commentsTextBox.Enabled = true;
_lastComment = commentsTextBox.Text;
}
}
private DataTable CleanDataTable(DataTable table)
{
if (table.Columns[table.Columns.Count - 1].ColumnName == "FK_GroupID")
{
table.Columns.RemoveAt(table.Columns.Count - 1);
}
var cleanedTable = table;
return cleanedTable;
}
/// <summary>
/// Grabs all dates from the database and splits the returned strings
/// into months, days, and years and stores them in their respective
/// combo boxes to display to the user. Also stores the list of dates
/// inside a class wide variable.
/// </summary>
private void FillDateSuggestionComboBoxes()
{
//Create a connection to the database reader class.
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
//Grab the most recent date in the database.
var mostRecentDateTime = databaseReader.RetrieveMostRecentDateString(databaseTracker.DatabaseConnectionString);
var mostRecentDateString = mostRecentDateTime.ToString("MM/dd/yyyy");
//Check to see if the return value is null and IF so log the error and return.
if (mostRecentDateString == "") { _console.WriteToLog(FrmLogConsole.Level.Error, "No dates could be found in the database."); return; }
//Otherwise, if there was a return date, split it into a array.
var mostRecentDateParts = mostRecentDateString.Split('/');
//Grab only the most recent years in the database (only say 2015) and fill a table with the dates. Indexes are as follows: [0] is Month, [1] is Day and [2] is Year.
List<DateTime> dateList = databaseReader.RetrieveDateListByYear(mostRecentDateParts[2].ToString(), databaseTracker.DatabaseConnectionString);
//Suspend the control's drawing so the user doesn't see any ugly enumeration and index changing.
DrawingControl.SuspendDrawing(secondaryLayOutPanel);
//Considering there was a return value for the most recent date, its safe to assume there is at least one date in the database, so clear the class's date collection.
_gDateStringCollection.Clear();
monthComboBox.Items.Clear();
dayComboBox.Items.Clear();
yearComboBox.Items.Clear();
monthComboBox.SelectedIndexChanged -= UpdateDaysOfMonth;
dayComboBox.SelectedIndexChanged -= UpdateDataGridViewInformation;
yearComboBox.SelectedIndexChanged -= UpdateDaysOfMonthByYear;
//Now spin through the oneYearDatesTable and fill the class wide object with all the dates for the most recent year.
for (var i = 0; i < dateList.Count; i++)
{
var fullDateString = dateList[i].ToString("MM/dd/yyyy");
//Check for nulls just to be paranoid.
if (fullDateString == "")
{
return;
}
//IF the date string collection already contains the date, then continue to the next iteration.
if (_gDateStringCollection.Contains(fullDateString))
{
continue;
}
_gDateStringCollection.Add(fullDateString);
}
var dayBasedOnMonthAndYeaRegex = new Regex("^0?" + mostRecentDateParts[0] + @"/\d{2}/" + mostRecentDateParts[2]);
var monthBasedOnYearRegex = new Regex(@"^\d{2}/\d{2}/" + mostRecentDateParts[2]);
for (var i = 0; i < _gDateStringCollection.Count; i++)
{
string[] dateArray = _gDateStringCollection[i].Split('/');
var month = dateArray[0];
var day = dateArray[1];
if (dayBasedOnMonthAndYeaRegex.IsMatch(_gDateStringCollection[i]))
{
dayComboBox.Items.Add(day);
}
if (monthBasedOnYearRegex.IsMatch(_gDateStringCollection[i]))
{
if (!monthComboBox.Items.Contains(month))
{
monthComboBox.Items.Add(month);
}
}
}
var yearsInDatabase = databaseReader.RetrieveUniqueYearsList(databaseTracker.DatabaseConnectionString);
foreach (var year in yearsInDatabase)
{
yearComboBox.Items.Add(year);
}
if (dayComboBox.Items.Count >= 1 && yearComboBox.Items.Count >= 1 && monthComboBox.Items.Count >= 1)
{
monthComboBox.SelectedIndex = monthComboBox.Items.Count - 1;
dayComboBox.SelectedIndex = dayComboBox.Items.Count - 1;
yearComboBox.SelectedIndex = yearComboBox.Items.Count - 1;
monthComboBox.Enabled = true;
dayComboBox.Enabled = true;
yearComboBox.Enabled = true;
}
else
{
monthComboBox.Enabled = false;
dayComboBox.Enabled = false;
yearComboBox.Enabled = false;
}
monthComboBox.SelectedIndexChanged += UpdateDaysOfMonth;
dayComboBox.SelectedIndexChanged += UpdateDataGridViewInformation;
yearComboBox.SelectedIndexChanged += UpdateDaysOfMonthByYear;
DrawingControl.ResumeDrawing(secondaryLayOutPanel);
}
private void UpdateDaysOfMonth(object sender, EventArgs e)
{
if (yearComboBox.SelectedIndex == -1) return;
var year = yearComboBox.SelectedItem.ToString();
var month = monthComboBox.SelectedItem.ToString();
var dateParserPattern = new Regex("^" + month + @"\/\d{2}\/" + year);
dayComboBox.Items.Clear();
for (var i = 0; i < _gDateStringCollection.Count; i++)
{
if (dateParserPattern.IsMatch(_gDateStringCollection[i]))
{
var dateArray = _gDateStringCollection[i].Split('/');
var day = dateArray[1];
dayComboBox.Items.Add(day);
}
}
if (dayComboBox.Items.Count > 0)
{
dayComboBox.SelectedIndex = dayComboBox.Items.Count - 1;
}
}
/// <summary>
/// Fires when the Year combo box's index changes.
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void UpdateDaysOfMonthByYear(object sender, EventArgs e)
{
//Obligatory database retrieval call...
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
//First, grab the year and the month from their respective combo boxes.
var year = yearComboBox.SelectedItem.ToString();
var month = monthComboBox.SelectedItem.ToString();
//Since we can more or less be certain that nothing is null, clear the current date collection.
_gDateStringCollection.Clear();
var months = databaseReader.RetrieveUniqueMonthsList(year, databaseTracker.DatabaseConnectionString);
var mostRecentMonth = months.Max();
if (mostRecentMonth.Length == 1)
{
mostRecentMonth = "0" + mostRecentMonth;
}
var dateList = databaseReader.RetrieveDateListByYear(year, databaseTracker.DatabaseConnectionString);
foreach (var t in dateList)
{
_gDateStringCollection.Add(t.ToString("MM/dd/yyyy"));
}
//Clear the month and day combo boxes and unregister their event handlers.
dayComboBox.Items.Clear();
monthComboBox.Items.Clear();
monthComboBox.SelectedIndexChanged -= UpdateDaysOfMonth;
dayComboBox.SelectedIndexChanged -= UpdateDataGridViewInformation;
for (var i = 0; i < _gDateStringCollection.Count; i++)
{
var dateArray = _gDateStringCollection[i].Split('/');
month = dateArray[0];
//Declare the patterns to look for when enumerating the combo boxes.
var dayBasedOnMonthAndYeaRegex = new Regex(@"^(" + mostRecentMonth + @"\/\d{2}\/" + year + ")"); //Only allows days that are actually part of the month and year.
var day = dateArray[1];
if (dayBasedOnMonthAndYeaRegex.IsMatch(_gDateStringCollection[i]))
{
dayComboBox.Items.Add(day);
}
if (!monthComboBox.Items.Contains(month))
{
monthComboBox.Items.Add(month);
}
}
if (dayComboBox.Items.Count > 0)
{
dayComboBox.SelectedIndex = dayComboBox.Items.Count - 1;
}
if (monthComboBox.Items.Count > 0)
{
monthComboBox.SelectedIndex = monthComboBox.Items.Count - 1;
}
//Now re-register the event handlers
monthComboBox.SelectedIndexChanged += UpdateDaysOfMonth;
dayComboBox.SelectedIndexChanged += UpdateDataGridViewInformation;
BuildAndFillDataGridViews(monthComboBox.SelectedItem + "/" + dayComboBox.SelectedItem + "/" + year);
}
private void DELETE_Click(object sender, EventArgs e)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var databaseWriter = new DatabaseWriter(databaseTracker.DatabaseConnectionString);
var result = MessageBox.Show("Are you sure you wish to delete all records for the date selected date (" + monthComboBox.Text +"/" + dayComboBox.Text + "/" + yearComboBox.Text + ")?\nThis cannot be undone.", "Purge Selected Year", MessageBoxButtons.YesNo)
;
if (result == DialogResult.Yes)
{
var dateId =
databaseReader.RetrieveDateIdByDateString(monthComboBox.Text + "/" + dayComboBox.Text + "/" +
yearComboBox.Text, databaseTracker.DatabaseConnectionString);
var recordsAffected = databaseWriter.RemoveAllEntriesAndYearById(dateId);
if (recordsAffected > 0)
{
informationLabel.Text = "Successfully removed " + recordsAffected.ToString() +
" entries clearing all records of\n" + monthComboBox.Text + "/" + dayComboBox.Text +
"/" + yearComboBox.Text + " from the database.";
}
}
else
{
return;
}
FillDateSuggestionComboBoxes();
BuildAndFillDataGridViews();
}
}
}
File diff suppressed because it is too large Load Diff
+163
View File
@@ -0,0 +1,163 @@
namespace AdvertsingProfitControl
{
partial class FrmLogConsole
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmLogConsole));
this.mainTableLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.mainMenu = new System.Windows.Forms.MenuStrip();
this.logMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.saveLogMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.clearLogMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator();
this.closeLogMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.sourcesMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.logListView = new System.Windows.Forms.ListView();
this.mainTableLayoutPanel.SuspendLayout();
this.mainMenu.SuspendLayout();
this.SuspendLayout();
//
// mainTableLayoutPanel
//
this.mainTableLayoutPanel.ColumnCount = 1;
this.mainTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.mainTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 30F));
this.mainTableLayoutPanel.Controls.Add(this.mainMenu, 0, 0);
this.mainTableLayoutPanel.Controls.Add(this.logListView, 0, 1);
this.mainTableLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainTableLayoutPanel.Location = new System.Drawing.Point(0, 0);
this.mainTableLayoutPanel.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.mainTableLayoutPanel.Name = "mainTableLayoutPanel";
this.mainTableLayoutPanel.RowCount = 2;
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 38F));
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.mainTableLayoutPanel.Size = new System.Drawing.Size(876, 863);
this.mainTableLayoutPanel.TabIndex = 0;
//
// mainMenu
//
this.mainMenu.BackColor = System.Drawing.SystemColors.Control;
this.mainMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.logMainMenu,
this.sourcesMainMenu});
this.mainMenu.Location = new System.Drawing.Point(0, 0);
this.mainMenu.Name = "mainMenu";
this.mainMenu.Padding = new System.Windows.Forms.Padding(9, 3, 0, 3);
this.mainMenu.Size = new System.Drawing.Size(876, 35);
this.mainMenu.TabIndex = 0;
this.mainMenu.Text = "menuStrip1";
//
// logMainMenu
//
this.logMainMenu.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.saveLogMainMenu,
this.clearLogMainMenu,
this.toolStripSeparator1,
this.closeLogMainMenu});
this.logMainMenu.Name = "logMainMenu";
this.logMainMenu.Size = new System.Drawing.Size(54, 29);
this.logMainMenu.Text = "&Log";
//
// saveLogMainMenu
//
this.saveLogMainMenu.Name = "saveLogMainMenu";
this.saveLogMainMenu.Size = new System.Drawing.Size(133, 30);
this.saveLogMainMenu.Text = "S&ave...";
//
// clearLogMainMenu
//
this.clearLogMainMenu.Name = "clearLogMainMenu";
this.clearLogMainMenu.Size = new System.Drawing.Size(133, 30);
this.clearLogMainMenu.Text = "C&lear";
//
// toolStripSeparator1
//
this.toolStripSeparator1.Name = "toolStripSeparator1";
this.toolStripSeparator1.Size = new System.Drawing.Size(130, 6);
//
// closeLogMainMenu
//
this.closeLogMainMenu.Name = "closeLogMainMenu";
this.closeLogMainMenu.Size = new System.Drawing.Size(133, 30);
this.closeLogMainMenu.Text = "&Close";
//
// sourcesMainMenu
//
this.sourcesMainMenu.Name = "sourcesMainMenu";
this.sourcesMainMenu.Size = new System.Drawing.Size(86, 29);
this.sourcesMainMenu.Text = "&Sources";
//
// logListView
//
this.logListView.BackColor = System.Drawing.SystemColors.ControlLight;
this.logListView.Dock = System.Windows.Forms.DockStyle.Fill;
this.logListView.Font = new System.Drawing.Font("Times New Roman", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.logListView.FullRowSelect = true;
this.logListView.GridLines = true;
this.logListView.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.Nonclickable;
this.logListView.Location = new System.Drawing.Point(4, 43);
this.logListView.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.logListView.Name = "logListView";
this.logListView.Size = new System.Drawing.Size(868, 815);
this.logListView.TabIndex = 1;
this.logListView.UseCompatibleStateImageBehavior = false;
this.logListView.View = System.Windows.Forms.View.Details;
//
// LogConsole
//
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(876, 863);
this.Controls.Add(this.mainTableLayoutPanel);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.MainMenuStrip = this.mainMenu;
this.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.MaximizeBox = false;
this.Name = "LogConsole";
this.Text = "Program Log Form";
this.mainTableLayoutPanel.ResumeLayout(false);
this.mainTableLayoutPanel.PerformLayout();
this.mainMenu.ResumeLayout(false);
this.mainMenu.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.TableLayoutPanel mainTableLayoutPanel;
private System.Windows.Forms.MenuStrip mainMenu;
private System.Windows.Forms.ToolStripMenuItem logMainMenu;
private System.Windows.Forms.ToolStripMenuItem closeLogMainMenu;
private System.Windows.Forms.ListView logListView;
private System.Windows.Forms.ToolStripMenuItem sourcesMainMenu;
private System.Windows.Forms.ToolStripMenuItem saveLogMainMenu;
private System.Windows.Forms.ToolStripMenuItem clearLogMainMenu;
private System.Windows.Forms.ToolStripSeparator toolStripSeparator1;
}
}
+136
View File
@@ -0,0 +1,136 @@
using System;
using System.Drawing;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
public sealed partial class FrmLogConsole : Form
{
//Source code: https://hashfactor.wordpress.com/2009/03/31/c-winforms-create-a-single-instance-form/
private static bool _gIsShown;
public FrmLogConsole()
{
InitializeComponent();
logListView.Scrollable = true;
logListView.View = View.Details;
//Information for drawing header columns and sub-items in ListView:
//http://stackoverflow.com/questions/561798/how-do-i-align-text-for-a-single-subitem-in-a-listview-using-c
var header = new ColumnHeader
{
Text = @"Advertising Profit Control " + Application.ProductVersion + @" Debug Console",
Name = "LogConsoleHeader",
Width = logListView.Width
};
logListView.Columns.Add(header);
}
static FrmLogConsole()
{
GetStaticInstance.FormClosing += LogConsole_FormClosing;
//Set the maximum and minimum size of the form.
GetStaticInstance.MaximumSize = new Size(900, 900);
GetStaticInstance.MinimumSize = new Size(400, 400);
}
public new void Show()
{
if (_gIsShown)
{
base.Show();
}
else
{
base.Show();
_gIsShown = true;
}
}
public new void Hide()
{
if (!_gIsShown) return;
base.Hide();
_gIsShown = false;
}
public enum Level
{
Critical = 0,
Error = 1,
Warning = 2,
Info = 3,
Verbose = 4,
Debug = 5
};
public void WriteToLog(Level level, string message)
{
Color color;
switch (level)
{
case Level.Critical:
color = Color.White;
break;
case Level.Error:
color = Color.Red;
break;
case Level.Warning:
color = Color.Goldenrod;
break;
case Level.Info:
color = Color.Green;
break;
case Level.Verbose:
color = Color.Blue;
break;
case Level.Debug:
color = Color.Black;
break;
default:
color = Color.Black;
break;
}
var index = logListView.Items.Count;
try
{
message = $"{level}: {message}";
if (level != Level.Info)
{
GlobalClasses.WriteToLog(DateTime.Now + ": " + message + Environment.NewLine);
}
logListView.Items.Add(message);
logListView.Items[index].ForeColor = color;
}
catch (Exception e)
{
MessageBox.Show(e.Message);
}
switch (level)
{
case Level.Critical:
logListView.Items[index].BackColor = Color.Red;
break;
case Level.Error:
logListView.Items[index].ForeColor = Color.Maroon;
break;
default:
logListView.Items[index].BackColor = Color.WhiteSmoke;
break;
}
}
private static void LogConsole_FormClosing(object sender, FormClosingEventArgs e)
{
e.Cancel = true;
GetStaticInstance.Hide();
_gIsShown = false;
}
public static FrmLogConsole GetStaticInstance { get; } = new FrmLogConsole();
public bool IsVisable => _gIsShown;
}
}
File diff suppressed because it is too large Load Diff
+803
View File
@@ -0,0 +1,803 @@
namespace AdvertsingProfitControl
{
partial class FrmMain
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmMain));
this.mainTableLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.mainMenu = new System.Windows.Forms.MenuStrip();
this.fileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.exitFileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.recordsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.addRecordsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.modifyRecordMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.deleteRecordsMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.newFormTestToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolsMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.adSpecialKeyWordsToolsMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.manageItemsToolsMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.helpMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.showHideConsoleHelpMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.dbVersionHelpMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.commentMainTableLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.commentMainGroupBox = new System.Windows.Forms.GroupBox();
this.commentsTextBox = new System.Windows.Forms.TextBox();
this.profitAnalysisMainGroupBox = new System.Windows.Forms.GroupBox();
this.shrinkLinkLabel = new System.Windows.Forms.LinkLabel();
this.totalProfitReturnLabel = new System.Windows.Forms.Label();
this.totalProfitReturnFromRemaingLabel = new System.Windows.Forms.Label();
this.totalProfitFromAdItemsLabel = new System.Windows.Forms.Label();
this.remainingSalesLabel = new System.Windows.Forms.Label();
this.salesProducedLabel = new System.Windows.Forms.Label();
this.departmentSalesLabel = new System.Windows.Forms.Label();
this.grossProfitGroupBox = new System.Windows.Forms.GroupBox();
this.grossProfitEstimatedWeeklyDeptmartmentExpenseLabel = new System.Windows.Forms.Label();
this.grossProfitDollarGrossProfitLabel = new System.Windows.Forms.Label();
this.perfectGrossProfitLabel = new System.Windows.Forms.Label();
this.grossProfitTotalSales = new System.Windows.Forms.Label();
this.grossProfitLessCostOfSales = new System.Windows.Forms.Label();
this.taxableGroupBox = new System.Windows.Forms.GroupBox();
this.usePreRenderedFilesCheckbox = new System.Windows.Forms.CheckBox();
this.dateSelectorPanel = new System.Windows.Forms.Panel();
this.printPreviewButton = new System.Windows.Forms.Button();
this.yearComboBox = new System.Windows.Forms.ComboBox();
this.dayComboBox = new System.Windows.Forms.ComboBox();
this.monthComboBox = new System.Windows.Forms.ComboBox();
this.dateSelectLabel = new System.Windows.Forms.Label();
this.mainViewTabControl = new System.Windows.Forms.TabControl();
this.projectionTab = new System.Windows.Forms.TabPage();
this.projectedSalesMainDataGrid = new System.Windows.Forms.DataGridView();
this.inventoryTabPage = new System.Windows.Forms.TabPage();
this.inventoryDataGridView = new System.Windows.Forms.DataGridView();
this.actualSalesTab = new System.Windows.Forms.TabPage();
this.actualSalesMainLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.actualSalesMainDataGidView = new System.Windows.Forms.DataGridView();
this.suppliersTabPage = new System.Windows.Forms.TabPage();
this.suppliersDataGridView = new System.Windows.Forms.DataGridView();
this.WeeklySalesTabPage = new System.Windows.Forms.TabPage();
this.weeklySalesDataGridView = new System.Windows.Forms.DataGridView();
this.mainTableLayoutPanel.SuspendLayout();
this.mainMenu.SuspendLayout();
this.commentMainTableLayoutPanel.SuspendLayout();
this.commentMainGroupBox.SuspendLayout();
this.profitAnalysisMainGroupBox.SuspendLayout();
this.grossProfitGroupBox.SuspendLayout();
this.taxableGroupBox.SuspendLayout();
this.dateSelectorPanel.SuspendLayout();
this.mainViewTabControl.SuspendLayout();
this.projectionTab.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.projectedSalesMainDataGrid)).BeginInit();
this.inventoryTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.inventoryDataGridView)).BeginInit();
this.actualSalesTab.SuspendLayout();
this.actualSalesMainLayoutPanel.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.actualSalesMainDataGidView)).BeginInit();
this.suppliersTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.suppliersDataGridView)).BeginInit();
this.WeeklySalesTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.weeklySalesDataGridView)).BeginInit();
this.SuspendLayout();
//
// mainTableLayoutPanel
//
this.mainTableLayoutPanel.ColumnCount = 1;
this.mainTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.mainTableLayoutPanel.Controls.Add(this.mainMenu, 0, 0);
this.mainTableLayoutPanel.Controls.Add(this.commentMainTableLayoutPanel, 0, 2);
this.mainTableLayoutPanel.Controls.Add(this.mainViewTabControl, 0, 1);
this.mainTableLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainTableLayoutPanel.Location = new System.Drawing.Point(0, 0);
this.mainTableLayoutPanel.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.mainTableLayoutPanel.Name = "mainTableLayoutPanel";
this.mainTableLayoutPanel.RowCount = 3;
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 41F));
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 65F));
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 35F));
this.mainTableLayoutPanel.Size = new System.Drawing.Size(1734, 892);
this.mainTableLayoutPanel.TabIndex = 0;
//
// mainMenu
//
this.mainMenu.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainMenu.ImageScalingSize = new System.Drawing.Size(24, 24);
this.mainMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.fileMainMenu,
this.recordsToolStripMenuItem,
this.toolsMainMenu,
this.helpMainMenu});
this.mainMenu.Location = new System.Drawing.Point(0, 0);
this.mainMenu.Name = "mainMenu";
this.mainMenu.Padding = new System.Windows.Forms.Padding(10, 3, 0, 3);
this.mainMenu.Size = new System.Drawing.Size(1734, 41);
this.mainMenu.TabIndex = 1;
this.mainMenu.Text = "menuStrip1";
//
// fileMainMenu
//
this.fileMainMenu.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.exitFileMainMenu});
this.fileMainMenu.Name = "fileMainMenu";
this.fileMainMenu.Size = new System.Drawing.Size(56, 35);
this.fileMainMenu.Text = "&File";
//
// exitFileMainMenu
//
this.exitFileMainMenu.Name = "exitFileMainMenu";
this.exitFileMainMenu.Size = new System.Drawing.Size(138, 34);
this.exitFileMainMenu.Text = "E&xit";
//
// recordsToolStripMenuItem
//
this.recordsToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.addRecordsToolStripMenuItem,
this.modifyRecordMainMenu,
this.deleteRecordsMainMenu,
this.newFormTestToolStripMenuItem});
this.recordsToolStripMenuItem.Name = "recordsToolStripMenuItem";
this.recordsToolStripMenuItem.Size = new System.Drawing.Size(98, 35);
this.recordsToolStripMenuItem.Text = "&Records";
//
// addRecordsToolStripMenuItem
//
this.addRecordsToolStripMenuItem.Name = "addRecordsToolStripMenuItem";
this.addRecordsToolStripMenuItem.Size = new System.Drawing.Size(323, 34);
this.addRecordsToolStripMenuItem.Text = "&Add New Record";
this.addRecordsToolStripMenuItem.Click += new System.EventHandler(this.addRecordToolStripMenuItem_Click);
//
// modifyRecordMainMenu
//
this.modifyRecordMainMenu.Name = "modifyRecordMainMenu";
this.modifyRecordMainMenu.Size = new System.Drawing.Size(323, 34);
this.modifyRecordMainMenu.Text = "&Modify Existing Record ";
this.modifyRecordMainMenu.Click += new System.EventHandler(this.modifyRecordMainMenu_Click);
//
// deleteRecordsMainMenu
//
this.deleteRecordsMainMenu.Name = "deleteRecordsMainMenu";
this.deleteRecordsMainMenu.Size = new System.Drawing.Size(323, 34);
this.deleteRecordsMainMenu.Text = "&Delete Existing record";
this.deleteRecordsMainMenu.Click += new System.EventHandler(this.deleteRecordsMainMenu_Click);
//
// newFormTestToolStripMenuItem
//
this.newFormTestToolStripMenuItem.Name = "newFormTestToolStripMenuItem";
this.newFormTestToolStripMenuItem.Size = new System.Drawing.Size(323, 34);
this.newFormTestToolStripMenuItem.Text = "&New Form Test";
this.newFormTestToolStripMenuItem.Click += new System.EventHandler(this.newFormTestToolStripMenuItem_Click);
//
// toolsMainMenu
//
this.toolsMainMenu.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.adSpecialKeyWordsToolsMainMenu,
this.manageItemsToolsMainMenu});
this.toolsMainMenu.Name = "toolsMainMenu";
this.toolsMainMenu.Size = new System.Drawing.Size(72, 35);
this.toolsMainMenu.Text = "&Tools";
//
// adSpecialKeyWordsToolsMainMenu
//
this.adSpecialKeyWordsToolsMainMenu.Name = "adSpecialKeyWordsToolsMainMenu";
this.adSpecialKeyWordsToolsMainMenu.Size = new System.Drawing.Size(282, 34);
this.adSpecialKeyWordsToolsMainMenu.Text = "&Register Ad Special";
this.adSpecialKeyWordsToolsMainMenu.Click += new System.EventHandler(this.adSpecialKeyWordsToolsMainMenu_Click);
//
// manageItemsToolsMainMenu
//
this.manageItemsToolsMainMenu.Name = "manageItemsToolsMainMenu";
this.manageItemsToolsMainMenu.Size = new System.Drawing.Size(282, 34);
this.manageItemsToolsMainMenu.Text = "&Manage Ad Items";
this.manageItemsToolsMainMenu.Click += new System.EventHandler(this.manageItemsToolsMainMenu_Click);
//
// helpMainMenu
//
this.helpMainMenu.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.showHideConsoleHelpMainMenu,
this.dbVersionHelpMainMenu});
this.helpMainMenu.Name = "helpMainMenu";
this.helpMainMenu.Size = new System.Drawing.Size(68, 35);
this.helpMainMenu.Text = "&Help";
//
// showHideConsoleHelpMainMenu
//
this.showHideConsoleHelpMainMenu.Name = "showHideConsoleHelpMainMenu";
this.showHideConsoleHelpMainMenu.Size = new System.Drawing.Size(304, 34);
this.showHideConsoleHelpMainMenu.Text = "&Show/Hide Console";
this.showHideConsoleHelpMainMenu.Click += new System.EventHandler(this.showHideConsoleHelpMainMenu_Click);
//
// dbVersionHelpMainMenu
//
this.dbVersionHelpMainMenu.Name = "dbVersionHelpMainMenu";
this.dbVersionHelpMainMenu.Size = new System.Drawing.Size(304, 34);
this.dbVersionHelpMainMenu.Text = "Get &Database Version";
this.dbVersionHelpMainMenu.Click += new System.EventHandler(this.dbVersionHelpMainMenu_Click);
//
// commentMainTableLayoutPanel
//
this.commentMainTableLayoutPanel.ColumnCount = 4;
this.commentMainTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
this.commentMainTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 28F));
this.commentMainTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 26F));
this.commentMainTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 26F));
this.commentMainTableLayoutPanel.Controls.Add(this.commentMainGroupBox, 0, 0);
this.commentMainTableLayoutPanel.Controls.Add(this.profitAnalysisMainGroupBox, 1, 0);
this.commentMainTableLayoutPanel.Controls.Add(this.grossProfitGroupBox, 2, 0);
this.commentMainTableLayoutPanel.Controls.Add(this.taxableGroupBox, 3, 0);
this.commentMainTableLayoutPanel.Controls.Add(this.dateSelectorPanel, 2, 1);
this.commentMainTableLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentMainTableLayoutPanel.Location = new System.Drawing.Point(5, 600);
this.commentMainTableLayoutPanel.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.commentMainTableLayoutPanel.Name = "commentMainTableLayoutPanel";
this.commentMainTableLayoutPanel.RowCount = 2;
this.commentMainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 80F));
this.commentMainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
this.commentMainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 23F));
this.commentMainTableLayoutPanel.Size = new System.Drawing.Size(1724, 286);
this.commentMainTableLayoutPanel.TabIndex = 2;
//
// commentMainGroupBox
//
this.commentMainGroupBox.Controls.Add(this.commentsTextBox);
this.commentMainGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentMainGroupBox.Location = new System.Drawing.Point(5, 6);
this.commentMainGroupBox.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.commentMainGroupBox.Name = "commentMainGroupBox";
this.commentMainGroupBox.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.commentMainTableLayoutPanel.SetRowSpan(this.commentMainGroupBox, 2);
this.commentMainGroupBox.Size = new System.Drawing.Size(334, 274);
this.commentMainGroupBox.TabIndex = 0;
this.commentMainGroupBox.TabStop = false;
this.commentMainGroupBox.Text = "Comments";
//
// commentsTextBox
//
this.commentsTextBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentsTextBox.Enabled = false;
this.commentsTextBox.Location = new System.Drawing.Point(5, 28);
this.commentsTextBox.Multiline = true;
this.commentsTextBox.Name = "commentsTextBox";
this.commentsTextBox.ReadOnly = true;
this.commentsTextBox.Size = new System.Drawing.Size(324, 240);
this.commentsTextBox.TabIndex = 0;
//
// profitAnalysisMainGroupBox
//
this.profitAnalysisMainGroupBox.Controls.Add(this.shrinkLinkLabel);
this.profitAnalysisMainGroupBox.Controls.Add(this.totalProfitReturnLabel);
this.profitAnalysisMainGroupBox.Controls.Add(this.totalProfitReturnFromRemaingLabel);
this.profitAnalysisMainGroupBox.Controls.Add(this.totalProfitFromAdItemsLabel);
this.profitAnalysisMainGroupBox.Controls.Add(this.remainingSalesLabel);
this.profitAnalysisMainGroupBox.Controls.Add(this.salesProducedLabel);
this.profitAnalysisMainGroupBox.Controls.Add(this.departmentSalesLabel);
this.profitAnalysisMainGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.profitAnalysisMainGroupBox.Location = new System.Drawing.Point(349, 6);
this.profitAnalysisMainGroupBox.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.profitAnalysisMainGroupBox.Name = "profitAnalysisMainGroupBox";
this.profitAnalysisMainGroupBox.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.commentMainTableLayoutPanel.SetRowSpan(this.profitAnalysisMainGroupBox, 2);
this.profitAnalysisMainGroupBox.Size = new System.Drawing.Size(472, 274);
this.profitAnalysisMainGroupBox.TabIndex = 1;
this.profitAnalysisMainGroupBox.TabStop = false;
this.profitAnalysisMainGroupBox.Text = "Profit Analysis";
//
// shrinkLinkLabel
//
this.shrinkLinkLabel.AutoSize = true;
this.shrinkLinkLabel.LinkArea = new System.Windows.Forms.LinkArea(20, 6);
this.shrinkLinkLabel.LinkBehavior = System.Windows.Forms.LinkBehavior.HoverUnderline;
this.shrinkLinkLabel.LinkColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(192)))));
this.shrinkLinkLabel.Location = new System.Drawing.Point(0, 37);
this.shrinkLinkLabel.Name = "shrinkLinkLabel";
this.shrinkLinkLabel.Size = new System.Drawing.Size(272, 27);
this.shrinkLinkLabel.TabIndex = 6;
this.shrinkLinkLabel.TabStop = true;
this.shrinkLinkLabel.Text = "Assuming 30% Shrink Change";
this.shrinkLinkLabel.UseCompatibleTextRendering = true;
//
// totalProfitReturnLabel
//
this.totalProfitReturnLabel.AutoSize = true;
this.totalProfitReturnLabel.Location = new System.Drawing.Point(0, 251);
this.totalProfitReturnLabel.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
this.totalProfitReturnLabel.Name = "totalProfitReturnLabel";
this.totalProfitReturnLabel.Size = new System.Drawing.Size(178, 25);
this.totalProfitReturnLabel.TabIndex = 5;
this.totalProfitReturnLabel.Text = "Total Profit Return: ";
//
// totalProfitReturnFromRemaingLabel
//
this.totalProfitReturnFromRemaingLabel.AutoSize = true;
this.totalProfitReturnFromRemaingLabel.Location = new System.Drawing.Point(0, 216);
this.totalProfitReturnFromRemaingLabel.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
this.totalProfitReturnFromRemaingLabel.Name = "totalProfitReturnFromRemaingLabel";
this.totalProfitReturnFromRemaingLabel.Size = new System.Drawing.Size(380, 25);
this.totalProfitReturnFromRemaingLabel.TabIndex = 4;
this.totalProfitReturnFromRemaingLabel.Text = "Total Profit Return From Remaining Sales: ";
//
// totalProfitFromAdItemsLabel
//
this.totalProfitFromAdItemsLabel.AutoSize = true;
this.totalProfitFromAdItemsLabel.Location = new System.Drawing.Point(0, 180);
this.totalProfitFromAdItemsLabel.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
this.totalProfitFromAdItemsLabel.Name = "totalProfitFromAdItemsLabel";
this.totalProfitFromAdItemsLabel.Size = new System.Drawing.Size(342, 25);
this.totalProfitFromAdItemsLabel.TabIndex = 3;
this.totalProfitFromAdItemsLabel.Text = "Total Profit Return From Ad Items (B): ";
//
// remainingSalesLabel
//
this.remainingSalesLabel.AutoSize = true;
this.remainingSalesLabel.Location = new System.Drawing.Point(0, 143);
this.remainingSalesLabel.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
this.remainingSalesLabel.Name = "remainingSalesLabel";
this.remainingSalesLabel.Size = new System.Drawing.Size(170, 25);
this.remainingSalesLabel.TabIndex = 2;
this.remainingSalesLabel.Text = "Remaining Sales: ";
//
// salesProducedLabel
//
this.salesProducedLabel.AutoSize = true;
this.salesProducedLabel.Location = new System.Drawing.Point(0, 107);
this.salesProducedLabel.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
this.salesProducedLabel.Name = "salesProducedLabel";
this.salesProducedLabel.Size = new System.Drawing.Size(300, 25);
this.salesProducedLabel.TabIndex = 1;
this.salesProducedLabel.Text = "Sales Produced By Ad Items (A):";
//
// departmentSalesLabel
//
this.departmentSalesLabel.AutoSize = true;
this.departmentSalesLabel.Location = new System.Drawing.Point(0, 72);
this.departmentSalesLabel.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
this.departmentSalesLabel.Name = "departmentSalesLabel";
this.departmentSalesLabel.Size = new System.Drawing.Size(179, 25);
this.departmentSalesLabel.TabIndex = 0;
this.departmentSalesLabel.Text = "Department Sales: ";
//
// grossProfitGroupBox
//
this.grossProfitGroupBox.Controls.Add(this.grossProfitEstimatedWeeklyDeptmartmentExpenseLabel);
this.grossProfitGroupBox.Controls.Add(this.grossProfitDollarGrossProfitLabel);
this.grossProfitGroupBox.Controls.Add(this.perfectGrossProfitLabel);
this.grossProfitGroupBox.Controls.Add(this.grossProfitTotalSales);
this.grossProfitGroupBox.Controls.Add(this.grossProfitLessCostOfSales);
this.grossProfitGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.grossProfitGroupBox.Location = new System.Drawing.Point(831, 6);
this.grossProfitGroupBox.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.grossProfitGroupBox.Name = "grossProfitGroupBox";
this.grossProfitGroupBox.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.grossProfitGroupBox.Size = new System.Drawing.Size(438, 216);
this.grossProfitGroupBox.TabIndex = 2;
this.grossProfitGroupBox.TabStop = false;
this.grossProfitGroupBox.Text = "Gross Profit";
//
// grossProfitEstimatedWeeklyDeptmartmentExpenseLabel
//
this.grossProfitEstimatedWeeklyDeptmartmentExpenseLabel.AutoSize = true;
this.grossProfitEstimatedWeeklyDeptmartmentExpenseLabel.Location = new System.Drawing.Point(8, 177);
this.grossProfitEstimatedWeeklyDeptmartmentExpenseLabel.Name = "grossProfitEstimatedWeeklyDeptmartmentExpenseLabel";
this.grossProfitEstimatedWeeklyDeptmartmentExpenseLabel.Size = new System.Drawing.Size(368, 25);
this.grossProfitEstimatedWeeklyDeptmartmentExpenseLabel.TabIndex = 4;
this.grossProfitEstimatedWeeklyDeptmartmentExpenseLabel.Text = "Estimated Weekly Department Expense: ";
//
// grossProfitDollarGrossProfitLabel
//
this.grossProfitDollarGrossProfitLabel.AutoSize = true;
this.grossProfitDollarGrossProfitLabel.Location = new System.Drawing.Point(8, 107);
this.grossProfitDollarGrossProfitLabel.Name = "grossProfitDollarGrossProfitLabel";
this.grossProfitDollarGrossProfitLabel.Size = new System.Drawing.Size(179, 25);
this.grossProfitDollarGrossProfitLabel.TabIndex = 2;
this.grossProfitDollarGrossProfitLabel.Text = "Dollar Gross Profit: ";
//
// perfectGrossProfitLabel
//
this.perfectGrossProfitLabel.AutoSize = true;
this.perfectGrossProfitLabel.Location = new System.Drawing.Point(8, 142);
this.perfectGrossProfitLabel.Name = "perfectGrossProfitLabel";
this.perfectGrossProfitLabel.Size = new System.Drawing.Size(196, 25);
this.perfectGrossProfitLabel.TabIndex = 3;
this.perfectGrossProfitLabel.Text = "Percent Gross Profit: ";
//
// grossProfitTotalSales
//
this.grossProfitTotalSales.AutoSize = true;
this.grossProfitTotalSales.Location = new System.Drawing.Point(8, 37);
this.grossProfitTotalSales.Name = "grossProfitTotalSales";
this.grossProfitTotalSales.Size = new System.Drawing.Size(122, 25);
this.grossProfitTotalSales.TabIndex = 0;
this.grossProfitTotalSales.Text = "Total Sales: ";
//
// grossProfitLessCostOfSales
//
this.grossProfitLessCostOfSales.AutoSize = true;
this.grossProfitLessCostOfSales.Location = new System.Drawing.Point(8, 72);
this.grossProfitLessCostOfSales.Name = "grossProfitLessCostOfSales";
this.grossProfitLessCostOfSales.Size = new System.Drawing.Size(187, 25);
this.grossProfitLessCostOfSales.TabIndex = 1;
this.grossProfitLessCostOfSales.Text = "Less Cost of Sales: ";
//
// taxableGroupBox
//
this.taxableGroupBox.Controls.Add(this.usePreRenderedFilesCheckbox);
this.taxableGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.taxableGroupBox.Location = new System.Drawing.Point(1277, 3);
this.taxableGroupBox.Name = "taxableGroupBox";
this.taxableGroupBox.Size = new System.Drawing.Size(444, 222);
this.taxableGroupBox.TabIndex = 3;
this.taxableGroupBox.TabStop = false;
this.taxableGroupBox.Text = "Taxable";
//
// usePreRenderedFilesCheckbox
//
this.usePreRenderedFilesCheckbox.AutoSize = true;
this.usePreRenderedFilesCheckbox.Location = new System.Drawing.Point(206, 191);
this.usePreRenderedFilesCheckbox.Name = "usePreRenderedFilesCheckbox";
this.usePreRenderedFilesCheckbox.Size = new System.Drawing.Size(239, 29);
this.usePreRenderedFilesCheckbox.TabIndex = 5;
this.usePreRenderedFilesCheckbox.Text = "Use Pre-rendered Files";
this.usePreRenderedFilesCheckbox.UseVisualStyleBackColor = true;
//
// dateSelectorPanel
//
this.commentMainTableLayoutPanel.SetColumnSpan(this.dateSelectorPanel, 2);
this.dateSelectorPanel.Controls.Add(this.printPreviewButton);
this.dateSelectorPanel.Controls.Add(this.yearComboBox);
this.dateSelectorPanel.Controls.Add(this.dayComboBox);
this.dateSelectorPanel.Controls.Add(this.monthComboBox);
this.dateSelectorPanel.Controls.Add(this.dateSelectLabel);
this.dateSelectorPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.dateSelectorPanel.Location = new System.Drawing.Point(829, 231);
this.dateSelectorPanel.Name = "dateSelectorPanel";
this.dateSelectorPanel.Size = new System.Drawing.Size(892, 52);
this.dateSelectorPanel.TabIndex = 4;
//
// printPreviewButton
//
this.printPreviewButton.Location = new System.Drawing.Point(744, 0);
this.printPreviewButton.Name = "printPreviewButton";
this.printPreviewButton.Size = new System.Drawing.Size(138, 49);
this.printPreviewButton.TabIndex = 4;
this.printPreviewButton.Text = "Print Preview";
this.printPreviewButton.UseVisualStyleBackColor = true;
this.printPreviewButton.Click += new System.EventHandler(this.DisplayPrintPreview);
//
// yearComboBox
//
this.yearComboBox.FormattingEnabled = true;
this.yearComboBox.Location = new System.Drawing.Point(446, 13);
this.yearComboBox.Name = "yearComboBox";
this.yearComboBox.Size = new System.Drawing.Size(111, 32);
this.yearComboBox.Sorted = true;
this.yearComboBox.TabIndex = 3;
//
// dayComboBox
//
this.dayComboBox.FormattingEnabled = true;
this.dayComboBox.Location = new System.Drawing.Point(327, 13);
this.dayComboBox.Name = "dayComboBox";
this.dayComboBox.Size = new System.Drawing.Size(111, 32);
this.dayComboBox.Sorted = true;
this.dayComboBox.TabIndex = 2;
//
// monthComboBox
//
this.monthComboBox.FormattingEnabled = true;
this.monthComboBox.Location = new System.Drawing.Point(208, 13);
this.monthComboBox.Name = "monthComboBox";
this.monthComboBox.Size = new System.Drawing.Size(111, 32);
this.monthComboBox.Sorted = true;
this.monthComboBox.TabIndex = 1;
//
// dateSelectLabel
//
this.dateSelectLabel.AutoSize = true;
this.dateSelectLabel.Location = new System.Drawing.Point(7, 14);
this.dateSelectLabel.Name = "dateSelectLabel";
this.dateSelectLabel.Size = new System.Drawing.Size(204, 25);
this.dateSelectLabel.TabIndex = 0;
this.dateSelectLabel.Text = "Select a Date to View:";
//
// mainViewTabControl
//
this.mainViewTabControl.Controls.Add(this.projectionTab);
this.mainViewTabControl.Controls.Add(this.inventoryTabPage);
this.mainViewTabControl.Controls.Add(this.actualSalesTab);
this.mainViewTabControl.Controls.Add(this.suppliersTabPage);
this.mainViewTabControl.Controls.Add(this.WeeklySalesTabPage);
this.mainViewTabControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainViewTabControl.Location = new System.Drawing.Point(5, 47);
this.mainViewTabControl.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.mainViewTabControl.Name = "mainViewTabControl";
this.mainViewTabControl.SelectedIndex = 0;
this.mainViewTabControl.Size = new System.Drawing.Size(1724, 541);
this.mainViewTabControl.TabIndex = 3;
//
// projectionTab
//
this.projectionTab.Controls.Add(this.projectedSalesMainDataGrid);
this.projectionTab.Location = new System.Drawing.Point(4, 33);
this.projectionTab.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.projectionTab.Name = "projectionTab";
this.projectionTab.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.projectionTab.Size = new System.Drawing.Size(1716, 504);
this.projectionTab.TabIndex = 0;
this.projectionTab.Text = "Projections";
this.projectionTab.UseVisualStyleBackColor = true;
//
// projectedSalesMainDataGrid
//
this.projectedSalesMainDataGrid.AllowUserToAddRows = false;
this.projectedSalesMainDataGrid.AllowUserToDeleteRows = false;
this.projectedSalesMainDataGrid.AllowUserToResizeRows = false;
this.projectedSalesMainDataGrid.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.projectedSalesMainDataGrid.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.projectedSalesMainDataGrid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.projectedSalesMainDataGrid.Dock = System.Windows.Forms.DockStyle.Fill;
this.projectedSalesMainDataGrid.EditMode = System.Windows.Forms.DataGridViewEditMode.EditOnKeystroke;
this.projectedSalesMainDataGrid.Location = new System.Drawing.Point(5, 6);
this.projectedSalesMainDataGrid.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.projectedSalesMainDataGrid.Name = "projectedSalesMainDataGrid";
this.projectedSalesMainDataGrid.ReadOnly = true;
this.projectedSalesMainDataGrid.RowHeadersVisible = false;
this.projectedSalesMainDataGrid.ShowCellErrors = false;
this.projectedSalesMainDataGrid.ShowRowErrors = false;
this.projectedSalesMainDataGrid.Size = new System.Drawing.Size(1706, 492);
this.projectedSalesMainDataGrid.TabIndex = 0;
//
// inventoryTabPage
//
this.inventoryTabPage.Controls.Add(this.inventoryDataGridView);
this.inventoryTabPage.Location = new System.Drawing.Point(4, 33);
this.inventoryTabPage.Name = "inventoryTabPage";
this.inventoryTabPage.Padding = new System.Windows.Forms.Padding(3);
this.inventoryTabPage.Size = new System.Drawing.Size(1716, 504);
this.inventoryTabPage.TabIndex = 4;
this.inventoryTabPage.Text = "Inventory";
this.inventoryTabPage.UseVisualStyleBackColor = true;
//
// inventoryDataGridView
//
this.inventoryDataGridView.AllowUserToAddRows = false;
this.inventoryDataGridView.AllowUserToDeleteRows = false;
this.inventoryDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.inventoryDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.inventoryDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.inventoryDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.inventoryDataGridView.Location = new System.Drawing.Point(3, 3);
this.inventoryDataGridView.Name = "inventoryDataGridView";
this.inventoryDataGridView.ReadOnly = true;
this.inventoryDataGridView.RowHeadersVisible = false;
this.inventoryDataGridView.RowTemplate.Height = 28;
this.inventoryDataGridView.ShowRowErrors = false;
this.inventoryDataGridView.Size = new System.Drawing.Size(1710, 498);
this.inventoryDataGridView.TabIndex = 0;
//
// actualSalesTab
//
this.actualSalesTab.Controls.Add(this.actualSalesMainLayoutPanel);
this.actualSalesTab.Location = new System.Drawing.Point(4, 33);
this.actualSalesTab.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.actualSalesTab.Name = "actualSalesTab";
this.actualSalesTab.Size = new System.Drawing.Size(1716, 504);
this.actualSalesTab.TabIndex = 2;
this.actualSalesTab.Text = "Actual Sales";
this.actualSalesTab.UseVisualStyleBackColor = true;
//
// actualSalesMainLayoutPanel
//
this.actualSalesMainLayoutPanel.ColumnCount = 1;
this.actualSalesMainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.actualSalesMainLayoutPanel.Controls.Add(this.actualSalesMainDataGidView, 0, 0);
this.actualSalesMainLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.actualSalesMainLayoutPanel.Location = new System.Drawing.Point(0, 0);
this.actualSalesMainLayoutPanel.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.actualSalesMainLayoutPanel.Name = "actualSalesMainLayoutPanel";
this.actualSalesMainLayoutPanel.RowCount = 1;
this.actualSalesMainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.actualSalesMainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 504F));
this.actualSalesMainLayoutPanel.Size = new System.Drawing.Size(1716, 504);
this.actualSalesMainLayoutPanel.TabIndex = 0;
//
// actualSalesMainDataGidView
//
this.actualSalesMainDataGidView.AllowUserToAddRows = false;
this.actualSalesMainDataGidView.AllowUserToDeleteRows = false;
this.actualSalesMainDataGidView.AllowUserToResizeRows = false;
this.actualSalesMainDataGidView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.actualSalesMainDataGidView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.actualSalesMainDataGidView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.actualSalesMainDataGidView.Dock = System.Windows.Forms.DockStyle.Fill;
this.actualSalesMainDataGidView.EditMode = System.Windows.Forms.DataGridViewEditMode.EditOnKeystroke;
this.actualSalesMainDataGidView.Location = new System.Drawing.Point(5, 6);
this.actualSalesMainDataGidView.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.actualSalesMainDataGidView.Name = "actualSalesMainDataGidView";
this.actualSalesMainDataGidView.ReadOnly = true;
this.actualSalesMainDataGidView.RowHeadersVisible = false;
this.actualSalesMainDataGidView.ShowCellErrors = false;
this.actualSalesMainDataGidView.ShowRowErrors = false;
this.actualSalesMainDataGidView.Size = new System.Drawing.Size(1706, 492);
this.actualSalesMainDataGidView.TabIndex = 1;
//
// suppliersTabPage
//
this.suppliersTabPage.Controls.Add(this.suppliersDataGridView);
this.suppliersTabPage.Location = new System.Drawing.Point(4, 33);
this.suppliersTabPage.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.suppliersTabPage.Name = "suppliersTabPage";
this.suppliersTabPage.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.suppliersTabPage.Size = new System.Drawing.Size(1716, 504);
this.suppliersTabPage.TabIndex = 1;
this.suppliersTabPage.Text = "Suppliers";
this.suppliersTabPage.UseVisualStyleBackColor = true;
//
// suppliersDataGridView
//
this.suppliersDataGridView.AllowUserToAddRows = false;
this.suppliersDataGridView.AllowUserToDeleteRows = false;
this.suppliersDataGridView.AllowUserToResizeRows = false;
this.suppliersDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.suppliersDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.suppliersDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.suppliersDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.suppliersDataGridView.EditMode = System.Windows.Forms.DataGridViewEditMode.EditOnKeystroke;
this.suppliersDataGridView.Location = new System.Drawing.Point(5, 6);
this.suppliersDataGridView.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.suppliersDataGridView.Name = "suppliersDataGridView";
this.suppliersDataGridView.ReadOnly = true;
this.suppliersDataGridView.RowHeadersVisible = false;
this.suppliersDataGridView.Size = new System.Drawing.Size(1706, 492);
this.suppliersDataGridView.TabIndex = 0;
//
// WeeklySalesTabPage
//
this.WeeklySalesTabPage.Controls.Add(this.weeklySalesDataGridView);
this.WeeklySalesTabPage.Location = new System.Drawing.Point(4, 33);
this.WeeklySalesTabPage.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.WeeklySalesTabPage.Name = "WeeklySalesTabPage";
this.WeeklySalesTabPage.Padding = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.WeeklySalesTabPage.Size = new System.Drawing.Size(1716, 504);
this.WeeklySalesTabPage.TabIndex = 3;
this.WeeklySalesTabPage.Text = "Weekly Sales";
this.WeeklySalesTabPage.UseVisualStyleBackColor = true;
//
// weeklySalesDataGridView
//
this.weeklySalesDataGridView.AllowUserToAddRows = false;
this.weeklySalesDataGridView.AllowUserToDeleteRows = false;
this.weeklySalesDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.weeklySalesDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.weeklySalesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.weeklySalesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.weeklySalesDataGridView.EditMode = System.Windows.Forms.DataGridViewEditMode.EditOnKeystroke;
this.weeklySalesDataGridView.Location = new System.Drawing.Point(5, 6);
this.weeklySalesDataGridView.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.weeklySalesDataGridView.Name = "weeklySalesDataGridView";
this.weeklySalesDataGridView.ReadOnly = true;
this.weeklySalesDataGridView.RowHeadersVisible = false;
this.weeklySalesDataGridView.Size = new System.Drawing.Size(1706, 492);
this.weeklySalesDataGridView.TabIndex = 0;
//
// FrmMain
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(1734, 892);
this.Controls.Add(this.mainTableLayoutPanel);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
this.MaximizeBox = false;
this.Name = "FrmMain";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "Advertising Profit Control";
this.Load += new System.EventHandler(this.frmMain_Load);
this.mainTableLayoutPanel.ResumeLayout(false);
this.mainTableLayoutPanel.PerformLayout();
this.mainMenu.ResumeLayout(false);
this.mainMenu.PerformLayout();
this.commentMainTableLayoutPanel.ResumeLayout(false);
this.commentMainGroupBox.ResumeLayout(false);
this.commentMainGroupBox.PerformLayout();
this.profitAnalysisMainGroupBox.ResumeLayout(false);
this.profitAnalysisMainGroupBox.PerformLayout();
this.grossProfitGroupBox.ResumeLayout(false);
this.grossProfitGroupBox.PerformLayout();
this.taxableGroupBox.ResumeLayout(false);
this.taxableGroupBox.PerformLayout();
this.dateSelectorPanel.ResumeLayout(false);
this.dateSelectorPanel.PerformLayout();
this.mainViewTabControl.ResumeLayout(false);
this.projectionTab.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.projectedSalesMainDataGrid)).EndInit();
this.inventoryTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.inventoryDataGridView)).EndInit();
this.actualSalesTab.ResumeLayout(false);
this.actualSalesMainLayoutPanel.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.actualSalesMainDataGidView)).EndInit();
this.suppliersTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.suppliersDataGridView)).EndInit();
this.WeeklySalesTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.weeklySalesDataGridView)).EndInit();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.TableLayoutPanel mainTableLayoutPanel;
private System.Windows.Forms.MenuStrip mainMenu;
private System.Windows.Forms.ToolStripMenuItem fileMainMenu;
private System.Windows.Forms.TableLayoutPanel commentMainTableLayoutPanel;
private System.Windows.Forms.GroupBox commentMainGroupBox;
private System.Windows.Forms.GroupBox profitAnalysisMainGroupBox;
private System.Windows.Forms.GroupBox grossProfitGroupBox;
private System.Windows.Forms.ToolStripMenuItem exitFileMainMenu;
private System.Windows.Forms.TabControl mainViewTabControl;
private System.Windows.Forms.TabPage projectionTab;
private System.Windows.Forms.TabPage suppliersTabPage;
private System.Windows.Forms.DataGridView suppliersDataGridView;
private System.Windows.Forms.TabPage actualSalesTab;
private System.Windows.Forms.TableLayoutPanel actualSalesMainLayoutPanel;
private System.Windows.Forms.DataGridView actualSalesMainDataGidView;
private System.Windows.Forms.DataGridView projectedSalesMainDataGrid;
private System.Windows.Forms.ToolStripMenuItem recordsToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem addRecordsToolStripMenuItem;
private System.Windows.Forms.Label totalProfitReturnLabel;
private System.Windows.Forms.Label totalProfitReturnFromRemaingLabel;
private System.Windows.Forms.Label totalProfitFromAdItemsLabel;
private System.Windows.Forms.Label remainingSalesLabel;
private System.Windows.Forms.Label salesProducedLabel;
private System.Windows.Forms.Label departmentSalesLabel;
private System.Windows.Forms.TabPage WeeklySalesTabPage;
private System.Windows.Forms.DataGridView weeklySalesDataGridView;
private System.Windows.Forms.ToolStripMenuItem helpMainMenu;
private System.Windows.Forms.ToolStripMenuItem showHideConsoleHelpMainMenu;
private System.Windows.Forms.GroupBox taxableGroupBox;
private System.Windows.Forms.Label grossProfitEstimatedWeeklyDeptmartmentExpenseLabel;
private System.Windows.Forms.Label perfectGrossProfitLabel;
private System.Windows.Forms.Label grossProfitDollarGrossProfitLabel;
private System.Windows.Forms.Label grossProfitLessCostOfSales;
private System.Windows.Forms.Label grossProfitTotalSales;
private System.Windows.Forms.Panel dateSelectorPanel;
private System.Windows.Forms.ComboBox yearComboBox;
private System.Windows.Forms.ComboBox dayComboBox;
private System.Windows.Forms.ComboBox monthComboBox;
private System.Windows.Forms.Label dateSelectLabel;
private System.Windows.Forms.TabPage inventoryTabPage;
private System.Windows.Forms.DataGridView inventoryDataGridView;
private System.Windows.Forms.ToolStripMenuItem toolsMainMenu;
private System.Windows.Forms.ToolStripMenuItem adSpecialKeyWordsToolsMainMenu;
private System.Windows.Forms.ToolStripMenuItem deleteRecordsMainMenu;
private System.Windows.Forms.TextBox commentsTextBox;
private System.Windows.Forms.ToolStripMenuItem modifyRecordMainMenu;
private System.Windows.Forms.ToolStripMenuItem manageItemsToolsMainMenu;
private System.Windows.Forms.ToolStripMenuItem dbVersionHelpMainMenu;
private System.Windows.Forms.Button printPreviewButton;
private System.Windows.Forms.CheckBox usePreRenderedFilesCheckbox;
private System.Windows.Forms.ToolStripMenuItem newFormTestToolStripMenuItem;
private System.Windows.Forms.LinkLabel shrinkLinkLabel;
}
}
+797
View File
@@ -0,0 +1,797 @@
using System;
using System.Collections.Generic;
using System.Data;
using System.Drawing;
using System.Drawing.Printing;
using System.IO;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text.RegularExpressions;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
public partial class FrmMain : Form
{
private double _SalesProducedByAdItems = 0;
private double _TotalProfitReturnFromAdItems = 0;
private double _gCostOfSalesCalculatedTotal = 0;
private double _departmentSales = 0;
private List<string> _gDateStringCollection = new List<string>();
readonly FrmLogConsole _console = FrmLogConsole.GetStaticInstance;
private int _LazyPageCounter = 0;
public FrmMain()
{
InitializeComponent();
//Set the maximum and minimum sizes for the form.
//MaximumSize = new Size(1200, 650);
//MinimumSize = new Size(1000, 550);
}
private void frmMain_Load(object sender, EventArgs e)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var versionControl = new DatabaseVersionControl();
var version = versionControl.GetDatabaseVerionNumber(databaseTracker.DatabaseConnectionString);
if(version == "0.3.0.0")
{
MessageBox.Show("An older version of the APC database has been detected.\nAdvertising Profit Control " + Application.ProductVersion + " will now attempt to update it.", "Outdated Database Detected");
string versionNumber = "";
if (versionControl.UpdateVersionPointFive(databaseTracker.DatabaseConnectionString, out versionNumber))
{
MessageBox.Show("The database has been successfully upgraded to version " + versionNumber + ".\nA back up of the old database has been made called APCDatabase.bak in the same location as the current database.", "Half Baked Code For The Win");
}
}
RowParsing.AdSpecialGroups.AddRange(databaseReader.ReturnGroupNameList(databaseTracker.DatabaseConnectionString));
FillDateSuggestionComboBoxes();
BuildAndFillDataGridTables();
CalculateProfitAnalysis();
CalculateGrossProfit();
projectedSalesMainDataGrid.KeyDown += FrmMain_KeyDown;
//var margin = new Margins(50, 50, 0, 0);
//_printDoc.DefaultPageSettings.Margins = margin;
}
private void FrmMain_KeyDown(object sender, KeyEventArgs e)
{
if (e.Modifiers == Keys.Shift && e.KeyCode == Keys.Up)
{
MessageBox.Show("My message");
}
}
private void UpdateDataGridViewInformation(object sender, EventArgs e)
{
var dateString = monthComboBox.Text + "/" + dayComboBox.Text + "/" + yearComboBox.Text;
BuildAndFillDataGridTables(dateString);
CalculateProfitAnalysis();
CalculateGrossProfit();
}
/// <summary>
/// Builds and fills the DataGridView tables on the main form
/// from the either the most recent date or the date specified in the parameter.
/// </summary>
/// <param name="dateString">The date of records to display to the user, if no date is specified then the most recent date is used.</param>
private void BuildAndFillDataGridTables(string dateString = "")
{
//
var databaseTracker = new DatabaseTracker();
var dataBaseReader = new DatabaseReader();
//
var dateId = "";
//Check to see if a parameter has been passed.
if (dateString == "")
{
//IF non were, then grab the most recent date ID from the database and use that.
dateId = dataBaseReader.RetrieveMostRecentDateId(databaseTracker.DatabaseConnectionString);
_console.WriteToLog(FrmLogConsole.Level.Info, dateId != "0" ? "Most recent date ID is " + dateId : "Most recent date ID is unavailable.");
}
else
{
//ELSE IF one was passed, then use it's ID to build the tables.
dateId = dataBaseReader.RetrieveDateIdByDateString(dateString, databaseTracker.DatabaseConnectionString);
_console.WriteToLog(FrmLogConsole.Level.Info, dateId != "0" ? "Date ID for " + dateString + " is resolved to have the ID of " + dateId + "." : "The date " + dateString + " could not be found in the database.");
if (dateId == "0")
{
_gDateStringCollection.Remove(dateString);
}
}
//Now check to make sure there were no errors grabbing the ID, IF there were return.
if (dateId == "0") return;
//Clear the class global variables to prevents calculation mishaps.
_SalesProducedByAdItems = 0;
_TotalProfitReturnFromAdItems = 0;
_gCostOfSalesCalculatedTotal = 0;
//Clear all DataGridViews since the date supplied is valid and in the database.
projectedSalesMainDataGrid.DataSource = null;
projectedSalesMainDataGrid.Columns.Clear();
inventoryDataGridView.DataSource = null;
inventoryDataGridView.Columns.Clear();
actualSalesMainDataGidView.DataSource = null;
actualSalesMainDataGidView.Columns.Clear();
suppliersDataGridView.DataSource = null;
weeklySalesDataGridView.DataSource = null;
//Begin by grabbing the Projections table
var tempTable = dataBaseReader.ReturnProjectionsTable(dateId, databaseTracker.DatabaseConnectionString);
if (tempTable.Rows.Count > 0)
{
BuildSalesDataGridViews(projectedSalesMainDataGrid, tempTable);
}
//Grabbing the Inventory table
tempTable = dataBaseReader.ReturnInventoryTable(dateId, databaseTracker.DatabaseConnectionString);
if (tempTable.Rows.Count > 0)
{
BuildInventoryDataGridView(inventoryDataGridView, tempTable);
}
//And the Actual Sales table
tempTable = dataBaseReader.ReturnActualSales(dateId, databaseTracker.DatabaseConnectionString);
if (tempTable.Rows.Count > 0)
{
BuildSalesDataGridViews(actualSalesMainDataGidView, tempTable);
}
//Next the Invoices table
tempTable = dataBaseReader.ReturnInvoiceTable(dateId, databaseTracker.DatabaseConnectionString);
if (tempTable.Rows.Count > 0)
{
suppliersDataGridView.DataSource = SumCostOfSales(tempTable);
}
//And finally the weekly sales
tempTable = dataBaseReader.ReturnWeeklySalesFromDateId(dateId, databaseTracker.DatabaseConnectionString);
if (tempTable.Rows.Count > 0)
{
weeklySalesDataGridView.DataSource = tempTable;
}
commentsTextBox.Text = dataBaseReader.RetrieveComments(dateId, databaseTracker.DatabaseConnectionString);
}
private void CalculateProfitAnalysis(double shrink = 0.30)
{
if (Math.Abs(_SalesProducedByAdItems) < 1 || Math.Abs(_TotalProfitReturnFromAdItems) < 1)
{
//Clear the labels...
if (weeklySalesDataGridView.Rows.Count == 0 || weeklySalesDataGridView.Rows[0].Cells[7].EditedFormattedValue.ToString() == "0.0000")
{
departmentSalesLabel.Text = "Department Sales: No Weekly Sales Found.";
departmentSalesLabel.ForeColor = Color.Red;
}
if (_SalesProducedByAdItems == 0)
{
salesProducedLabel.Text = "Sales Produced By Ad Items (A): No Values to Total.";
salesProducedLabel.ForeColor = Color.Red;
}
remainingSalesLabel.Text = "Remaining Sales: ";
if (_TotalProfitReturnFromAdItems == 0)
{
totalProfitFromAdItemsLabel.Text = "Total Profit Return From Ad Items (B): No Values to Total.";
totalProfitFromAdItemsLabel.ForeColor = Color.Red;
}
totalProfitReturnFromRemaingLabel.Text = "Total Profit Return From Remaining Sales: ";
totalProfitReturnLabel.Text = "Total Profit Return: ";
return;
}
double.TryParse(weeklySalesDataGridView.Rows[0].Cells[7].EditedFormattedValue.ToString(), out _departmentSales);
//Since there are department sales, change the label's color to make sure it doesn't appear as an error.
departmentSalesLabel.ForeColor = Color.Black;
departmentSalesLabel.Text = "Department Sales: " + _departmentSales.ToString("C");
//Assume that the sales produced is larger then zero (0).
salesProducedLabel.ForeColor = Color.Black;
salesProducedLabel.Text = "Sales Produced By Ad Items (A): " + _SalesProducedByAdItems.ToString("C");
double remainingSales = _departmentSales - _SalesProducedByAdItems;
remainingSalesLabel.Text = "Remaining Sales: " + remainingSales.ToString("C");
//Again assume the total profit return is larger then zero (0).
totalProfitFromAdItemsLabel.ForeColor = Color.Black;
totalProfitFromAdItemsLabel.Text = "Total Profit Return From Ad Items (B): " + _TotalProfitReturnFromAdItems.ToString("C");
//Shrink is being used as a place holder for Cross Profit % which is obtained by dividing gActualTotalProfitReturnCalculatedTotal by the department weekly retail sales.
double totalProfitReturnFromRemainingSales = shrink * remainingSales;
//
totalProfitReturnFromRemaingLabel.Text = "Total Profit Return From Remaining Sales: " + totalProfitReturnFromRemainingSales.ToString("C");
double totalProfitReturn = _TotalProfitReturnFromAdItems + totalProfitReturnFromRemainingSales;
totalProfitReturnLabel.Text = "Total Profit Return: " + totalProfitReturn.ToString("C");
}
private void BuildSalesDataGridViews(DataGridView dataGridView, DataTable table)
{
var adSpecialIndex = -1;
double totalSales = 0;
double totalProfitReturn = 0;
foreach (DataColumn column in table.Columns)
{
var dataGridViewColumn = new DataGridViewColumn()
{
HeaderText = column.ColumnName,
CellTemplate = new DataGridViewTextBoxCell()
};
if (dataGridViewColumn.HeaderText.Contains("Projection"))
{
dataGridViewColumn.HeaderText = dataGridViewColumn.HeaderText.Replace("Projection", "");
}
else if (dataGridViewColumn.HeaderText.Contains("Actual"))
{
dataGridViewColumn.HeaderText = dataGridViewColumn.HeaderText.Replace("Actual", "");
}
if (dataGridViewColumn.HeaderText == "FK_GroupID" || dataGridViewColumn.HeaderText == "RowAttribute")
{
dataGridViewColumn.Visible = false;
}
dataGridViewColumn.HeaderText = TextFormat.AddSpacesToSentence(dataGridViewColumn.HeaderText, false);
dataGridView.Columns.Add(dataGridViewColumn);
}
for (var i = 0; i < table.Rows.Count; i++)
{
var row = new DataGridViewRow();
//Checks for the group, if any, the row or rows is/are part of.
if (table.Rows[i][8].ToString() != "" &&
int.Parse(table.Rows[i][8].ToString()) != 0 && adSpecialIndex == -1)
{
adSpecialIndex = i;
var adSpecialRow = new DataGridViewRow();
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var groupName = databaseReader.ReturnGroupNameFromGroupId(table.Rows[i][8].ToString(), databaseTracker.DatabaseConnectionString);
adSpecialRow.DefaultCellStyle.BackColor = Color.DarkGray;
dataGridView.Rows.Add(adSpecialRow);
dataGridView.Rows[i].Cells[0].Value = groupName;
}
//Checks for row attribute
if (table.Rows[i][7].ToString() != "")
{
//The seventh column contains the row's attribute if any.
var rowAttribute = int.Parse(table.Rows[i][7].ToString());
if (rowAttribute == 1)
{
row.DefaultCellStyle.BackColor = Color.LightGray;
}
else if (rowAttribute == 2)
{
row.DefaultCellStyle.BackColor = Color.LightBlue;
}
foreach (var dataCell in table.Rows[i].ItemArray.Select(cell => new DataGridViewTextBoxCell { Value = cell }))
{
row.Cells.Add(dataCell);
}
dataGridView.Rows.Add(row);
}
else
{
dataGridView.Rows.Add(table.Rows[i].ItemArray);
}
//Check for values in the Total Sales and Total Profit Return columns
double tempOut = 0;
if (double.TryParse(table.Rows[i][3].ToString(), out tempOut))
{
if (tempOut >= 0)
{
totalSales += tempOut;
}
}
if (double.TryParse(table.Rows[i][6].ToString(), out tempOut))
{
if (tempOut >= 0)
{
totalProfitReturn += tempOut;
}
}
}
var totalsRow = new object[9];
totalsRow[0] = "Totals";
totalsRow[3] = totalSales;
totalsRow[6] = totalProfitReturn;
dataGridView.Rows.Add(totalsRow);
if (dataGridView.Name == "actualSalesMainDataGidView")
{
_SalesProducedByAdItems = totalSales;
_TotalProfitReturnFromAdItems = totalProfitReturn;
}
}
private void BuildInventoryDataGridView(DataGridView dataGridView, DataTable table)
{
var lastAdSpecialIndex = -1;
for (var columnIndex = 0; columnIndex < table.Columns.Count; columnIndex++)
{
var dataGridViewColumn = new DataGridViewColumn
{
Name = table.Columns[columnIndex].ColumnName,
CellTemplate = new DataGridViewTextBoxCell()
};
var columnHeaderText = table.Columns[columnIndex].ColumnName;
columnHeaderText = TextFormat.AddSpacesToSentence(columnHeaderText, false);
//Make the row attribute column invisible.
if (table.Columns[columnIndex].ColumnName == "RowAttribute")
{
dataGridViewColumn.Visible = false;
}
//Make any columns with a foreign key invisible.
if (table.Columns[columnIndex].ColumnName.Contains("FK"))
{
dataGridViewColumn.Visible = false;
}
dataGridViewColumn.HeaderText = columnHeaderText;
dataGridView.Columns.Add(dataGridViewColumn);
}
for (var rowIndex = 0; rowIndex < table.Rows.Count; rowIndex++)
{
var row = new DataGridViewRow();
if (table.Rows[rowIndex][6].ToString() != "" && int.Parse(table.Rows[rowIndex][6].ToString()) != 0 && lastAdSpecialIndex == -1)
{
lastAdSpecialIndex = rowIndex;
var adSpecialRow = new DataGridViewRow();
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var groupName = databaseReader.ReturnGroupNameFromGroupId(table.Rows[rowIndex][6].ToString(), databaseTracker.DatabaseConnectionString);
adSpecialRow.DefaultCellStyle.BackColor = Color.DarkGray;
dataGridView.Rows.Add(adSpecialRow);
dataGridView.Rows[rowIndex].Cells[0].Value = groupName;
}
if (table.Rows[rowIndex][5].ToString() != "")
{
//The fifth column contains the row's attribute if any.
var rowAttribute = int.Parse(table.Rows[rowIndex][5].ToString());
if (rowAttribute == 1)
{
row.DefaultCellStyle.BackColor = Color.LightGray;
}
else if (rowAttribute == 2)
{
row.DefaultCellStyle.BackColor = Color.LightBlue;
}
foreach (var dataCell in table.Rows[rowIndex].ItemArray.Select(cell => new DataGridViewTextBoxCell { Value = cell }))
{
row.Cells.Add(dataCell);
}
dataGridView.Rows.Add(row);
}
else
{
dataGridView.Rows.Add(table.Rows[rowIndex].ItemArray);
}
}
}
private void CalculateGrossProfit()
{
if (Math.Abs(_gCostOfSalesCalculatedTotal) < 1)
{
//IF Cost of Sales hasn't been calculated, then clear labels and return.
if (weeklySalesDataGridView.Rows.Count == 0 || weeklySalesDataGridView.Rows[0].Cells[7].EditedFormattedValue.ToString() == "0.0000")
{
grossProfitTotalSales.Text = "Total Sales: No Weekly Sales Found.";
grossProfitTotalSales.ForeColor = Color.Red;
}
grossProfitLessCostOfSales.Text = "Less Cost of Sales: ";
grossProfitDollarGrossProfitLabel.Text = "Dollar Gross Profit: ";
perfectGrossProfitLabel.Text = "Percent Gross Profit: ";
return;
}
double totalSales = Convert.ToDouble(weeklySalesDataGridView.Rows[0].Cells[7].EditedFormattedValue.ToString());
grossProfitTotalSales.ForeColor = Color.Black;
grossProfitTotalSales.Text = "Total Sales: " + totalSales.ToString("C");
grossProfitLessCostOfSales.Text = "Less Cost of Sales: " + _gCostOfSalesCalculatedTotal.ToString("C");
double dollarGrossProfit = totalSales - _gCostOfSalesCalculatedTotal;
grossProfitDollarGrossProfitLabel.Text = "Dollar Gross Profit: " + dollarGrossProfit.ToString("C");
double grossProfitPercent = dollarGrossProfit / totalSales;
perfectGrossProfitLabel.Text = "Percent Gross Profit: " + grossProfitPercent.ToString("P");
}
private void addRecordToolStripMenuItem_Click(object sender, EventArgs e)
{
var recordForm = new FrmAddRecord();
recordForm.ShowDialog();
FillDateSuggestionComboBoxes();
BuildAndFillDataGridTables();
CalculateProfitAnalysis();
CalculateGrossProfit();
}
/// <summary>
/// Appends a new "Totals" row to the end of the Invoice table that is passed in
/// and sums up the Net Cost of Invoices column as well as storing the total Costs of Sales
/// into the class wide variable for use with other functions.
/// </summary>
/// <param name="invoiceTable">The Invoice table to summed.</param>
/// <returns></returns>
private DataTable SumCostOfSales(DataTable invoiceTable)
{
//Check for a null parameter OR if the column count is less then six (6) as any less means the database isn't returning correctly.
if(invoiceTable == null || invoiceTable.Columns.Count < 6) return invoiceTable;
double costOfSalesSum = 0;
for (var i = 0; i < invoiceTable.Rows.Count; i++)
{
costOfSalesSum += Convert.ToDouble(invoiceTable.Rows[i][4]);
}
_gCostOfSalesCalculatedTotal = costOfSalesSum;
object[] invoiceTotalRow = new object[invoiceTable.Columns.Count];
invoiceTotalRow[0] = "Total Purchases";
invoiceTotalRow[4] = costOfSalesSum;
invoiceTable.Rows.Add(invoiceTotalRow);
return invoiceTable;
}
private void showHideConsoleHelpMainMenu_Click(object sender, EventArgs e)
{
if (_console.IsVisable)
{
_console.Hide();
}
else
{
_console.Show();
}
}
/// <summary>
/// Grabs all dates from the database and splits the returned strings
/// into months, days, and years and stores them in their respective
/// combo boxes to display to the user. Also stores the list of dates
/// inside a class wide variable.
/// </summary>
private void FillDateSuggestionComboBoxes()
{
//Create a connection to the database retrieval class.
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
//Grab the most recent date in the database.
var mostRecentDateTime = databaseReader.RetrieveMostRecentDateString(databaseTracker.DatabaseConnectionString);
var mostRecentDateString = mostRecentDateTime.ToString("MM/dd/yyyy");
//Check to see if the return value is null and IF so log the error and return.
if(mostRecentDateString == ""){ _console.WriteToLog(FrmLogConsole.Level.Error, "No dates could be found in the database."); return;}
//Otherwise, if there was a return date, split it into a array.
var mostRecentDateParts = mostRecentDateString.Split('/');
//Grab only the most recent years in the database (only say 2015) and fill a table with the dates. Indexes are as follows: [0] is Month, [1] is Day and [2] is Year.
var datesList = databaseReader.RetrieveDateListByYear(mostRecentDateParts[2], databaseTracker.DatabaseConnectionString);
//Suspend the control's drawing so the user doesn't see any ugly enumeration and index changing.
DrawingControl.SuspendDrawing(dateSelectorPanel);
//Considering there was a return value for the most recent date, its safe to assume there is at least one date in the database, so clear the class's date collection.
_gDateStringCollection.Clear();
monthComboBox.Items.Clear();
dayComboBox.Items.Clear();
yearComboBox.Items.Clear();
monthComboBox.SelectedIndexChanged -= UpdateDaysOfMonth;
dayComboBox.SelectedIndexChanged -= UpdateDataGridViewInformation;
yearComboBox.SelectedIndexChanged -= UpdateDaysOfMonthByYear;
//Now spin through the oneYearDatesTable and fill the class wide object with all the dates for the most recent year.
for (var i = 0; i < datesList.Count; i ++)
{
var fullDateString = datesList[i].ToString("MM/dd/yyyy");
//Check for nulls just to be paranoid.
if (fullDateString == "")
{
return;
}
//IF the date string collection already contains the date, then continue to the next iteration.
if (_gDateStringCollection.Contains(fullDateString))
{
continue;
}
_gDateStringCollection.Add(fullDateString);
}
var dayBasedOnMonthAndYeaRegex = new Regex("^0?" + mostRecentDateParts[0] + @"/\d{2}/" + mostRecentDateParts[2]);
var monthBasedOnYearRegex = new Regex(@"^\d{2}/\d{2}/" + mostRecentDateParts[2]);
for (var i = 0; i < _gDateStringCollection.Count; i++)
{
string[] dateArray = _gDateStringCollection[i].Split('/');
var month = dateArray[0];
var day =dateArray[1];
if (dayBasedOnMonthAndYeaRegex.IsMatch(_gDateStringCollection[i]))
{
dayComboBox.Items.Add(day);
}
if (monthBasedOnYearRegex.IsMatch(_gDateStringCollection[i]))
{
if (!monthComboBox.Items.Contains(month))
{
monthComboBox.Items.Add(month);
}
}
}
var yearsInDatabase = databaseReader.RetrieveUniqueYearsList(databaseTracker.DatabaseConnectionString);
foreach (var year in yearsInDatabase)
{
yearComboBox.Items.Add(year);
}
if (dayComboBox.Items.Count >= 1 && yearComboBox.Items.Count >= 1 && monthComboBox.Items.Count >= 1)
{
monthComboBox.SelectedIndex = monthComboBox.Items.Count - 1;
dayComboBox.SelectedIndex = dayComboBox.Items.Count - 1;
yearComboBox.SelectedIndex = yearComboBox.Items.Count - 1;
monthComboBox.Enabled = true;
dayComboBox.Enabled = true;
yearComboBox.Enabled = true;
}
else
{
monthComboBox.Enabled = false;
dayComboBox.Enabled = false;
yearComboBox.Enabled = false;
}
monthComboBox.SelectedIndexChanged += UpdateDaysOfMonth;
dayComboBox.SelectedIndexChanged += UpdateDataGridViewInformation;
yearComboBox.SelectedIndexChanged += UpdateDaysOfMonthByYear;
DrawingControl.ResumeDrawing(dateSelectorPanel);
}
private void UpdateDaysOfMonth(object sender, EventArgs e)
{
if (yearComboBox.SelectedIndex == -1) return;
var year = yearComboBox.SelectedItem.ToString();
var month = monthComboBox.SelectedItem.ToString();
var dateParserPattern = new Regex("^" + month + @"\/\d{2}\/" + year);
dayComboBox.Items.Clear();
for (var i = 0; i < _gDateStringCollection.Count; i++)
{
if (dateParserPattern.IsMatch(_gDateStringCollection[i]))
{
var dateArray = _gDateStringCollection[i].Split('/');
var day = dateArray[1];
dayComboBox.Items.Add(day);
}
}
if (dayComboBox.Items.Count > 0)
{
dayComboBox.SelectedIndex = dayComboBox.Items.Count - 1;
}
CalculateProfitAnalysis();
CalculateGrossProfit();
}
/// <summary>
/// Fires when the Year combo box's index changes.
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void UpdateDaysOfMonthByYear(object sender, EventArgs e)
{
//Obligatory database retrieval call...
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
//First, grab the year and the month from their respective combo boxes.
var year = yearComboBox.SelectedItem.ToString();
var month = monthComboBox.SelectedItem.ToString();
//Since we can more or less be certain that nothing is null, clear the current date collection.
_gDateStringCollection.Clear();
var months = databaseReader.RetrieveUniqueMonthsList(year, databaseTracker.DatabaseConnectionString);
var mostRecentMonth = months.Max();
if (mostRecentMonth.Length == 1)
{
mostRecentMonth = "0" + mostRecentMonth;
}
var datesList = databaseReader.RetrieveDateListByYear(year, databaseTracker.DatabaseConnectionString);
for (var i = 0; i < datesList.Count; i++)
{
_gDateStringCollection.Add(datesList[i].ToString("MM/dd/yyyy"));
}
//Clear the month and day combo boxes and unregister their event handlers.
dayComboBox.Items.Clear();
monthComboBox.Items.Clear();
monthComboBox.SelectedIndexChanged -= UpdateDaysOfMonth;
dayComboBox.SelectedIndexChanged -= UpdateDataGridViewInformation;
for (var i = 0; i < _gDateStringCollection.Count; i ++)
{
var dateArray = _gDateStringCollection[i].Split('/');
month = dateArray[0];
//Declare the patterns to look for when enumerating the combo boxes.
var dayBasedOnMonthAndYeaRegex = new Regex(@"^(" + mostRecentMonth + @"\/\d{2}\/" + year + ")"); //Only allows days that are actually part of the month and year.
var day = dateArray[1];
if (dayBasedOnMonthAndYeaRegex.IsMatch(_gDateStringCollection[i]))
{
dayComboBox.Items.Add(day);
}
if (!monthComboBox.Items.Contains(month))
{
monthComboBox.Items.Add(month);
}
}
if (dayComboBox.Items.Count > 0)
{
dayComboBox.SelectedIndex = dayComboBox.Items.Count - 1;
}
if (monthComboBox.Items.Count > 0)
{
monthComboBox.SelectedIndex = monthComboBox.Items.Count - 1;
}
//Now re-register the event handlers
monthComboBox.SelectedIndexChanged += UpdateDaysOfMonth;
dayComboBox.SelectedIndexChanged += UpdateDataGridViewInformation;
BuildAndFillDataGridTables(monthComboBox.SelectedItem + "/" + dayComboBox.SelectedItem + "/" + year);
CalculateProfitAnalysis();
CalculateGrossProfit();
}
private void adSpecialKeyWordsToolsMainMenu_Click(object sender, EventArgs e)
{
var keyWordRegister = new FrmAdSpecialRegister();
keyWordRegister.ShowDialog();
}
private void deleteRecordsMainMenu_Click(object sender, EventArgs e)
{
var frmDeleteRecord = new FrmDeleteRecord();
frmDeleteRecord.ShowDialog();
FillDateSuggestionComboBoxes();
BuildAndFillDataGridTables();
CalculateProfitAnalysis();
CalculateGrossProfit();
}
private void modifyRecordMainMenu_Click(object sender, EventArgs e)
{
var modifyForm = new FrmModifyRecord();
modifyForm.ShowDialog();
BuildAndFillDataGridTables();
CalculateProfitAnalysis();
CalculateGrossProfit();
}
private void manageItemsToolsMainMenu_Click(object sender, EventArgs e)
{
var adItemManager = new FrmManageAdItems();
adItemManager.ShowDialog();
}
private void dbVersionHelpMainMenu_Click(object sender, EventArgs e)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var version = databaseReader.GetDatabaseVersion(databaseTracker.DatabaseConnectionString);
if (version != "0.0.0.0")
{
MessageBox.Show("The current database's version is " + version + ".", "Database Version Number");
}
}
private void PrintPage(object sender, PrintPageEventArgs e)
{
Bitmap bitMap;
if (_LazyPageCounter == 0)
{
bitMap = new Bitmap(Application.StartupPath + "\\FrontPage.png");
}
else
{
bitMap = new Bitmap(Application.StartupPath + "\\BackPage.png");
}
var rect = e.MarginBounds;
if ((double)bitMap.Width / (double)bitMap.Height > (double)rect.Width / (double)rect.Height) // image is wider
{
rect.Height = (int)((double)bitMap.Height / (double)bitMap.Width * (double)rect.Width);
}
else
{
rect.Width = (int)((double)bitMap.Width / (double)bitMap.Height * (double)rect.Height);
}
if (_LazyPageCounter == 0)
{
e.Graphics.DrawImage(bitMap, new Rectangle(0, 25, 850, 1050));
_LazyPageCounter++;
e.HasMorePages = true;
}
else
{
e.Graphics.DrawImage(bitMap, new Rectangle(0, 0, 850, 1100));
_LazyPageCounter = 0;
e.HasMorePages = false;
}
}
private void DisplayPrintPreview(object sender, EventArgs e)
{
//Build and render the front and back forms of the document.
var test = new FrontPageGenerator();
var backPageTest = new BackPageGenerator();
var printTestPage = new PrintDocument();
var printDialog = new PrintPreviewDialog();
if (!usePreRenderedFilesCheckbox.Checked)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var dateId =
databaseReader.RetrieveDateIdByDateString(
monthComboBox.SelectedItem + "/" + dayComboBox.SelectedItem + "/" + yearComboBox.SelectedItem,
databaseTracker.DatabaseConnectionString);
double remaingingSales = _departmentSales - _SalesProducedByAdItems;
double totalProfitReturnFromReminaingSales = remaingingSales*.3;
double totalProfitReturn = _TotalProfitReturnFromAdItems + totalProfitReturnFromReminaingSales;
test.BuildFormFrontCompressedLayout(dateId, _departmentSales, _SalesProducedByAdItems, remaingingSales,
_TotalProfitReturnFromAdItems, totalProfitReturnFromReminaingSales, totalProfitReturn,
commentsTextBox.Text);
test.RenderHtmlToImage();
backPageTest.GenerateWeeklyInventoryControlPage(dateId);
backPageTest.RenderHtmlToImage();
}
else
{
if (File.Exists(Application.StartupPath + "\\" + "FrontPage.html") &&
File.Exists(Application.StartupPath + "\\" + "Backpage.html"))
{
test.RenderHtmlToImage();
backPageTest.RenderHtmlToImage();
}
}
//var margin = new Margins(50, 50, 0, 0);
//printDoc.DefaultPageSettings.Margins = margin;
printTestPage.PrintPage += PrintPage;
printDialog.Document = printTestPage;
printDialog.ShowDialog();
printDialog.Document = new PrintDocument();
}
private void newFormTestToolStripMenuItem_Click(object sender, EventArgs e)
{
var form = new NewAddRecord();
form.ShowDialog();
}
}
//http://stackoverflow.com/questions/487661/how-do-i-suspend-painting-for-a-control-and-its-children
internal class DrawingControl
{
[DllImport("user32.dll")]
public static extern int SendMessage(IntPtr hWnd, Int32 wMsg, bool wParam, Int32 lParam);
private const int WM_SETREDRAW = 11;
public static void SuspendDrawing(Control parent)
{
SendMessage(parent.Handle, WM_SETREDRAW, false, 0);
}
public static void ResumeDrawing(Control parent)
{
SendMessage(parent.Handle, WM_SETREDRAW, true, 0);
parent.Refresh();
}
}
}
File diff suppressed because it is too large Load Diff
+154
View File
@@ -0,0 +1,154 @@
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Globalization;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
public partial class FrmManageAdItems : Form
{
public FrmManageAdItems()
{
InitializeComponent();
MaximumSize = new Size(550, 505);
MinimumSize = new Size(525, 480);
}
private void frmManageAdItems_Load(object sender, EventArgs e)
{
FillAdItemComboBoxFilter();
adItemFilterComboBox.SelectedIndexChanged += UpdateFiltering;
adItemListView.SelectedIndexChanged += OnListItemSelectionChanged;
adItemTextBox.TextChanged += NewAdItemTextChanged;
}
private void NewAdItemTextChanged(object sender, EventArgs e)
{
if(adItemTextBox.TextLength == 0)
{
addItemButton.Enabled = false;
return;
}
else
{
addItemButton.Enabled = true;
}
}
private void OnListItemSelectionChanged(object sender, EventArgs e)
{
if(adItemListView.SelectedItems.Count > 0)
{
deleteSelectedItem.Enabled = true;
}
else
{
deleteSelectedItem.Enabled = false;
}
}
private void UpdateFiltering(object sender, EventArgs e)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var itemList = new List<string>();
adItemListView.Items.Clear();
if(adItemFilterComboBox.Text == "All Items")
{
itemList = databaseReader.RetrieveAdItemListByLetter(databaseTracker.DatabaseConnectionString);
}
else
{
itemList = databaseReader.RetrieveAdItemListByLetter(databaseTracker.DatabaseConnectionString, adItemFilterComboBox.Text);
}
foreach (var item in itemList)
{
var listViewItem = new ListViewItem(item);
adItemListView.Items.Add(listViewItem);
}
}
private void deleteSelectedItem_Click(object sender, EventArgs e)
{
if(adItemListView.SelectedItems.Count == 0)
{
return;
}
var databaseTracker = new DatabaseTracker();
var databaseWriter = new DatabaseWriter(databaseTracker.DatabaseConnectionString);
if (databaseWriter.RemoveAdItem(adItemListView.SelectedItems[0].Text))
{
notificationLabel.Text = "Successfully removed " + adItemListView.SelectedItems[0].Text + "\n from the database.";
adItemListView.Items.Remove(adItemListView.SelectedItems[0]);
}
deleteSelectedItem.Enabled = false;
}
private void addItemButton_Click(object sender, EventArgs e)
{
var databaseTracker = new DatabaseTracker();
var databaseWriter = new DatabaseWriter(databaseTracker.DatabaseConnectionString);
if (adItemTextBox.Text == "") return;
TextInfo textInfo = new CultureInfo("en-US", false).TextInfo;
//Clean up the input string.
//Pretty up the ad item's name by uppercasing the name.
var adItemText = adItemTextBox.Text;
adItemText = textInfo.ToTitleCase(adItemText);
//Eliminate the upper cased pound abbreviation ("Lb") with a standard "lb".
adItemText = adItemText.Replace("Lb", "lb");
adItemText = adItemText.Replace("LB", "lb");
adItemText = adItemText.Replace("lB", "lb");
adItemText = adItemText.Replace(":", "");
adItemText = adItemText.Replace(";", "");
adItemText = adItemText.Replace("/", "");
adItemText = adItemText.Replace("\\", "");
if (databaseWriter.AddNewItem(adItemText))
{
notificationLabel.Text = "Successfully inserted " + adItemText + "\n into the database.";
if (adItemFilterComboBox.SelectedIndex == 0 || adItemFilterComboBox.SelectedItem.ToString()[0] == adItemText[0])
{
adItemListView.Items.Add(adItemText);
}
if (!adItemFilterComboBox.Items.Contains(adItemText[0]))
{
adItemFilterComboBox.Items.Add(adItemText[0]);
}
}
addItemLabel.Select();
adItemTextBox.Text = "";
addItemButton.Enabled = false;
}
private void FillAdItemComboBoxFilter()
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var columnHeader = new ColumnHeader();
columnHeader.Text = "Ad Items";
columnHeader.Width = 300;
adItemListView.Columns.Add(columnHeader);
var itemList = databaseReader.RetrieveAdItemListByLetter(databaseTracker.DatabaseConnectionString);
foreach (var item in itemList)
{
var listViewItem = new ListViewItem(item);
if (!adItemFilterComboBox.Items.Contains(item[0]))
{
adItemFilterComboBox.Items.Add(item[0]);
}
adItemListView.Items.Add(listViewItem);
}
adItemFilterComboBox.Items.Insert(0, "All Items");
columnHeader.Width = -1;
adItemFilterComboBox.SelectedIndex = 0;
}
private void closeFormFileMainMenu_Click(object sender, EventArgs e)
{
Close();
}
}
}
File diff suppressed because it is too large Load Diff
+448
View File
@@ -0,0 +1,448 @@
namespace AdvertsingProfitControl
{
partial class FrmModifyRecord
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmModifyRecord));
this.mainTableLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.mainMenu = new System.Windows.Forms.MenuStrip();
this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.exitToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.debugToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.getAttributeToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.mainTabControl = new System.Windows.Forms.TabControl();
this.projectionsTabpage = new System.Windows.Forms.TabPage();
this.projectionsDataGridView = new System.Windows.Forms.DataGridView();
this.inventoryTabPage = new System.Windows.Forms.TabPage();
this.inventoryDataGridView = new System.Windows.Forms.DataGridView();
this.actualSalesTabPage = new System.Windows.Forms.TabPage();
this.actualSalesDataGridView = new System.Windows.Forms.DataGridView();
this.invoicesTabPage = new System.Windows.Forms.TabPage();
this.invoicesDataGridView = new System.Windows.Forms.DataGridView();
this.weeklySalesTabPage = new System.Windows.Forms.TabPage();
this.weeklySalesDataGridView = new System.Windows.Forms.DataGridView();
this.secondaryTableLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.commentsGroupBox = new System.Windows.Forms.GroupBox();
this.commentsTextBox = new System.Windows.Forms.TextBox();
this.dateSelectorGroupBox = new System.Windows.Forms.GroupBox();
this.updateRecords = new System.Windows.Forms.Button();
this.notificationLabel = new System.Windows.Forms.Label();
this.yearComboBox = new System.Windows.Forms.ComboBox();
this.dayComboBox = new System.Windows.Forms.ComboBox();
this.monthComboBox = new System.Windows.Forms.ComboBox();
this.mainTableLayoutPanel.SuspendLayout();
this.mainMenu.SuspendLayout();
this.mainTabControl.SuspendLayout();
this.projectionsTabpage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.projectionsDataGridView)).BeginInit();
this.inventoryTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.inventoryDataGridView)).BeginInit();
this.actualSalesTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.actualSalesDataGridView)).BeginInit();
this.invoicesTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.invoicesDataGridView)).BeginInit();
this.weeklySalesTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.weeklySalesDataGridView)).BeginInit();
this.secondaryTableLayoutPanel.SuspendLayout();
this.commentsGroupBox.SuspendLayout();
this.dateSelectorGroupBox.SuspendLayout();
this.SuspendLayout();
//
// mainTableLayoutPanel
//
this.mainTableLayoutPanel.ColumnCount = 1;
this.mainTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.mainTableLayoutPanel.Controls.Add(this.mainMenu, 0, 0);
this.mainTableLayoutPanel.Controls.Add(this.mainTabControl, 0, 1);
this.mainTableLayoutPanel.Controls.Add(this.secondaryTableLayoutPanel, 0, 2);
this.mainTableLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainTableLayoutPanel.Location = new System.Drawing.Point(0, 0);
this.mainTableLayoutPanel.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.mainTableLayoutPanel.Name = "mainTableLayoutPanel";
this.mainTableLayoutPanel.RowCount = 3;
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 38F));
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 70F));
this.mainTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 30F));
this.mainTableLayoutPanel.Size = new System.Drawing.Size(1180, 712);
this.mainTableLayoutPanel.TabIndex = 0;
//
// mainMenu
//
this.mainMenu.ImageScalingSize = new System.Drawing.Size(24, 24);
this.mainMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.fileToolStripMenuItem,
this.debugToolStripMenuItem});
this.mainMenu.Location = new System.Drawing.Point(0, 0);
this.mainMenu.Name = "mainMenu";
this.mainMenu.Padding = new System.Windows.Forms.Padding(9, 3, 0, 3);
this.mainMenu.Size = new System.Drawing.Size(1180, 35);
this.mainMenu.TabIndex = 0;
this.mainMenu.Text = "menuStrip1";
//
// fileToolStripMenuItem
//
this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.exitToolStripMenuItem});
this.fileToolStripMenuItem.Name = "fileToolStripMenuItem";
this.fileToolStripMenuItem.Size = new System.Drawing.Size(50, 29);
this.fileToolStripMenuItem.Text = "&File";
//
// exitToolStripMenuItem
//
this.exitToolStripMenuItem.Name = "exitToolStripMenuItem";
this.exitToolStripMenuItem.Size = new System.Drawing.Size(187, 30);
this.exitToolStripMenuItem.Text = "&Close Form";
//
// debugToolStripMenuItem
//
this.debugToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.getAttributeToolStripMenuItem});
this.debugToolStripMenuItem.Name = "debugToolStripMenuItem";
this.debugToolStripMenuItem.Size = new System.Drawing.Size(78, 29);
this.debugToolStripMenuItem.Text = "Debug";
//
// getAttributeToolStripMenuItem
//
this.getAttributeToolStripMenuItem.Name = "getAttributeToolStripMenuItem";
this.getAttributeToolStripMenuItem.Size = new System.Drawing.Size(211, 30);
this.getAttributeToolStripMenuItem.Text = "Get Attribute";
this.getAttributeToolStripMenuItem.Click += new System.EventHandler(this.getAttributeToolStripMenuItem_Click);
//
// mainTabControl
//
this.mainTabControl.Controls.Add(this.projectionsTabpage);
this.mainTabControl.Controls.Add(this.inventoryTabPage);
this.mainTabControl.Controls.Add(this.actualSalesTabPage);
this.mainTabControl.Controls.Add(this.invoicesTabPage);
this.mainTabControl.Controls.Add(this.weeklySalesTabPage);
this.mainTabControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainTabControl.Location = new System.Drawing.Point(4, 43);
this.mainTabControl.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.mainTabControl.Name = "mainTabControl";
this.mainTabControl.SelectedIndex = 0;
this.mainTabControl.Size = new System.Drawing.Size(1172, 461);
this.mainTabControl.TabIndex = 1;
//
// projectionsTabpage
//
this.projectionsTabpage.Controls.Add(this.projectionsDataGridView);
this.projectionsTabpage.Location = new System.Drawing.Point(4, 29);
this.projectionsTabpage.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.projectionsTabpage.Name = "projectionsTabpage";
this.projectionsTabpage.Padding = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.projectionsTabpage.Size = new System.Drawing.Size(1164, 428);
this.projectionsTabpage.TabIndex = 0;
this.projectionsTabpage.Text = "Projections";
this.projectionsTabpage.UseVisualStyleBackColor = true;
//
// projectionsDataGridView
//
this.projectionsDataGridView.AllowDrop = true;
this.projectionsDataGridView.AllowUserToResizeRows = false;
this.projectionsDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.projectionsDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.projectionsDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.projectionsDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.projectionsDataGridView.Location = new System.Drawing.Point(4, 5);
this.projectionsDataGridView.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.projectionsDataGridView.MultiSelect = false;
this.projectionsDataGridView.Name = "projectionsDataGridView";
this.projectionsDataGridView.Size = new System.Drawing.Size(1156, 418);
this.projectionsDataGridView.TabIndex = 0;
//
// inventoryTabPage
//
this.inventoryTabPage.Controls.Add(this.inventoryDataGridView);
this.inventoryTabPage.Location = new System.Drawing.Point(4, 29);
this.inventoryTabPage.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.inventoryTabPage.Name = "inventoryTabPage";
this.inventoryTabPage.Padding = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.inventoryTabPage.Size = new System.Drawing.Size(1164, 428);
this.inventoryTabPage.TabIndex = 1;
this.inventoryTabPage.Text = "Inventory";
this.inventoryTabPage.UseVisualStyleBackColor = true;
//
// inventoryDataGridView
//
this.inventoryDataGridView.AllowDrop = true;
this.inventoryDataGridView.AllowUserToResizeRows = false;
this.inventoryDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.inventoryDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.inventoryDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.inventoryDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.inventoryDataGridView.Location = new System.Drawing.Point(4, 5);
this.inventoryDataGridView.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.inventoryDataGridView.MultiSelect = false;
this.inventoryDataGridView.Name = "inventoryDataGridView";
this.inventoryDataGridView.Size = new System.Drawing.Size(1156, 418);
this.inventoryDataGridView.TabIndex = 0;
//
// actualSalesTabPage
//
this.actualSalesTabPage.Controls.Add(this.actualSalesDataGridView);
this.actualSalesTabPage.Location = new System.Drawing.Point(4, 29);
this.actualSalesTabPage.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.actualSalesTabPage.Name = "actualSalesTabPage";
this.actualSalesTabPage.Size = new System.Drawing.Size(1164, 428);
this.actualSalesTabPage.TabIndex = 2;
this.actualSalesTabPage.Text = "Actual Sales";
this.actualSalesTabPage.UseVisualStyleBackColor = true;
//
// actualSalesDataGridView
//
this.actualSalesDataGridView.AllowDrop = true;
this.actualSalesDataGridView.AllowUserToResizeRows = false;
this.actualSalesDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.actualSalesDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.actualSalesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.actualSalesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.actualSalesDataGridView.Location = new System.Drawing.Point(0, 0);
this.actualSalesDataGridView.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.actualSalesDataGridView.MultiSelect = false;
this.actualSalesDataGridView.Name = "actualSalesDataGridView";
this.actualSalesDataGridView.Size = new System.Drawing.Size(1164, 428);
this.actualSalesDataGridView.TabIndex = 0;
//
// invoicesTabPage
//
this.invoicesTabPage.Controls.Add(this.invoicesDataGridView);
this.invoicesTabPage.Location = new System.Drawing.Point(4, 29);
this.invoicesTabPage.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.invoicesTabPage.Name = "invoicesTabPage";
this.invoicesTabPage.Padding = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.invoicesTabPage.Size = new System.Drawing.Size(1164, 428);
this.invoicesTabPage.TabIndex = 4;
this.invoicesTabPage.Text = "Invoices";
this.invoicesTabPage.UseVisualStyleBackColor = true;
//
// invoicesDataGridView
//
this.invoicesDataGridView.AllowUserToResizeRows = false;
this.invoicesDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.invoicesDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.invoicesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.invoicesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.invoicesDataGridView.Location = new System.Drawing.Point(4, 5);
this.invoicesDataGridView.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.invoicesDataGridView.MultiSelect = false;
this.invoicesDataGridView.Name = "invoicesDataGridView";
this.invoicesDataGridView.Size = new System.Drawing.Size(1156, 418);
this.invoicesDataGridView.TabIndex = 0;
//
// weeklySalesTabPage
//
this.weeklySalesTabPage.Controls.Add(this.weeklySalesDataGridView);
this.weeklySalesTabPage.Location = new System.Drawing.Point(4, 29);
this.weeklySalesTabPage.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.weeklySalesTabPage.Name = "weeklySalesTabPage";
this.weeklySalesTabPage.Size = new System.Drawing.Size(1164, 428);
this.weeklySalesTabPage.TabIndex = 3;
this.weeklySalesTabPage.Text = "Weekly Sales";
this.weeklySalesTabPage.UseVisualStyleBackColor = true;
//
// weeklySalesDataGridView
//
this.weeklySalesDataGridView.AllowUserToAddRows = false;
this.weeklySalesDataGridView.AllowUserToDeleteRows = false;
this.weeklySalesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.weeklySalesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.weeklySalesDataGridView.Location = new System.Drawing.Point(0, 0);
this.weeklySalesDataGridView.MultiSelect = false;
this.weeklySalesDataGridView.Name = "weeklySalesDataGridView";
this.weeklySalesDataGridView.RowTemplate.Height = 28;
this.weeklySalesDataGridView.Size = new System.Drawing.Size(1164, 428);
this.weeklySalesDataGridView.TabIndex = 0;
//
// secondaryTableLayoutPanel
//
this.secondaryTableLayoutPanel.ColumnCount = 3;
this.secondaryTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.secondaryTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.secondaryTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.secondaryTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 30F));
this.secondaryTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 30F));
this.secondaryTableLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 30F));
this.secondaryTableLayoutPanel.Controls.Add(this.commentsGroupBox, 0, 0);
this.secondaryTableLayoutPanel.Controls.Add(this.dateSelectorGroupBox, 1, 0);
this.secondaryTableLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.secondaryTableLayoutPanel.Location = new System.Drawing.Point(4, 514);
this.secondaryTableLayoutPanel.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.secondaryTableLayoutPanel.Name = "secondaryTableLayoutPanel";
this.secondaryTableLayoutPanel.RowCount = 1;
this.secondaryTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.secondaryTableLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 20F));
this.secondaryTableLayoutPanel.Size = new System.Drawing.Size(1172, 193);
this.secondaryTableLayoutPanel.TabIndex = 2;
//
// commentsGroupBox
//
this.commentsGroupBox.Controls.Add(this.commentsTextBox);
this.commentsGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentsGroupBox.Location = new System.Drawing.Point(3, 3);
this.commentsGroupBox.Name = "commentsGroupBox";
this.commentsGroupBox.Size = new System.Drawing.Size(384, 187);
this.commentsGroupBox.TabIndex = 0;
this.commentsGroupBox.TabStop = false;
this.commentsGroupBox.Text = "Comments";
//
// commentsTextBox
//
this.commentsTextBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentsTextBox.Location = new System.Drawing.Point(3, 22);
this.commentsTextBox.Multiline = true;
this.commentsTextBox.Name = "commentsTextBox";
this.commentsTextBox.Size = new System.Drawing.Size(378, 162);
this.commentsTextBox.TabIndex = 0;
//
// dateSelectorGroupBox
//
this.secondaryTableLayoutPanel.SetColumnSpan(this.dateSelectorGroupBox, 2);
this.dateSelectorGroupBox.Controls.Add(this.updateRecords);
this.dateSelectorGroupBox.Controls.Add(this.notificationLabel);
this.dateSelectorGroupBox.Controls.Add(this.yearComboBox);
this.dateSelectorGroupBox.Controls.Add(this.dayComboBox);
this.dateSelectorGroupBox.Controls.Add(this.monthComboBox);
this.dateSelectorGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.dateSelectorGroupBox.Location = new System.Drawing.Point(393, 3);
this.dateSelectorGroupBox.Name = "dateSelectorGroupBox";
this.dateSelectorGroupBox.Size = new System.Drawing.Size(776, 187);
this.dateSelectorGroupBox.TabIndex = 1;
this.dateSelectorGroupBox.TabStop = false;
this.dateSelectorGroupBox.Text = "Select a date to modify:";
//
// updateRecords
//
this.updateRecords.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.updateRecords.Location = new System.Drawing.Point(598, 143);
this.updateRecords.Name = "updateRecords";
this.updateRecords.Size = new System.Drawing.Size(178, 40);
this.updateRecords.TabIndex = 2;
this.updateRecords.Text = "Update Records";
this.updateRecords.UseVisualStyleBackColor = true;
this.updateRecords.Click += new System.EventHandler(this.addRecords_Click);
//
// notificationLabel
//
this.notificationLabel.AutoSize = true;
this.notificationLabel.Location = new System.Drawing.Point(6, 105);
this.notificationLabel.Name = "notificationLabel";
this.notificationLabel.Size = new System.Drawing.Size(0, 20);
this.notificationLabel.TabIndex = 3;
//
// yearComboBox
//
this.yearComboBox.FormattingEnabled = true;
this.yearComboBox.Location = new System.Drawing.Point(256, 62);
this.yearComboBox.Name = "yearComboBox";
this.yearComboBox.Size = new System.Drawing.Size(121, 28);
this.yearComboBox.TabIndex = 2;
//
// dayComboBox
//
this.dayComboBox.FormattingEnabled = true;
this.dayComboBox.Location = new System.Drawing.Point(129, 62);
this.dayComboBox.Name = "dayComboBox";
this.dayComboBox.Size = new System.Drawing.Size(121, 28);
this.dayComboBox.TabIndex = 1;
//
// monthComboBox
//
this.monthComboBox.FormattingEnabled = true;
this.monthComboBox.Location = new System.Drawing.Point(2, 62);
this.monthComboBox.Name = "monthComboBox";
this.monthComboBox.Size = new System.Drawing.Size(121, 28);
this.monthComboBox.TabIndex = 0;
//
// FrmModifyRecord
//
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1180, 712);
this.Controls.Add(this.mainTableLayoutPanel);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.MainMenuStrip = this.mainMenu;
this.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
this.MaximumSize = new System.Drawing.Size(1332, 878);
this.MinimumSize = new System.Drawing.Size(1182, 724);
this.Name = "FrmModifyRecord";
this.Text = "Modify Existing Records";
this.Load += new System.EventHandler(this.FrmModifyRecord_Load);
this.mainTableLayoutPanel.ResumeLayout(false);
this.mainTableLayoutPanel.PerformLayout();
this.mainMenu.ResumeLayout(false);
this.mainMenu.PerformLayout();
this.mainTabControl.ResumeLayout(false);
this.projectionsTabpage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.projectionsDataGridView)).EndInit();
this.inventoryTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.inventoryDataGridView)).EndInit();
this.actualSalesTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.actualSalesDataGridView)).EndInit();
this.invoicesTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.invoicesDataGridView)).EndInit();
this.weeklySalesTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.weeklySalesDataGridView)).EndInit();
this.secondaryTableLayoutPanel.ResumeLayout(false);
this.commentsGroupBox.ResumeLayout(false);
this.commentsGroupBox.PerformLayout();
this.dateSelectorGroupBox.ResumeLayout(false);
this.dateSelectorGroupBox.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.TableLayoutPanel mainTableLayoutPanel;
private System.Windows.Forms.MenuStrip mainMenu;
private System.Windows.Forms.ToolStripMenuItem fileToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem exitToolStripMenuItem;
private System.Windows.Forms.TabControl mainTabControl;
private System.Windows.Forms.TabPage projectionsTabpage;
private System.Windows.Forms.DataGridView projectionsDataGridView;
private System.Windows.Forms.TabPage inventoryTabPage;
private System.Windows.Forms.DataGridView inventoryDataGridView;
private System.Windows.Forms.TabPage actualSalesTabPage;
private System.Windows.Forms.DataGridView actualSalesDataGridView;
private System.Windows.Forms.TabPage weeklySalesTabPage;
private System.Windows.Forms.TableLayoutPanel secondaryTableLayoutPanel;
private System.Windows.Forms.TabPage invoicesTabPage;
private System.Windows.Forms.DataGridView invoicesDataGridView;
private System.Windows.Forms.GroupBox commentsGroupBox;
private System.Windows.Forms.TextBox commentsTextBox;
private System.Windows.Forms.GroupBox dateSelectorGroupBox;
private System.Windows.Forms.ComboBox yearComboBox;
private System.Windows.Forms.ComboBox dayComboBox;
private System.Windows.Forms.ComboBox monthComboBox;
private System.Windows.Forms.ToolStripMenuItem debugToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem getAttributeToolStripMenuItem;
private System.Windows.Forms.Label notificationLabel;
private System.Windows.Forms.Button updateRecords;
private System.Windows.Forms.DataGridView weeklySalesDataGridView;
}
}
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,506 @@
using System;
using System.Windows.Forms;
using System.IO;
using System.Web.UI;
using System.Drawing;
using System.Drawing.Imaging;
using TheArtOfDev.HtmlRenderer.WinForms;
namespace AdvertsingProfitControl
{
internal class FrontPageGenerator
{
FrmLogConsole _console = FrmLogConsole.GetStaticInstance;
public void RenderHtmlToImage()
{
var htmlCode = File.ReadAllLines(Application.StartupPath + "\\FrontPage.html");
var code = "";
foreach (var line in htmlCode)
{
code = code + "\r\n" + line;
}
try
{
var imageFromHtml = HtmlRender.RenderToImage(code);
imageFromHtml.RotateFlip(RotateFlipType.Rotate90FlipNone);
imageFromHtml.Save(Application.StartupPath + "\\FrontPage.png", ImageFormat.Png);
imageFromHtml.Dispose();
}
catch (Exception e)
{
_console.WriteToLog(FrmLogConsole.Level.Critical,
"Failed to generate an updated image for the front page of Advertising Profit Control.");
_console.WriteToLog(FrmLogConsole.Level.Debug, e.Message);
_console.WriteToLog(FrmLogConsole.Level.Info,
"This is most likely a screw you from the GDI+ subsystem of Windows.");
}
}
public void BuildFormFrontCompressedLayout(string dateId, double departmentSales, double salesProducedByAdItems, double remainingSales, double totalProfitReturnFromAdItems, double totalProfitReturnFromRemainingSales, double totalProfitReturn, string comments)
{
var databaseTracker = new DatabaseTracker();
var databaseReader = new DatabaseReader();
var stringWriter = new StringWriter();
var writer = new HtmlTextWriter(stringWriter);
var table = databaseReader.ReturnApcTableForReport(dateId, databaseTracker.DatabaseConnectionString);
var dateString = databaseReader.RetrieveDateStringById(dateId, databaseTracker.DatabaseConnectionString);
var spam = dateString.Split(' ');
dateString = spam[0];
//Begin evaluating the size of the table.
var isCompressedFormat = false;
var willGenerateCommentRow = false;
if ((table.Rows.Count + 1) == 15)
{
willGenerateCommentRow = true;
}
else if ((table.Rows.Count + 1) < 15)
{
isCompressedFormat = true;
}
writer.Write("<!DOCTYPE html>\n");
writer.RenderBeginTag(HtmlTextWriterTag.Html);
writer.RenderBeginTag(HtmlTextWriterTag.Head);
writer.AddAttribute(HtmlTextWriterAttribute.Type, "text/css");
writer.RenderBeginTag(HtmlTextWriterTag.Style);
writer.Write("th{margins:0; padding:0; vertical-align:bottom; height:35px; font-size:14px; border:1px solid black}");
writer.Write("td{margins:0; padding:0; border:1px solid black; font-size:14px; text-align:center; height:35px}");
writer.RenderEndTag();//style
writer.RenderEndTag(); // Head
writer.AddAttribute(HtmlTextWriterAttribute.Style, "width:11in; height:8in");
writer.RenderBeginTag(HtmlTextWriterTag.Body);
//Begin building the header for the page, the HTML engine doesn't seem to like putting content in the Head.
writer.AddAttribute(HtmlTextWriterAttribute.Style, "margin-top:200px; width:100%");
writer.RenderBeginTag(HtmlTextWriterTag.Table);
writer.AddAttribute(HtmlTextWriterAttribute.Style, "margin:0px; padding:0px");
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
writer.AddAttribute(HtmlTextWriterAttribute.Style, "font-size:14px; width:20%; vertical-align:bottom; border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<p>Store Name:<u> Allen's of Hastings</u></p>");
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "width:50%; font-size:15px; margin:0px; padding: 0px 0px 0px 0px; border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td); // <br><p style=\"font-size:10px\">(Mode: " + (willGenerateCommentRow ? "Generates Comment row" : "Compressed Format") + ")
writer.Write("<p><center><h2>Advertising Profit Control v " + Application.ProductVersion + "</h2></center></p>");
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "width:33%; padding: 0px 0px 0px 0px; margin:0px; border:none; vertical-align:bottom");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<p><span style=\"margin-left:102px\">Week Ending: <u>" + dateString + "</u></span><br><span style=\"margin-left:86px\">Department: <u>Produce</u></span></p>");
writer.RenderEndTag();//td
writer.RenderEndTag();//tr
writer.AddAttribute(HtmlTextWriterAttribute.Style, "margin:0px; padding:0px");
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<p><span style=\"margin-right:280px\">Projection</span><span>Actual</span></p>");
writer.RenderEndTag();//td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<p style=\"margin-left:150px\">Profit Analysis</p>");
writer.RenderEndTag();//td
writer.RenderEndTag();//tr
writer.RenderEndTag();//table
//END of header table structure
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-collapse: collapse; width:11in; height:7.0in; table-layout:fixed"); //style for the table
writer.RenderBeginTag(HtmlTextWriterTag.Table);
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
//Begin building the header row.
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-left:none");
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Ad Items");
writer.RenderEndTag(); //th
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9");
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Sold");
writer.RenderEndTag(); //th
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9");
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Sale<br>Price");
writer.RenderEndTag(); //th
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9");
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Total<br>Sales");
writer.RenderEndTag(); //th
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9");
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Cost");
writer.RenderEndTag(); //th
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9");
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("$<br>Prof.<br>Retn.");
writer.RenderEndTag(); //th
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9");
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Total<br>$<br>Prof.<br>Retn.");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Beg.<br>Inv.");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Rec'd");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Total");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("End.<br>Inv.");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Sold");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Sale<br>Price");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Total<br>Sales");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Cost");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("$<br>Prof.<br>Retn.");
writer.RenderEndTag(); //th
writer.RenderBeginTag(HtmlTextWriterTag.Th);
writer.Write("Total<br>$<br>Prof.<br>Retn.");
writer.RenderEndTag(); //th
//Department Sales
writer.AddAttribute(HtmlTextWriterAttribute.Style, "width:159px; border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center>Department<br>Sales</center><p><span style=\"font-size:9px; vertical-align:bottom\">1</span><span style=\"margin-left:60px\">"+ $"{departmentSales:C}" + "</span></p>");
writer.RenderEndTag();//td
writer.RenderEndTag();//End of header row code.
var isRowMember = false;
var isRenderingGroup = false;
var adSpecialRowIndex = -1;
//Variables for the Totals row.
double projectionProfitReturn = 0;
double projectionTotalProfitReturn = 0;
double actualProfitReturn = 0;
double actualTotalProfitReturn = 0;
var adSpecialOffset = 0;
//Profit Analysis values.
for (var rowIndex = 0; rowIndex < (table.Rows.Count < 19 ? 19 : table.Rows.Count); rowIndex++) //The comparison in the for loop is index based, so no need to add one to the row count.
{
var isProfitAnalysisCell = false;
//IF the row index goes beyond the number of rows that are in the table, then start padding with blank cells to fit the Profit Analysis cells.
if (rowIndex < table.Rows.Count)
{
var row = table.Rows[rowIndex];
var rowAttribute = 0;
var groupId = 0;
if (int.TryParse(row.ItemArray[17].ToString(), out rowAttribute))
{
if (rowAttribute != 0)
{
if (rowAttribute == 1)
{
isRowMember = false;
}
else
{
isRowMember = true;
}
isRenderingGroup = true;
}
else
{
isRenderingGroup = false;
isRowMember = false;
}
}
if (adSpecialRowIndex == -1 && int.TryParse(row.ItemArray[18].ToString(), out groupId))
{
if (groupId != 0)
{
adSpecialRowIndex = rowIndex;
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "17");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-left:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center>" +
databaseReader.ReturnGroupNameFromGroupId(groupId.ToString(),
databaseTracker.DatabaseConnectionString) + "</center>");
writer.RenderEndTag(); //td
writer.RenderEndTag(); //tr
BuildProfitAnalysisCell(ref writer, rowIndex, out isProfitAnalysisCell, salesProducedByAdItems, remainingSales, totalProfitReturnFromAdItems, totalProfitReturnFromRemainingSales, totalProfitReturn);
adSpecialOffset++;
}
}
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
for (var i = 0; i < row.ItemArray.Length; i++)
{
if (i >= 17) continue;
if (i == 0)
{
writer.AddStyleAttribute(HtmlTextWriterStyle.TextAlign, "left");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-left:none");
}
else if (i > 0 && i < 7)
{
//background-color:#e9e9e9
writer.AddStyleAttribute(HtmlTextWriterStyle.BackgroundColor, "#e9e9e9");
}
writer.RenderBeginTag(HtmlTextWriterTag.Td);
decimal number;
if (decimal.TryParse(row.ItemArray[i].ToString(), out number))
{
//Check for the inventory columns and the sold columns.
if (!isRowMember)
{
if (i == 1 || i > 6 && i < 12)
{
writer.Write(number == 0 ? "0" : row.ItemArray[i].ToString());
}
if (i > 1 && i < 7 || i > 11)
{
writer.Write(number == 0 ? "0.00" : $"{number:N}");
}
}
switch (i)
{
case 3:
projectionProfitReturn += double.Parse(row.ItemArray[3].ToString());
break;
case 6:
projectionTotalProfitReturn += double.Parse(row.ItemArray[6].ToString());
break;
case 13:
actualProfitReturn += double.Parse(row.ItemArray[13].ToString());
break;
case 16:
actualTotalProfitReturn += double.Parse(row.ItemArray[16].ToString());
break;
}
}
else
{
writer.Write(row.ItemArray[i]);
}
writer.RenderEndTag(); //td
}
}
else
{
//Padding
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
//Generate padding rows to fit the Profit Analysis cells properly onto the sheet.
//Check to see if the row index is equal to the number of rows in the table.
if (rowIndex == table.Rows.Count)
{
//IF so, then that means the current row index represents the index of the Totals row. So build the totals row with the added values from above.
//Begin rendering the totals row.
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:1px solid black; border-left:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9; text-align:right");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Total");
writer.RenderEndTag(); //td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9; padding: 0px 0px 0px 5px");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("(A) " + $"{projectionProfitReturn:C}");
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9; padding: 0px 0px 0px 5px");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("(B) " + $"{projectionTotalProfitReturn:C}");
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "text-align:right");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "5");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Total");
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "padding: 0px 0px 0px 5px");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("(A) " + $"{actualProfitReturn:C}");
writer.RenderEndTag();
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "padding: 0px 0px 0px 5px");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("(B) " + $"{actualTotalProfitReturn:C}");
writer.RenderEndTag();//td
//END rending the totals row.
BuildProfitAnalysisCell(ref writer, rowIndex + adSpecialOffset, out isProfitAnalysisCell, salesProducedByAdItems, remainingSales, totalProfitReturnFromAdItems, totalProfitReturnFromRemainingSales, totalProfitReturn);
}
else if (rowIndex == (table.Rows.Count + 1))
//Check to see if the current index is equal to the row after the totals row and, if so, create the comments row.
{
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "17");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-left:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write(
"<b>Comments:</b> " + comments);
writer.RenderEndTag(); //td
BuildProfitAnalysisCell(ref writer, rowIndex + adSpecialOffset, out isProfitAnalysisCell, salesProducedByAdItems, remainingSales, totalProfitReturnFromAdItems, totalProfitReturnFromRemainingSales, totalProfitReturn);
}
else
{
var cellCount = 0;
while (cellCount < 17)
{
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();//td
cellCount++;
}
}
}
//Check for every 3rd row to append a Profit Analysis cell onto.
switch (rowIndex + adSpecialOffset)
{
case 0:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:1px\">Sales Produced By<br>Ad Items (A)</center><p><span style=\"font-size:9px; vertical-align:bottom\">2</span><span style=\"margin-left:60px\">" + $"{salesProducedByAdItems:C}" + "</span></p>");
writer.RenderEndTag();
break;
case 3:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-top:1px solid black; border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:1px\">Remaining<br>Sales</center><p><span style=\"font-size:9px; vertical-align:bottom\">3</span><span style=\"margin-left:60px\">" + $"{remainingSales:C}" + " </span></p>");
writer.RenderEndTag();
break;
case 6:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-top:1px solid black; border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:1px;\">Total $ Profit Return<br>From Ad Items (B)</center><p><span style=\"font-size:9px; vertical-align:bottom\">4</span><span style=\"margin-left:60px\">" + $"{totalProfitReturnFromAdItems:C}" + " </span></p>");
writer.RenderEndTag();
break;
case 9:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-top:1px solid black; border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:2px\">Total $ Profit Return<br>From Remaining Sales</center><p><span style=\"font-size:9px; vertical-align:bottom\">5</span><span style=\"margin-left:60px\">" + $"{totalProfitReturnFromRemainingSales:C}" + "</span></p>");
writer.RenderEndTag();
break;
case 12:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:1px\">Total $ Profit<br>Return</center><p><span style=\"font-size:9px; vertical-align:bottom\">6</span><span style=\"margin-left:60px\">" + $"{totalProfitReturn:C}" + "</span></p>");
writer.RenderEndTag();
break;
case 15:
//IF either the compressed format or the generate comment row flags are set, then ignore this case. Only tables with 19 or more rows can generate a full comments cell due to the amount of text it can contain.
if (isCompressedFormat || willGenerateCommentRow) break;
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "4");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Comments: " + comments);
writer.RenderEndTag();
break;
}
writer.RenderEndTag();//tr
}//end for loop
if (!willGenerateCommentRow && !isCompressedFormat)
{
//Begin rendering the totals row.
writer.RenderBeginTag(HtmlTextWriterTag.Tr);
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:1px solid black; border-left:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9; border:1px solid black; font-size:12px; border-left: 1px solid #000; text-align:right");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Total");
writer.RenderEndTag(); //td
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9; border:1px solid black; font-size:12px; border-left: 1px solid #000; padding: 0px 0px 0px 5px");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("(A) " + $"{projectionProfitReturn:C}");
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "background-color:#e9e9e9; border:1px solid black; font-size:12px; border-left: 1px solid #000; padding: 0px 0px 0px 5px");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("(B) " + $"{projectionTotalProfitReturn:C}");
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:1px solid black; font-size:12px; border-left: 1px solid #000; text-align:right");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "5");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("Total");
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:1px solid black; font-size:12px; border-left: 1px solid #000; padding: 0px 0px 0px 5px");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("(A) " + $"{actualProfitReturn:C}");
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:1px solid black");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.RenderEndTag();
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:1px solid black; font-size:12px; border-left: 1px solid #000; padding: 0px 0px 0px 5px");
writer.AddAttribute(HtmlTextWriterAttribute.Colspan, "2");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("(B) " + $"{actualTotalProfitReturn:C}");
writer.RenderEndTag();//td
writer.RenderEndTag(); //tr
}
writer.RenderEndTag();//table
writer.RenderEndTag();//body
writer.RenderEndTag();//HTML
using (var streamWriter = new StreamWriter(Application.StartupPath + "\\FrontPage.html"))
{
streamWriter.WriteLine(stringWriter.ToString());
}
RenderHtmlToImage();
}
private void BuildProfitAnalysisCell(ref HtmlTextWriter writer, int rowIndex, out bool isProfitAnalysisCell, double salesProducedByAdItems, double remainingSales, double totalProfitReturnFromAdItems, double totalProfitReturnFromRemainingSales, double totalProfitReturn)
{
isProfitAnalysisCell = false;
switch (rowIndex)
{
case 0:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-right:1px solid black; border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:1px\">Sales Produced By<br>Ad Items (A)</center><p><span style=\"font-size:9px; vertical-align:bottom\">2</span><span style=\"margin-left:60px\">" + $"{salesProducedByAdItems:C}" + "</span></p>");
writer.RenderEndTag();
break;
case 3:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-right:1px solid black; border-top:1px solid black; border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:1px\">Remaining<br>Sales</center><p><span style=\"font-size:9px; vertical-align:bottom\">3</span><span style=\"margin-left:60px\">" + $"{remainingSales:C}" + " </span></p>");
writer.RenderEndTag();
break;
case 6:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-right:1px solid black; border-top:1px solid black; border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:1px;\">Total $ Profit Return<br>From Ad Items (B)</center><p><span style=\"font-size:9px; vertical-align:bottom\">4</span><span style=\"margin-left:60px\">" + $"{totalProfitReturnFromAdItems:C}" + " </span></p>");
writer.RenderEndTag();
break;
case 9:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border:none; border-right:1px solid black; border-top:1px solid black; border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:2px\">Total $ Profit Return<br>From Remaining Sales</center><p><span style=\"font-size:9px; vertical-align:bottom\">5</span><span style=\"margin-left:60px\">" + $"{totalProfitReturnFromRemainingSales:C}" + "</span></p>");
writer.RenderEndTag();
break;
case 12:
writer.AddAttribute(HtmlTextWriterAttribute.Rowspan, "2");
writer.AddAttribute(HtmlTextWriterAttribute.Style, "border-right:none");
writer.RenderBeginTag(HtmlTextWriterTag.Td);
writer.Write("<center style=\"margin-top:1px\">Total $ Profit<br>Return</center><p><span style=\"font-size:9px; vertical-align:bottom\">6</span><span style=\"margin-left:60px\">" + $"{totalProfitReturn:C}" + "</span></p>");
writer.RenderEndTag();
break;
}
}
}
}
+50
View File
@@ -0,0 +1,50 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
class GlobalClasses
{
public static void LogError(object sender, System.Threading.ThreadExceptionEventArgs e)
{
using (
StreamWriter file =
new StreamWriter(@"C:\Users\" + Environment.UserName + @"\AppData\Local\APC\" + DateTime.Now.ToString("MM-dd-yyyy") + ".log", true))
{
file.WriteLine(DateTime.Now + ": Unhandled Thread Exception:\n" + e.Exception.Message + "\n" + e.Exception.StackTrace);
MessageBox.Show("An unhandled thread exception has occurred. Advertising Profit Control will be forced to exit.",
"Fatal Error");
Application.Exit();
}
}
public static void LogError(object sender, UnhandledExceptionEventArgs e)
{
using (
StreamWriter file =
new StreamWriter(@"C:\Users\" + Environment.UserName + @"\AppData\Local\APC\" + DateTime.Now.ToString("MM-dd-yyyy") + ".log", true))
{
file.WriteLine(DateTime.Now + ": An unhandled exception occurred. \nException Object: " + e.ExceptionObject);
MessageBox.Show("And unknown error has occurred. Advertising Profit Control will be forced to exit.",
"Fatal Error");
Application.Exit();
}
}
public static void WriteToLog(string message)
{
using (
StreamWriter file =
new StreamWriter(@"C:\Users\" + Environment.UserName + @"\AppData\Local\APC\Information.log", true))
{
file.WriteLine(message);
}
}
}
}
+986
View File
@@ -0,0 +1,986 @@
namespace AdvertsingProfitControl
{
partial class NewAddRecord
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(NewAddRecord));
this.commentsGroupBox = new System.Windows.Forms.GroupBox();
this.commentsTextBox = new System.Windows.Forms.TextBox();
this.mainTabControl = new System.Windows.Forms.TabControl();
this.projectionTabPage = new System.Windows.Forms.TabPage();
this.projectionsDataGridView = new System.Windows.Forms.DataGridView();
this.inventoryTabPage = new System.Windows.Forms.TabPage();
this.inventoryDataGridView = new System.Windows.Forms.DataGridView();
this.actualSalesTabPage = new System.Windows.Forms.TabPage();
this.actualSalesDataGridView = new System.Windows.Forms.DataGridView();
this.invoicesTabPage = new System.Windows.Forms.TabPage();
this.invoicesDataGridView = new System.Windows.Forms.DataGridView();
this.debugTabPage = new System.Windows.Forms.TabPage();
this.mainMenuStrip = new System.Windows.Forms.MenuStrip();
this.FileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.exitFileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.debugMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.getCellValueDebugMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.mainLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.costAnalysisGroupBox = new System.Windows.Forms.GroupBox();
this.suppliesTextBox = new System.Windows.Forms.TextBox();
this.salaryPercentageTextBox = new System.Windows.Forms.TextBox();
this.salaryDollarsTextBox = new System.Windows.Forms.TextBox();
this.salesPerManHourLabel = new System.Windows.Forms.Label();
this.salaryPercentageLabel = new System.Windows.Forms.Label();
this.salesPerManHourTextBox = new System.Windows.Forms.TextBox();
this.salaryDollarsLabel = new System.Windows.Forms.Label();
this.suppliesLabel = new System.Windows.Forms.Label();
this.tabControl1 = new System.Windows.Forms.TabControl();
this.weeklySalesTabPage = new System.Windows.Forms.TabPage();
this.mondayWeeklySalesTextBox = new System.Windows.Forms.TextBox();
this.totalWeeklySalesTextBox = new System.Windows.Forms.TextBox();
this.saturdayWeeklySalesTextBox = new System.Windows.Forms.TextBox();
this.thursdayWeeklySalesTextBox = new System.Windows.Forms.TextBox();
this.tuesdayWeeklySalesTextBox = new System.Windows.Forms.TextBox();
this.mondayWeeklySalesLabel = new System.Windows.Forms.Label();
this.thursdayWeeklySalesLabel = new System.Windows.Forms.Label();
this.saturdayWeeklySalesLabel = new System.Windows.Forms.Label();
this.sundayWeeklySalesTextBox = new System.Windows.Forms.TextBox();
this.totalWeeklySalesLabel = new System.Windows.Forms.Label();
this.fridayWeeklySalesLabel = new System.Windows.Forms.Label();
this.wednesdayWeeklySalesLabel = new System.Windows.Forms.Label();
this.tuesdayWeeklySalesLabel = new System.Windows.Forms.Label();
this.fridayWeeklySalesTextBox = new System.Windows.Forms.TextBox();
this.sundayWeeklySalesLabel = new System.Windows.Forms.Label();
this.wednesdayWeeklySalesTextBox = new System.Windows.Forms.TextBox();
this.taxableTabPage = new System.Windows.Forms.TabPage();
this.totalTaxableTextBox = new System.Windows.Forms.TextBox();
this.mondayTaxableTextBox = new System.Windows.Forms.TextBox();
this.thursdayTaxableTextBox = new System.Windows.Forms.TextBox();
this.tuesdayTaxableTextBox = new System.Windows.Forms.TextBox();
this.fridayTaxableLabel = new System.Windows.Forms.Label();
this.sundayTaxableLabel = new System.Windows.Forms.Label();
this.thursdayTaxableLabel = new System.Windows.Forms.Label();
this.wednesdayTaxableTextBox = new System.Windows.Forms.TextBox();
this.fridayTaxableTextBox = new System.Windows.Forms.TextBox();
this.mondayTaxableLabel = new System.Windows.Forms.Label();
this.wednesdayTaxableLabel = new System.Windows.Forms.Label();
this.totalTaxableLabel = new System.Windows.Forms.Label();
this.saturdayTaxableLabel = new System.Windows.Forms.Label();
this.sundayTaxableTextBox = new System.Windows.Forms.TextBox();
this.tuesdayTaxableLabel = new System.Windows.Forms.Label();
this.saturdayTaxableTextBox = new System.Windows.Forms.TextBox();
this.dateGroupBox = new System.Windows.Forms.GroupBox();
this.monthCalendarInstructionsLabel = new System.Windows.Forms.Label();
this.weekEndingMonthCalendar = new System.Windows.Forms.MonthCalendar();
this.dateTimeMaskedTextBoxPanel = new System.Windows.Forms.Panel();
this.errorLabel = new System.Windows.Forms.Label();
this.weekEndingMaskedTextBox = new System.Windows.Forms.MaskedTextBox();
this.weekEndingMaskedTextBoxInstructionLabel = new System.Windows.Forms.Label();
this.informationPanel = new System.Windows.Forms.Panel();
this.informationLabel = new System.Windows.Forms.Label();
this.addRecordButton = new System.Windows.Forms.Button();
this.commentsGroupBox.SuspendLayout();
this.mainTabControl.SuspendLayout();
this.projectionTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.projectionsDataGridView)).BeginInit();
this.inventoryTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.inventoryDataGridView)).BeginInit();
this.actualSalesTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.actualSalesDataGridView)).BeginInit();
this.invoicesTabPage.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.invoicesDataGridView)).BeginInit();
this.mainMenuStrip.SuspendLayout();
this.mainLayoutPanel.SuspendLayout();
this.costAnalysisGroupBox.SuspendLayout();
this.tabControl1.SuspendLayout();
this.weeklySalesTabPage.SuspendLayout();
this.taxableTabPage.SuspendLayout();
this.dateGroupBox.SuspendLayout();
this.dateTimeMaskedTextBoxPanel.SuspendLayout();
this.informationPanel.SuspendLayout();
this.SuspendLayout();
//
// commentsGroupBox
//
this.commentsGroupBox.Controls.Add(this.commentsTextBox);
this.commentsGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentsGroupBox.Location = new System.Drawing.Point(423, 594);
this.commentsGroupBox.Margin = new System.Windows.Forms.Padding(4);
this.commentsGroupBox.Name = "commentsGroupBox";
this.commentsGroupBox.Padding = new System.Windows.Forms.Padding(4);
this.commentsGroupBox.Size = new System.Drawing.Size(411, 223);
this.commentsGroupBox.TabIndex = 2;
this.commentsGroupBox.TabStop = false;
this.commentsGroupBox.Text = "Comments";
//
// commentsTextBox
//
this.commentsTextBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.commentsTextBox.Location = new System.Drawing.Point(4, 26);
this.commentsTextBox.MaxLength = 256;
this.commentsTextBox.Multiline = true;
this.commentsTextBox.Name = "commentsTextBox";
this.commentsTextBox.Size = new System.Drawing.Size(403, 193);
this.commentsTextBox.TabIndex = 4;
//
// mainTabControl
//
this.mainLayoutPanel.SetColumnSpan(this.mainTabControl, 4);
this.mainTabControl.Controls.Add(this.projectionTabPage);
this.mainTabControl.Controls.Add(this.inventoryTabPage);
this.mainTabControl.Controls.Add(this.actualSalesTabPage);
this.mainTabControl.Controls.Add(this.invoicesTabPage);
this.mainTabControl.Controls.Add(this.debugTabPage);
this.mainTabControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainTabControl.Location = new System.Drawing.Point(4, 39);
this.mainTabControl.Margin = new System.Windows.Forms.Padding(4);
this.mainTabControl.Name = "mainTabControl";
this.mainTabControl.SelectedIndex = 0;
this.mainTabControl.Size = new System.Drawing.Size(1668, 547);
this.mainTabControl.TabIndex = 1;
this.mainTabControl.TabStop = false;
//
// projectionTabPage
//
this.projectionTabPage.Controls.Add(this.projectionsDataGridView);
this.projectionTabPage.Location = new System.Drawing.Point(4, 33);
this.projectionTabPage.Margin = new System.Windows.Forms.Padding(4);
this.projectionTabPage.Name = "projectionTabPage";
this.projectionTabPage.Size = new System.Drawing.Size(1660, 510);
this.projectionTabPage.TabIndex = 0;
this.projectionTabPage.Text = "Projected Sales";
this.projectionTabPage.UseVisualStyleBackColor = true;
//
// projectionsDataGridView
//
this.projectionsDataGridView.AllowDrop = true;
this.projectionsDataGridView.AllowUserToResizeRows = false;
this.projectionsDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.projectionsDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.projectionsDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.projectionsDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.projectionsDataGridView.Location = new System.Drawing.Point(0, 0);
this.projectionsDataGridView.Margin = new System.Windows.Forms.Padding(4);
this.projectionsDataGridView.MultiSelect = false;
this.projectionsDataGridView.Name = "projectionsDataGridView";
this.projectionsDataGridView.RowTemplate.Height = 28;
this.projectionsDataGridView.Size = new System.Drawing.Size(1660, 510);
this.projectionsDataGridView.TabIndex = 2;
//
// inventoryTabPage
//
this.inventoryTabPage.Controls.Add(this.inventoryDataGridView);
this.inventoryTabPage.Location = new System.Drawing.Point(4, 33);
this.inventoryTabPage.Margin = new System.Windows.Forms.Padding(4);
this.inventoryTabPage.Name = "inventoryTabPage";
this.inventoryTabPage.Size = new System.Drawing.Size(1660, 510);
this.inventoryTabPage.TabIndex = 1;
this.inventoryTabPage.Text = "Inventory";
this.inventoryTabPage.UseVisualStyleBackColor = true;
//
// inventoryDataGridView
//
this.inventoryDataGridView.AllowDrop = true;
this.inventoryDataGridView.AllowUserToResizeRows = false;
this.inventoryDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.inventoryDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.inventoryDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.inventoryDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.inventoryDataGridView.Location = new System.Drawing.Point(0, 0);
this.inventoryDataGridView.Margin = new System.Windows.Forms.Padding(4);
this.inventoryDataGridView.MultiSelect = false;
this.inventoryDataGridView.Name = "inventoryDataGridView";
this.inventoryDataGridView.RowTemplate.Height = 28;
this.inventoryDataGridView.Size = new System.Drawing.Size(1660, 510);
this.inventoryDataGridView.TabIndex = 1;
//
// actualSalesTabPage
//
this.actualSalesTabPage.Controls.Add(this.actualSalesDataGridView);
this.actualSalesTabPage.Location = new System.Drawing.Point(4, 33);
this.actualSalesTabPage.Margin = new System.Windows.Forms.Padding(4);
this.actualSalesTabPage.Name = "actualSalesTabPage";
this.actualSalesTabPage.Size = new System.Drawing.Size(1660, 510);
this.actualSalesTabPage.TabIndex = 2;
this.actualSalesTabPage.Text = "Actual Sales";
this.actualSalesTabPage.UseVisualStyleBackColor = true;
//
// actualSalesDataGridView
//
this.actualSalesDataGridView.AllowDrop = true;
this.actualSalesDataGridView.AllowUserToResizeRows = false;
this.actualSalesDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.actualSalesDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.actualSalesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.actualSalesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.actualSalesDataGridView.Location = new System.Drawing.Point(0, 0);
this.actualSalesDataGridView.Margin = new System.Windows.Forms.Padding(4);
this.actualSalesDataGridView.MultiSelect = false;
this.actualSalesDataGridView.Name = "actualSalesDataGridView";
this.actualSalesDataGridView.RowTemplate.Height = 28;
this.actualSalesDataGridView.Size = new System.Drawing.Size(1660, 510);
this.actualSalesDataGridView.TabIndex = 1;
//
// invoicesTabPage
//
this.invoicesTabPage.Controls.Add(this.invoicesDataGridView);
this.invoicesTabPage.Location = new System.Drawing.Point(4, 33);
this.invoicesTabPage.Margin = new System.Windows.Forms.Padding(4);
this.invoicesTabPage.Name = "invoicesTabPage";
this.invoicesTabPage.Size = new System.Drawing.Size(1660, 510);
this.invoicesTabPage.TabIndex = 3;
this.invoicesTabPage.Text = "Invoices";
this.invoicesTabPage.UseVisualStyleBackColor = true;
//
// invoicesDataGridView
//
this.invoicesDataGridView.AllowDrop = true;
this.invoicesDataGridView.AllowUserToResizeRows = false;
this.invoicesDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.invoicesDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.invoicesDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.invoicesDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.invoicesDataGridView.Location = new System.Drawing.Point(0, 0);
this.invoicesDataGridView.Margin = new System.Windows.Forms.Padding(4);
this.invoicesDataGridView.MultiSelect = false;
this.invoicesDataGridView.Name = "invoicesDataGridView";
this.invoicesDataGridView.RowTemplate.Height = 28;
this.invoicesDataGridView.Size = new System.Drawing.Size(1660, 510);
this.invoicesDataGridView.TabIndex = 1;
//
// debugTabPage
//
this.debugTabPage.Location = new System.Drawing.Point(4, 33);
this.debugTabPage.Name = "debugTabPage";
this.debugTabPage.Padding = new System.Windows.Forms.Padding(3);
this.debugTabPage.Size = new System.Drawing.Size(1660, 510);
this.debugTabPage.TabIndex = 4;
this.debugTabPage.Text = "DEBUG";
this.debugTabPage.UseVisualStyleBackColor = true;
//
// mainMenuStrip
//
this.mainLayoutPanel.SetColumnSpan(this.mainMenuStrip, 4);
this.mainMenuStrip.ImageScalingSize = new System.Drawing.Size(24, 24);
this.mainMenuStrip.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.FileMainMenu,
this.debugMainMenu});
this.mainMenuStrip.Location = new System.Drawing.Point(0, 0);
this.mainMenuStrip.Name = "mainMenuStrip";
this.mainMenuStrip.Padding = new System.Windows.Forms.Padding(7, 2, 0, 2);
this.mainMenuStrip.Size = new System.Drawing.Size(1676, 35);
this.mainMenuStrip.TabIndex = 0;
this.mainMenuStrip.Text = "menuStrip1";
//
// FileMainMenu
//
this.FileMainMenu.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.exitFileMainMenu});
this.FileMainMenu.Name = "FileMainMenu";
this.FileMainMenu.Size = new System.Drawing.Size(56, 31);
this.FileMainMenu.Text = "&File";
//
// exitFileMainMenu
//
this.exitFileMainMenu.Name = "exitFileMainMenu";
this.exitFileMainMenu.Size = new System.Drawing.Size(138, 34);
this.exitFileMainMenu.Text = "E&xit";
//
// debugMainMenu
//
this.debugMainMenu.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.getCellValueDebugMainMenu});
this.debugMainMenu.Name = "debugMainMenu";
this.debugMainMenu.Size = new System.Drawing.Size(87, 31);
this.debugMainMenu.Text = "Debug";
//
// getCellValueDebugMainMenu
//
this.getCellValueDebugMainMenu.Name = "getCellValueDebugMainMenu";
this.getCellValueDebugMainMenu.Size = new System.Drawing.Size(233, 34);
this.getCellValueDebugMainMenu.Text = "Get Cell Value";
this.getCellValueDebugMainMenu.Click += new System.EventHandler(this.getCellValueDebugMainMenu_Click);
//
// mainLayoutPanel
//
this.mainLayoutPanel.ColumnCount = 4;
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.mainLayoutPanel.Controls.Add(this.mainMenuStrip, 0, 0);
this.mainLayoutPanel.Controls.Add(this.mainTabControl, 0, 1);
this.mainLayoutPanel.Controls.Add(this.costAnalysisGroupBox, 3, 2);
this.mainLayoutPanel.Controls.Add(this.tabControl1, 2, 2);
this.mainLayoutPanel.Controls.Add(this.commentsGroupBox, 1, 2);
this.mainLayoutPanel.Controls.Add(this.dateGroupBox, 0, 2);
this.mainLayoutPanel.Controls.Add(this.dateTimeMaskedTextBoxPanel, 1, 3);
this.mainLayoutPanel.Controls.Add(this.informationPanel, 3, 3);
this.mainLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainLayoutPanel.Location = new System.Drawing.Point(0, 0);
this.mainLayoutPanel.Margin = new System.Windows.Forms.Padding(4);
this.mainLayoutPanel.Name = "mainLayoutPanel";
this.mainLayoutPanel.RowCount = 4;
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 35F));
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 60F));
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 15F));
this.mainLayoutPanel.Size = new System.Drawing.Size(1676, 961);
this.mainLayoutPanel.TabIndex = 0;
//
// costAnalysisGroupBox
//
this.costAnalysisGroupBox.Controls.Add(this.suppliesTextBox);
this.costAnalysisGroupBox.Controls.Add(this.salaryPercentageTextBox);
this.costAnalysisGroupBox.Controls.Add(this.salaryDollarsTextBox);
this.costAnalysisGroupBox.Controls.Add(this.salesPerManHourLabel);
this.costAnalysisGroupBox.Controls.Add(this.salaryPercentageLabel);
this.costAnalysisGroupBox.Controls.Add(this.salesPerManHourTextBox);
this.costAnalysisGroupBox.Controls.Add(this.salaryDollarsLabel);
this.costAnalysisGroupBox.Controls.Add(this.suppliesLabel);
this.costAnalysisGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.costAnalysisGroupBox.Location = new System.Drawing.Point(1260, 593);
this.costAnalysisGroupBox.Name = "costAnalysisGroupBox";
this.costAnalysisGroupBox.Size = new System.Drawing.Size(413, 225);
this.costAnalysisGroupBox.TabIndex = 6;
this.costAnalysisGroupBox.TabStop = false;
this.costAnalysisGroupBox.Text = "Cost Analysis";
//
// suppliesTextBox
//
this.suppliesTextBox.Location = new System.Drawing.Point(205, 185);
this.suppliesTextBox.Name = "suppliesTextBox";
this.suppliesTextBox.Size = new System.Drawing.Size(199, 29);
this.suppliesTextBox.TabIndex = 25;
//
// salaryPercentageTextBox
//
this.salaryPercentageTextBox.Location = new System.Drawing.Point(205, 87);
this.salaryPercentageTextBox.Name = "salaryPercentageTextBox";
this.salaryPercentageTextBox.Size = new System.Drawing.Size(199, 29);
this.salaryPercentageTextBox.TabIndex = 23;
//
// salaryDollarsTextBox
//
this.salaryDollarsTextBox.Location = new System.Drawing.Point(205, 136);
this.salaryDollarsTextBox.Name = "salaryDollarsTextBox";
this.salaryDollarsTextBox.Size = new System.Drawing.Size(199, 29);
this.salaryDollarsTextBox.TabIndex = 24;
//
// salesPerManHourLabel
//
this.salesPerManHourLabel.AutoSize = true;
this.salesPerManHourLabel.Location = new System.Drawing.Point(5, 38);
this.salesPerManHourLabel.Name = "salesPerManHourLabel";
this.salesPerManHourLabel.Size = new System.Drawing.Size(194, 25);
this.salesPerManHourLabel.TabIndex = 0;
this.salesPerManHourLabel.Text = "Sales Per Man Hour:";
//
// salaryPercentageLabel
//
this.salaryPercentageLabel.AutoSize = true;
this.salaryPercentageLabel.Location = new System.Drawing.Point(20, 87);
this.salaryPercentageLabel.Name = "salaryPercentageLabel";
this.salaryPercentageLabel.Size = new System.Drawing.Size(179, 25);
this.salaryPercentageLabel.TabIndex = 1;
this.salaryPercentageLabel.Text = "Salary Percentage:";
//
// salesPerManHourTextBox
//
this.salesPerManHourTextBox.Location = new System.Drawing.Point(205, 38);
this.salesPerManHourTextBox.Name = "salesPerManHourTextBox";
this.salesPerManHourTextBox.Size = new System.Drawing.Size(199, 29);
this.salesPerManHourTextBox.TabIndex = 22;
//
// salaryDollarsLabel
//
this.salaryDollarsLabel.AutoSize = true;
this.salaryDollarsLabel.Location = new System.Drawing.Point(60, 136);
this.salaryDollarsLabel.Name = "salaryDollarsLabel";
this.salaryDollarsLabel.Size = new System.Drawing.Size(139, 25);
this.salaryDollarsLabel.TabIndex = 2;
this.salaryDollarsLabel.Text = "Salary Dollars:";
//
// suppliesLabel
//
this.suppliesLabel.AutoSize = true;
this.suppliesLabel.Location = new System.Drawing.Point(105, 185);
this.suppliesLabel.Name = "suppliesLabel";
this.suppliesLabel.Size = new System.Drawing.Size(94, 25);
this.suppliesLabel.TabIndex = 3;
this.suppliesLabel.Text = "Supplies:";
//
// tabControl1
//
this.tabControl1.Controls.Add(this.weeklySalesTabPage);
this.tabControl1.Controls.Add(this.taxableTabPage);
this.tabControl1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tabControl1.Location = new System.Drawing.Point(838, 590);
this.tabControl1.Margin = new System.Windows.Forms.Padding(0);
this.tabControl1.Multiline = true;
this.tabControl1.Name = "tabControl1";
this.tabControl1.Padding = new System.Drawing.Point(0, 0);
this.mainLayoutPanel.SetRowSpan(this.tabControl1, 2);
this.tabControl1.SelectedIndex = 0;
this.tabControl1.Size = new System.Drawing.Size(419, 371);
this.tabControl1.TabIndex = 5;
//
// weeklySalesTabPage
//
this.weeklySalesTabPage.BackColor = System.Drawing.SystemColors.ControlLight;
this.weeklySalesTabPage.Controls.Add(this.mondayWeeklySalesTextBox);
this.weeklySalesTabPage.Controls.Add(this.totalWeeklySalesTextBox);
this.weeklySalesTabPage.Controls.Add(this.saturdayWeeklySalesTextBox);
this.weeklySalesTabPage.Controls.Add(this.thursdayWeeklySalesTextBox);
this.weeklySalesTabPage.Controls.Add(this.tuesdayWeeklySalesTextBox);
this.weeklySalesTabPage.Controls.Add(this.mondayWeeklySalesLabel);
this.weeklySalesTabPage.Controls.Add(this.thursdayWeeklySalesLabel);
this.weeklySalesTabPage.Controls.Add(this.saturdayWeeklySalesLabel);
this.weeklySalesTabPage.Controls.Add(this.sundayWeeklySalesTextBox);
this.weeklySalesTabPage.Controls.Add(this.totalWeeklySalesLabel);
this.weeklySalesTabPage.Controls.Add(this.fridayWeeklySalesLabel);
this.weeklySalesTabPage.Controls.Add(this.wednesdayWeeklySalesLabel);
this.weeklySalesTabPage.Controls.Add(this.tuesdayWeeklySalesLabel);
this.weeklySalesTabPage.Controls.Add(this.fridayWeeklySalesTextBox);
this.weeklySalesTabPage.Controls.Add(this.sundayWeeklySalesLabel);
this.weeklySalesTabPage.Controls.Add(this.wednesdayWeeklySalesTextBox);
this.weeklySalesTabPage.Location = new System.Drawing.Point(4, 33);
this.weeklySalesTabPage.Name = "weeklySalesTabPage";
this.weeklySalesTabPage.Padding = new System.Windows.Forms.Padding(3);
this.weeklySalesTabPage.Size = new System.Drawing.Size(411, 334);
this.weeklySalesTabPage.TabIndex = 0;
this.weeklySalesTabPage.Text = "Weekly Sales";
//
// mondayWeeklySalesTextBox
//
this.mondayWeeklySalesTextBox.Location = new System.Drawing.Point(135, 46);
this.mondayWeeklySalesTextBox.Name = "mondayWeeklySalesTextBox";
this.mondayWeeklySalesTextBox.Size = new System.Drawing.Size(274, 29);
this.mondayWeeklySalesTextBox.TabIndex = 7;
//
// totalWeeklySalesTextBox
//
this.totalWeeklySalesTextBox.Location = new System.Drawing.Point(134, 299);
this.totalWeeklySalesTextBox.Name = "totalWeeklySalesTextBox";
this.totalWeeklySalesTextBox.Size = new System.Drawing.Size(274, 29);
this.totalWeeklySalesTextBox.TabIndex = 13;
//
// saturdayWeeklySalesTextBox
//
this.saturdayWeeklySalesTextBox.Location = new System.Drawing.Point(135, 256);
this.saturdayWeeklySalesTextBox.Name = "saturdayWeeklySalesTextBox";
this.saturdayWeeklySalesTextBox.Size = new System.Drawing.Size(274, 29);
this.saturdayWeeklySalesTextBox.TabIndex = 12;
//
// thursdayWeeklySalesTextBox
//
this.thursdayWeeklySalesTextBox.Location = new System.Drawing.Point(135, 172);
this.thursdayWeeklySalesTextBox.Name = "thursdayWeeklySalesTextBox";
this.thursdayWeeklySalesTextBox.Size = new System.Drawing.Size(274, 29);
this.thursdayWeeklySalesTextBox.TabIndex = 10;
//
// tuesdayWeeklySalesTextBox
//
this.tuesdayWeeklySalesTextBox.Location = new System.Drawing.Point(135, 88);
this.tuesdayWeeklySalesTextBox.Name = "tuesdayWeeklySalesTextBox";
this.tuesdayWeeklySalesTextBox.Size = new System.Drawing.Size(274, 29);
this.tuesdayWeeklySalesTextBox.TabIndex = 8;
//
// mondayWeeklySalesLabel
//
this.mondayWeeklySalesLabel.AutoSize = true;
this.mondayWeeklySalesLabel.Location = new System.Drawing.Point(11, 49);
this.mondayWeeklySalesLabel.Name = "mondayWeeklySalesLabel";
this.mondayWeeklySalesLabel.Size = new System.Drawing.Size(89, 25);
this.mondayWeeklySalesLabel.TabIndex = 1;
this.mondayWeeklySalesLabel.Text = "Monday:";
//
// thursdayWeeklySalesLabel
//
this.thursdayWeeklySalesLabel.AutoSize = true;
this.thursdayWeeklySalesLabel.Location = new System.Drawing.Point(11, 175);
this.thursdayWeeklySalesLabel.Name = "thursdayWeeklySalesLabel";
this.thursdayWeeklySalesLabel.Size = new System.Drawing.Size(101, 25);
this.thursdayWeeklySalesLabel.TabIndex = 4;
this.thursdayWeeklySalesLabel.Text = "Thursday:";
//
// saturdayWeeklySalesLabel
//
this.saturdayWeeklySalesLabel.AutoSize = true;
this.saturdayWeeklySalesLabel.Location = new System.Drawing.Point(11, 259);
this.saturdayWeeklySalesLabel.Name = "saturdayWeeklySalesLabel";
this.saturdayWeeklySalesLabel.Size = new System.Drawing.Size(97, 25);
this.saturdayWeeklySalesLabel.TabIndex = 6;
this.saturdayWeeklySalesLabel.Text = "Saturday:";
//
// sundayWeeklySalesTextBox
//
this.sundayWeeklySalesTextBox.Location = new System.Drawing.Point(135, 4);
this.sundayWeeklySalesTextBox.Name = "sundayWeeklySalesTextBox";
this.sundayWeeklySalesTextBox.Size = new System.Drawing.Size(274, 29);
this.sundayWeeklySalesTextBox.TabIndex = 6;
//
// totalWeeklySalesLabel
//
this.totalWeeklySalesLabel.AutoSize = true;
this.totalWeeklySalesLabel.Location = new System.Drawing.Point(11, 301);
this.totalWeeklySalesLabel.Name = "totalWeeklySalesLabel";
this.totalWeeklySalesLabel.Size = new System.Drawing.Size(117, 25);
this.totalWeeklySalesLabel.TabIndex = 7;
this.totalWeeklySalesLabel.Text = "Total Sales:";
//
// fridayWeeklySalesLabel
//
this.fridayWeeklySalesLabel.AutoSize = true;
this.fridayWeeklySalesLabel.Location = new System.Drawing.Point(11, 217);
this.fridayWeeklySalesLabel.Name = "fridayWeeklySalesLabel";
this.fridayWeeklySalesLabel.Size = new System.Drawing.Size(72, 25);
this.fridayWeeklySalesLabel.TabIndex = 5;
this.fridayWeeklySalesLabel.Text = "Friday:";
//
// wednesdayWeeklySalesLabel
//
this.wednesdayWeeklySalesLabel.AutoSize = true;
this.wednesdayWeeklySalesLabel.Location = new System.Drawing.Point(11, 133);
this.wednesdayWeeklySalesLabel.Name = "wednesdayWeeklySalesLabel";
this.wednesdayWeeklySalesLabel.Size = new System.Drawing.Size(124, 25);
this.wednesdayWeeklySalesLabel.TabIndex = 3;
this.wednesdayWeeklySalesLabel.Text = "Wednesday:";
//
// tuesdayWeeklySalesLabel
//
this.tuesdayWeeklySalesLabel.AutoSize = true;
this.tuesdayWeeklySalesLabel.Location = new System.Drawing.Point(11, 91);
this.tuesdayWeeklySalesLabel.Name = "tuesdayWeeklySalesLabel";
this.tuesdayWeeklySalesLabel.Size = new System.Drawing.Size(95, 25);
this.tuesdayWeeklySalesLabel.TabIndex = 2;
this.tuesdayWeeklySalesLabel.Text = "Tuesday:";
//
// fridayWeeklySalesTextBox
//
this.fridayWeeklySalesTextBox.Location = new System.Drawing.Point(135, 214);
this.fridayWeeklySalesTextBox.Name = "fridayWeeklySalesTextBox";
this.fridayWeeklySalesTextBox.Size = new System.Drawing.Size(274, 29);
this.fridayWeeklySalesTextBox.TabIndex = 11;
//
// sundayWeeklySalesLabel
//
this.sundayWeeklySalesLabel.AutoSize = true;
this.sundayWeeklySalesLabel.Location = new System.Drawing.Point(11, 7);
this.sundayWeeklySalesLabel.Name = "sundayWeeklySalesLabel";
this.sundayWeeklySalesLabel.Size = new System.Drawing.Size(86, 25);
this.sundayWeeklySalesLabel.TabIndex = 0;
this.sundayWeeklySalesLabel.Text = "Sunday:";
//
// wednesdayWeeklySalesTextBox
//
this.wednesdayWeeklySalesTextBox.Location = new System.Drawing.Point(135, 130);
this.wednesdayWeeklySalesTextBox.Name = "wednesdayWeeklySalesTextBox";
this.wednesdayWeeklySalesTextBox.Size = new System.Drawing.Size(274, 29);
this.wednesdayWeeklySalesTextBox.TabIndex = 9;
//
// taxableTabPage
//
this.taxableTabPage.BackColor = System.Drawing.SystemColors.ControlLight;
this.taxableTabPage.Controls.Add(this.totalTaxableTextBox);
this.taxableTabPage.Controls.Add(this.mondayTaxableTextBox);
this.taxableTabPage.Controls.Add(this.thursdayTaxableTextBox);
this.taxableTabPage.Controls.Add(this.tuesdayTaxableTextBox);
this.taxableTabPage.Controls.Add(this.fridayTaxableLabel);
this.taxableTabPage.Controls.Add(this.sundayTaxableLabel);
this.taxableTabPage.Controls.Add(this.thursdayTaxableLabel);
this.taxableTabPage.Controls.Add(this.wednesdayTaxableTextBox);
this.taxableTabPage.Controls.Add(this.fridayTaxableTextBox);
this.taxableTabPage.Controls.Add(this.mondayTaxableLabel);
this.taxableTabPage.Controls.Add(this.wednesdayTaxableLabel);
this.taxableTabPage.Controls.Add(this.totalTaxableLabel);
this.taxableTabPage.Controls.Add(this.saturdayTaxableLabel);
this.taxableTabPage.Controls.Add(this.sundayTaxableTextBox);
this.taxableTabPage.Controls.Add(this.tuesdayTaxableLabel);
this.taxableTabPage.Controls.Add(this.saturdayTaxableTextBox);
this.taxableTabPage.Location = new System.Drawing.Point(4, 33);
this.taxableTabPage.Name = "taxableTabPage";
this.taxableTabPage.Padding = new System.Windows.Forms.Padding(3);
this.taxableTabPage.Size = new System.Drawing.Size(411, 334);
this.taxableTabPage.TabIndex = 1;
this.taxableTabPage.Text = "Taxable";
//
// totalTaxableTextBox
//
this.totalTaxableTextBox.Location = new System.Drawing.Point(145, 299);
this.totalTaxableTextBox.Name = "totalTaxableTextBox";
this.totalTaxableTextBox.Size = new System.Drawing.Size(263, 29);
this.totalTaxableTextBox.TabIndex = 21;
//
// mondayTaxableTextBox
//
this.mondayTaxableTextBox.Location = new System.Drawing.Point(145, 47);
this.mondayTaxableTextBox.Name = "mondayTaxableTextBox";
this.mondayTaxableTextBox.Size = new System.Drawing.Size(263, 29);
this.mondayTaxableTextBox.TabIndex = 15;
//
// thursdayTaxableTextBox
//
this.thursdayTaxableTextBox.Location = new System.Drawing.Point(145, 173);
this.thursdayTaxableTextBox.Name = "thursdayTaxableTextBox";
this.thursdayTaxableTextBox.Size = new System.Drawing.Size(263, 29);
this.thursdayTaxableTextBox.TabIndex = 18;
//
// tuesdayTaxableTextBox
//
this.tuesdayTaxableTextBox.Location = new System.Drawing.Point(145, 90);
this.tuesdayTaxableTextBox.Name = "tuesdayTaxableTextBox";
this.tuesdayTaxableTextBox.Size = new System.Drawing.Size(263, 29);
this.tuesdayTaxableTextBox.TabIndex = 16;
//
// fridayTaxableLabel
//
this.fridayTaxableLabel.AutoSize = true;
this.fridayTaxableLabel.Location = new System.Drawing.Point(11, 219);
this.fridayTaxableLabel.Name = "fridayTaxableLabel";
this.fridayTaxableLabel.Size = new System.Drawing.Size(72, 25);
this.fridayTaxableLabel.TabIndex = 13;
this.fridayTaxableLabel.Text = "Friday:";
//
// sundayTaxableLabel
//
this.sundayTaxableLabel.AutoSize = true;
this.sundayTaxableLabel.Location = new System.Drawing.Point(11, 9);
this.sundayTaxableLabel.Name = "sundayTaxableLabel";
this.sundayTaxableLabel.Size = new System.Drawing.Size(86, 25);
this.sundayTaxableLabel.TabIndex = 8;
this.sundayTaxableLabel.Text = "Sunday:";
//
// thursdayTaxableLabel
//
this.thursdayTaxableLabel.AutoSize = true;
this.thursdayTaxableLabel.Location = new System.Drawing.Point(11, 177);
this.thursdayTaxableLabel.Name = "thursdayTaxableLabel";
this.thursdayTaxableLabel.Size = new System.Drawing.Size(101, 25);
this.thursdayTaxableLabel.TabIndex = 12;
this.thursdayTaxableLabel.Text = "Thursday:";
//
// wednesdayTaxableTextBox
//
this.wednesdayTaxableTextBox.Location = new System.Drawing.Point(145, 132);
this.wednesdayTaxableTextBox.Name = "wednesdayTaxableTextBox";
this.wednesdayTaxableTextBox.Size = new System.Drawing.Size(263, 29);
this.wednesdayTaxableTextBox.TabIndex = 17;
//
// fridayTaxableTextBox
//
this.fridayTaxableTextBox.Location = new System.Drawing.Point(145, 216);
this.fridayTaxableTextBox.Name = "fridayTaxableTextBox";
this.fridayTaxableTextBox.Size = new System.Drawing.Size(263, 29);
this.fridayTaxableTextBox.TabIndex = 19;
//
// mondayTaxableLabel
//
this.mondayTaxableLabel.AutoSize = true;
this.mondayTaxableLabel.Location = new System.Drawing.Point(11, 51);
this.mondayTaxableLabel.Name = "mondayTaxableLabel";
this.mondayTaxableLabel.Size = new System.Drawing.Size(89, 25);
this.mondayTaxableLabel.TabIndex = 9;
this.mondayTaxableLabel.Text = "Monday:";
//
// wednesdayTaxableLabel
//
this.wednesdayTaxableLabel.AutoSize = true;
this.wednesdayTaxableLabel.Location = new System.Drawing.Point(11, 135);
this.wednesdayTaxableLabel.Name = "wednesdayTaxableLabel";
this.wednesdayTaxableLabel.Size = new System.Drawing.Size(124, 25);
this.wednesdayTaxableLabel.TabIndex = 11;
this.wednesdayTaxableLabel.Text = "Wednesday:";
//
// totalTaxableLabel
//
this.totalTaxableLabel.AutoSize = true;
this.totalTaxableLabel.Location = new System.Drawing.Point(11, 303);
this.totalTaxableLabel.Name = "totalTaxableLabel";
this.totalTaxableLabel.Size = new System.Drawing.Size(138, 25);
this.totalTaxableLabel.TabIndex = 15;
this.totalTaxableLabel.Text = "Total Taxable:";
//
// saturdayTaxableLabel
//
this.saturdayTaxableLabel.AutoSize = true;
this.saturdayTaxableLabel.Location = new System.Drawing.Point(11, 261);
this.saturdayTaxableLabel.Name = "saturdayTaxableLabel";
this.saturdayTaxableLabel.Size = new System.Drawing.Size(97, 25);
this.saturdayTaxableLabel.TabIndex = 14;
this.saturdayTaxableLabel.Text = "Saturday:";
//
// sundayTaxableTextBox
//
this.sundayTaxableTextBox.Location = new System.Drawing.Point(145, 5);
this.sundayTaxableTextBox.Name = "sundayTaxableTextBox";
this.sundayTaxableTextBox.Size = new System.Drawing.Size(263, 29);
this.sundayTaxableTextBox.TabIndex = 14;
//
// tuesdayTaxableLabel
//
this.tuesdayTaxableLabel.AutoSize = true;
this.tuesdayTaxableLabel.Location = new System.Drawing.Point(11, 93);
this.tuesdayTaxableLabel.Name = "tuesdayTaxableLabel";
this.tuesdayTaxableLabel.Size = new System.Drawing.Size(95, 25);
this.tuesdayTaxableLabel.TabIndex = 10;
this.tuesdayTaxableLabel.Text = "Tuesday:";
//
// saturdayTaxableTextBox
//
this.saturdayTaxableTextBox.Location = new System.Drawing.Point(145, 258);
this.saturdayTaxableTextBox.Name = "saturdayTaxableTextBox";
this.saturdayTaxableTextBox.Size = new System.Drawing.Size(263, 29);
this.saturdayTaxableTextBox.TabIndex = 20;
//
// dateGroupBox
//
this.dateGroupBox.Controls.Add(this.monthCalendarInstructionsLabel);
this.dateGroupBox.Controls.Add(this.weekEndingMonthCalendar);
this.dateGroupBox.Dock = System.Windows.Forms.DockStyle.Fill;
this.dateGroupBox.Location = new System.Drawing.Point(3, 593);
this.dateGroupBox.Name = "dateGroupBox";
this.mainLayoutPanel.SetRowSpan(this.dateGroupBox, 2);
this.dateGroupBox.Size = new System.Drawing.Size(413, 365);
this.dateGroupBox.TabIndex = 24;
this.dateGroupBox.TabStop = false;
this.dateGroupBox.Text = "Week Ending Date (MM/DD/YYYY)";
//
// monthCalendarInstructionsLabel
//
this.monthCalendarInstructionsLabel.AutoSize = true;
this.monthCalendarInstructionsLabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.142858F, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.monthCalendarInstructionsLabel.Location = new System.Drawing.Point(57, 30);
this.monthCalendarInstructionsLabel.Name = "monthCalendarInstructionsLabel";
this.monthCalendarInstructionsLabel.Size = new System.Drawing.Size(296, 25);
this.monthCalendarInstructionsLabel.TabIndex = 2;
this.monthCalendarInstructionsLabel.Text = "Select a date from the calendar...";
//
// weekEndingMonthCalendar
//
this.weekEndingMonthCalendar.BackColor = System.Drawing.SystemColors.ControlLight;
this.weekEndingMonthCalendar.FirstDayOfWeek = System.Windows.Forms.Day.Sunday;
this.weekEndingMonthCalendar.Location = new System.Drawing.Point(29, 61);
this.weekEndingMonthCalendar.MaxSelectionCount = 1;
this.weekEndingMonthCalendar.Name = "weekEndingMonthCalendar";
this.weekEndingMonthCalendar.ShowTodayCircle = false;
this.weekEndingMonthCalendar.TabIndex = 2;
this.weekEndingMonthCalendar.TabStop = false;
this.weekEndingMonthCalendar.DateChanged += new System.Windows.Forms.DateRangeEventHandler(this.UpdateWeekEndingMaskedTextBox);
//
// dateTimeMaskedTextBoxPanel
//
this.dateTimeMaskedTextBoxPanel.Controls.Add(this.errorLabel);
this.dateTimeMaskedTextBoxPanel.Controls.Add(this.weekEndingMaskedTextBox);
this.dateTimeMaskedTextBoxPanel.Controls.Add(this.weekEndingMaskedTextBoxInstructionLabel);
this.dateTimeMaskedTextBoxPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.dateTimeMaskedTextBoxPanel.Location = new System.Drawing.Point(422, 824);
this.dateTimeMaskedTextBoxPanel.Name = "dateTimeMaskedTextBoxPanel";
this.dateTimeMaskedTextBoxPanel.Size = new System.Drawing.Size(413, 134);
this.dateTimeMaskedTextBoxPanel.TabIndex = 1;
//
// errorLabel
//
this.errorLabel.AutoSize = true;
this.errorLabel.ForeColor = System.Drawing.Color.Maroon;
this.errorLabel.Location = new System.Drawing.Point(3, 31);
this.errorLabel.Name = "errorLabel";
this.errorLabel.Size = new System.Drawing.Size(108, 25);
this.errorLabel.TabIndex = 28;
this.errorLabel.Text = "Errors here";
//
// weekEndingMaskedTextBox
//
this.weekEndingMaskedTextBox.Font = new System.Drawing.Font("Microsoft Sans Serif", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.weekEndingMaskedTextBox.Location = new System.Drawing.Point(277, 3);
this.weekEndingMaskedTextBox.Mask = "00/00/0000";
this.weekEndingMaskedTextBox.Name = "weekEndingMaskedTextBox";
this.weekEndingMaskedTextBox.Size = new System.Drawing.Size(115, 31);
this.weekEndingMaskedTextBox.TabIndex = 3;
this.weekEndingMaskedTextBox.ValidatingType = typeof(System.DateTime);
//
// weekEndingMaskedTextBoxInstructionLabel
//
this.weekEndingMaskedTextBoxInstructionLabel.AutoSize = true;
this.weekEndingMaskedTextBoxInstructionLabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.142858F, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.weekEndingMaskedTextBoxInstructionLabel.Location = new System.Drawing.Point(16, 6);
this.weekEndingMaskedTextBoxInstructionLabel.Name = "weekEndingMaskedTextBoxInstructionLabel";
this.weekEndingMaskedTextBoxInstructionLabel.Size = new System.Drawing.Size(245, 25);
this.weekEndingMaskedTextBoxInstructionLabel.TabIndex = 0;
this.weekEndingMaskedTextBoxInstructionLabel.Text = "... or manually enter it here:\r\n";
//
// informationPanel
//
this.informationPanel.Controls.Add(this.informationLabel);
this.informationPanel.Controls.Add(this.addRecordButton);
this.informationPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.informationPanel.Location = new System.Drawing.Point(1260, 824);
this.informationPanel.Name = "informationPanel";
this.informationPanel.Size = new System.Drawing.Size(413, 134);
this.informationPanel.TabIndex = 25;
//
// informationLabel
//
this.informationLabel.AutoSize = true;
this.informationLabel.Location = new System.Drawing.Point(0, 0);
this.informationLabel.Name = "informationLabel";
this.informationLabel.Size = new System.Drawing.Size(152, 25);
this.informationLabel.TabIndex = 27;
this.informationLabel.Text = "Information here";
//
// addRecordButton
//
this.addRecordButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.addRecordButton.Location = new System.Drawing.Point(237, 84);
this.addRecordButton.Name = "addRecordButton";
this.addRecordButton.Size = new System.Drawing.Size(167, 41);
this.addRecordButton.TabIndex = 26;
this.addRecordButton.Text = "Add Record";
this.addRecordButton.UseVisualStyleBackColor = true;
this.addRecordButton.Click += new System.EventHandler(this.AddRecordsButtonClick);
//
// NewAddRecord
//
this.AutoScaleDimensions = new System.Drawing.SizeF(168F, 168F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi;
this.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
this.ClientSize = new System.Drawing.Size(1676, 961);
this.Controls.Add(this.mainLayoutPanel);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.MainMenuStrip = this.mainMenuStrip;
this.Margin = new System.Windows.Forms.Padding(4);
this.MaximizeBox = false;
this.MaximumSize = new System.Drawing.Size(1900, 1025);
this.MinimumSize = new System.Drawing.Size(1700, 1025);
this.Name = "NewAddRecord";
this.Text = "Add New Record";
this.commentsGroupBox.ResumeLayout(false);
this.commentsGroupBox.PerformLayout();
this.mainTabControl.ResumeLayout(false);
this.projectionTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.projectionsDataGridView)).EndInit();
this.inventoryTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.inventoryDataGridView)).EndInit();
this.actualSalesTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.actualSalesDataGridView)).EndInit();
this.invoicesTabPage.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.invoicesDataGridView)).EndInit();
this.mainMenuStrip.ResumeLayout(false);
this.mainMenuStrip.PerformLayout();
this.mainLayoutPanel.ResumeLayout(false);
this.mainLayoutPanel.PerformLayout();
this.costAnalysisGroupBox.ResumeLayout(false);
this.costAnalysisGroupBox.PerformLayout();
this.tabControl1.ResumeLayout(false);
this.weeklySalesTabPage.ResumeLayout(false);
this.weeklySalesTabPage.PerformLayout();
this.taxableTabPage.ResumeLayout(false);
this.taxableTabPage.PerformLayout();
this.dateGroupBox.ResumeLayout(false);
this.dateGroupBox.PerformLayout();
this.dateTimeMaskedTextBoxPanel.ResumeLayout(false);
this.dateTimeMaskedTextBoxPanel.PerformLayout();
this.informationPanel.ResumeLayout(false);
this.informationPanel.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.GroupBox commentsGroupBox;
private System.Windows.Forms.TabControl mainTabControl;
private System.Windows.Forms.TableLayoutPanel mainLayoutPanel;
private System.Windows.Forms.MenuStrip mainMenuStrip;
private System.Windows.Forms.ToolStripMenuItem FileMainMenu;
private System.Windows.Forms.ToolStripMenuItem exitFileMainMenu;
private System.Windows.Forms.TabPage projectionTabPage;
private System.Windows.Forms.TabPage inventoryTabPage;
private System.Windows.Forms.DataGridView inventoryDataGridView;
private System.Windows.Forms.TabPage actualSalesTabPage;
private System.Windows.Forms.DataGridView actualSalesDataGridView;
private System.Windows.Forms.TabPage invoicesTabPage;
private System.Windows.Forms.DataGridView invoicesDataGridView;
private System.Windows.Forms.TextBox suppliesTextBox;
private System.Windows.Forms.TextBox salaryDollarsTextBox;
private System.Windows.Forms.TextBox salaryPercentageTextBox;
private System.Windows.Forms.TextBox salesPerManHourTextBox;
private System.Windows.Forms.Label suppliesLabel;
private System.Windows.Forms.Label salaryDollarsLabel;
private System.Windows.Forms.Label salaryPercentageLabel;
private System.Windows.Forms.Label salesPerManHourLabel;
private System.Windows.Forms.TextBox commentsTextBox;
private System.Windows.Forms.GroupBox costAnalysisGroupBox;
private System.Windows.Forms.Label sundayTaxableLabel;
private System.Windows.Forms.Label mondayTaxableLabel;
private System.Windows.Forms.Label tuesdayTaxableLabel;
private System.Windows.Forms.Label wednesdayTaxableLabel;
private System.Windows.Forms.Label thursdayTaxableLabel;
private System.Windows.Forms.Label fridayTaxableLabel;
private System.Windows.Forms.Label saturdayTaxableLabel;
private System.Windows.Forms.Label totalTaxableLabel;
private System.Windows.Forms.Button addRecordButton;
private System.Windows.Forms.TextBox totalTaxableTextBox;
private System.Windows.Forms.TextBox wednesdayTaxableTextBox;
private System.Windows.Forms.TextBox saturdayTaxableTextBox;
private System.Windows.Forms.TextBox fridayTaxableTextBox;
private System.Windows.Forms.TextBox thursdayTaxableTextBox;
private System.Windows.Forms.TextBox tuesdayTaxableTextBox;
private System.Windows.Forms.TextBox mondayTaxableTextBox;
private System.Windows.Forms.TextBox sundayTaxableTextBox;
private System.Windows.Forms.DataGridView projectionsDataGridView;
private System.Windows.Forms.TextBox totalWeeklySalesTextBox;
private System.Windows.Forms.TextBox wednesdayWeeklySalesTextBox;
private System.Windows.Forms.Label totalWeeklySalesLabel;
private System.Windows.Forms.TextBox saturdayWeeklySalesTextBox;
private System.Windows.Forms.Label saturdayWeeklySalesLabel;
private System.Windows.Forms.Label sundayWeeklySalesLabel;
private System.Windows.Forms.TextBox sundayWeeklySalesTextBox;
private System.Windows.Forms.TextBox fridayWeeklySalesTextBox;
private System.Windows.Forms.Label fridayWeeklySalesLabel;
private System.Windows.Forms.Label mondayWeeklySalesLabel;
private System.Windows.Forms.TextBox mondayWeeklySalesTextBox;
private System.Windows.Forms.TextBox thursdayWeeklySalesTextBox;
private System.Windows.Forms.Label thursdayWeeklySalesLabel;
private System.Windows.Forms.Label tuesdayWeeklySalesLabel;
private System.Windows.Forms.TextBox tuesdayWeeklySalesTextBox;
private System.Windows.Forms.Label wednesdayWeeklySalesLabel;
private System.Windows.Forms.GroupBox dateGroupBox;
private System.Windows.Forms.TabControl tabControl1;
private System.Windows.Forms.TabPage weeklySalesTabPage;
private System.Windows.Forms.TabPage taxableTabPage;
private System.Windows.Forms.Label monthCalendarInstructionsLabel;
private System.Windows.Forms.MonthCalendar weekEndingMonthCalendar;
private System.Windows.Forms.Panel dateTimeMaskedTextBoxPanel;
private System.Windows.Forms.MaskedTextBox weekEndingMaskedTextBox;
private System.Windows.Forms.Label weekEndingMaskedTextBoxInstructionLabel;
private System.Windows.Forms.TabPage debugTabPage;
private System.Windows.Forms.Panel informationPanel;
private System.Windows.Forms.Label errorLabel;
private System.Windows.Forms.Label informationLabel;
private System.Windows.Forms.ToolStripMenuItem debugMainMenu;
private System.Windows.Forms.ToolStripMenuItem getCellValueDebugMainMenu;
}
}
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+25
View File
@@ -0,0 +1,25 @@
using System;
using System.Windows.Forms;
namespace AdvertsingProfitControl
{
static class Program
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
private static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.ThreadException += GlobalClasses.LogError;
AppDomain.CurrentDomain.UnhandledException += GlobalClasses.LogError;
//LogConsole console = LogConsole.GetStaticInstance;
//var errorConsoleThread = new Thread(console.Show);
//errorConsoleThread.IsBackground = true;
//errorConsoleThread.Start();
Application.Run(new FrmMain());
}
}
}
@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Advertsing Profit Control")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("Advertsing Profit Control")]
[assembly: AssemblyCopyright("Copyright © 2016")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("ddd8ea52-f3a1-4e6f-8b7e-8d9c1c19179d")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("0.9.5.2")]
[assembly: AssemblyFileVersion("0.9.5.2")]
+63
View File
@@ -0,0 +1,63 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace AdvertsingProfitControl.Properties {
using System;
/// <summary>
/// A strongly-typed resource class, for looking up localized strings, etc.
/// </summary>
// This class was auto-generated by the StronglyTypedResourceBuilder
// class via a tool like ResGen or Visual Studio.
// To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources {
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources() {
}
/// <summary>
/// Returns the cached ResourceManager instance used by this class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager {
get {
if (object.ReferenceEquals(resourceMan, null)) {
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("AdvertsingProfitControl.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Overrides the current thread's CurrentUICulture property for all
/// resource lookups using this strongly typed resource class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture {
get {
return resourceCulture;
}
set {
resourceCulture = value;
}
}
}
}
@@ -0,0 +1,117 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
+26
View File
@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace AdvertsingProfitControl.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
public static Settings Default {
get {
return defaultInstance;
}
}
}
}
@@ -0,0 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
<Profiles />
<Settings />
</SettingsFile>
@@ -0,0 +1,54 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<assemblyIdentity version="1.0.0.0" name="MyApplication.app" />
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
<security>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
<!-- UAC Manifest Options
If you want to change the Windows User Account Control level replace the
requestedExecutionLevel node with one of the following.
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
<requestedExecutionLevel level="highestAvailable" uiAccess="false" />
Specifying requestedExecutionLevel node will disable file and registry virtualization.
If you want to utilize File and Registry Virtualization for backward
compatibility then delete the requestedExecutionLevel node.
-->
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
</requestedPrivileges>
<applicationRequestMinimum>
<defaultAssemblyRequest permissionSetReference="Custom" />
<PermissionSet class="System.Security.PermissionSet" version="1" Unrestricted="true" ID="Custom" SameSite="site" />
</applicationRequestMinimum>
</security>
</trustInfo>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<dpiAware>true/PM</dpiAware>
<!-- A list of all Windows versions that this application is designed to work with.
Windows will automatically select the most compatible environment.-->
<!-- If your application is designed to work with Windows Vista, uncomment the following supportedOS node-->
<!--<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"></supportedOS>-->
<!-- If your application is designed to work with Windows 7, uncomment the following supportedOS node-->
<!--<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>-->
<!-- If your application is designed to work with Windows 8, uncomment the following supportedOS node-->
<!--<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"></supportedOS>-->
<!--<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>-->
</application>
</compatibility>
<!-- Enable themes for Windows common controls and dialogs (Windows XP and later) -->
<!-- <dependency>
<dependentAssembly>
<assemblyIdentity
type="win32"
name="Microsoft.Windows.Common-Controls"
version="6.0.0.0"
processorArchitecture="*"
publicKeyToken="6595b64144ccf1df"
language="*"
/>
</dependentAssembly>
</dependency>-->
</asmv1:assembly>
+137
View File
@@ -0,0 +1,137 @@
using System;
using System.Collections.Generic;
using System.Text.RegularExpressions;
using System.Windows.Forms;
using System.Linq;
namespace AdvertsingProfitControl
{
internal class RowParsing
{
public static List<string> AdSpecialGroups = new List<string>();
public string CheckForGroupKeyWord(string cellContents)
{
var keyWord = "NoGroupFound";
var query = from adI in AdSpecialGroups
where adI.Equals(cellContents, StringComparison.InvariantCultureIgnoreCase)
select adI;
var enumerable = query as string[] ?? query.ToArray();
if (enumerable.ToArray().Length > 0)
{
//Grab the first object in the array and return it.
keyWord = enumerable.ToArray().First();
}
return keyWord;
}
/// <summary>
/// Determines a row's status.
/// </summary>
/// <param name="row">The row from a DataGridView object to be examined.</param>
/// <returns>The row's status, such as HeaderRow or NewRow.</returns>
public RowAttribute GetRowAttribute(DataGridViewRow row)
{
//IF the supplied row is null, then simply declare it an IncompleteRow.
if (row == null)
{
return RowAttribute.IncompleteRow;
}
//IF the supplied row is a new row, by the definition of the DataGridViewRow class, then return NewRow.
if (row.IsNewRow)
{
return RowAttribute.NewRow;
}
var rowContents = new List<string>();
var rowAttribute = RowAttribute.MemberRow;
//Get the contents of the row that's being examined and add then to a List<string> array.
var i = 0;
foreach (DataGridViewCell cell in row.Cells)
{
if (cell.ColumnIndex >= (int) SalesTableColumns.IsHeaderRow) { i++; continue;}
//Strip all whitespace characters from the cell, this includes vertical tabs, newlines, and any number of spaces.
var cellContentsStripped = new string(cell.EditedFormattedValue.ToString().Where(c => !char.IsWhiteSpace(c)).ToArray());
//Now remove all zeros, including any decimal points as these values are meaningless.
cellContentsStripped = cellContentsStripped.Replace("0", "");
cellContentsStripped = cellContentsStripped.Replace(".", "");
if (cellContentsStripped != "")
{
rowContents.Add(cell.EditedFormattedValue.ToString());
}
//If the first cell contains nothing, then return as IncompleteRow.
else if (cellContentsStripped == "" && i == (int) SalesTableColumns.AdItem)
{
return RowAttribute.IncompleteRow;
}
i++;
}
//With all meaningless content removed, only actual data should be here. So if there are more then one items, than that means there are more then one
//cells with meaningful data in them. Which means that this row can be a header row with member rows under it.
if (rowContents.Count > 1)
{
rowAttribute = RowAttribute.HeaderRow;
}
else if (rowContents.Count == 1) //Check to see if this row is intended to be for a special ad.
{
var keyWord = CheckForGroupKeyWord(rowContents[0]);
//IF a keyword is found then declare this row an AdSpecialRow.
if (keyWord != "NoGroupFound")
{
return RowAttribute.AdSpecialRow;
}
}
return rowAttribute;
}
public RowAttribute GetRowAttribute(object[] row)
{
var rowAttribute = RowAttribute.MemberRow;
return rowAttribute;
}
public void PaintDataGridViewRowGroups(DataGridView dataGridView, DataGridView companionDataGridView = null, int startIndex = 0,
bool stopOnFirstFullGroupFound = false)
{
}
/// <summary>
/// Checks for the presents of a repeat command using the Reg-ex engine.
/// If a repeat command is found it returns the line number the command
/// specifies to repeat.
/// </summary>
/// <param name="rowCommandField">The contents of Cell[0] in the row being parsed.</param>
/// <returns>Line number to be repeated, -1 if no command is found.</returns>
public int CheckForRepeatCommand(string rowCommandField)
{
const string repeatCommandPattern = @"^repeat( line)?:? [0-9]"; //Reference sheet: https://msdn.microsoft.com/en-us/library/az24scfc.aspx
var rgx = new Regex(repeatCommandPattern, RegexOptions.IgnoreCase);
var lineNumber = -1;
if (!rgx.IsMatch(rowCommandField)) return lineNumber;
//Parse the string and retrieve the line number
var numbers = Regex.Split(rowCommandField, @"\D+");
lineNumber = int.Parse(numbers[1]);
return lineNumber;
}
}
public enum RowAttribute
{
NewRow = 0,
MemberRow = 1,
HeaderRow = 2,
AdSpecialRow = 3,
IncompleteRow = 4
}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 361 KiB

+379
View File
@@ -0,0 +1,379 @@
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace AdvertsingProfitControl
{
/// <summary>
/// Contains methods that assist with managing ad item names.
/// </summary>
internal static class TextFormat
{
private static readonly FrmLogConsole LogConsole = FrmLogConsole.GetStaticInstance;
/// <summary>
/// Formats an ad item's name / text into a standard format so as to help reduce redundancy in the database.
/// </summary>
/// <param name="adItemText">The ad item's name to be formatted.</param>
/// <param name="preserveAcronyms">Whether or not to preserve case on abbreviations.</param>
/// <returns>A cleaned up and formatted version of the ad item text.</returns>
public static string FormatAdItemText(string adItemText, bool preserveAcronyms = false)
{
//Trim all beginning and trailing whitespace characters to start.
adItemText = adItemText.Trim();
var abbreviations = new List<string>();
var words = new List<string>();
var isInsideBrackets = false;
//This just makes the code a bit more readable rather then doing "adItemText[currentCharacter - 1]" to access the previous character.
var isPreviousCharWhiteSpace = false;
var cleanedInputString = "";
var lastnumberStartingIndex = -1;
//Create an array of brackets to test for, and either balance out or simply ignore the extras.
char[] openBrackets = { '(', '<', '{', '[' };
char[] closedBrackets = { ')', '>', '}', ']' };
for (var currentCharacter = 0; currentCharacter < adItemText.Length; currentCharacter++)
{
//Capitalize the first character in the string and move to the next character.
if (currentCharacter == 0)
{
cleanedInputString += char.ToUpperInvariant(adItemText[0]);
continue;
}
//IF the current character is a whitespace character, mark it as such, add to the temporary string, and move on to the next.
if (char.IsWhiteSpace(adItemText[currentCharacter]))
{
//Check for more then one space in a row.
if (isPreviousCharWhiteSpace)
{
//If more then one space is found to be in a row, then ignore it and move onto the next character.
continue;
}
//IF the current character is whitespace, then mark it and move onto the next loop.
isPreviousCharWhiteSpace = true;
lastnumberStartingIndex = -1; //reset
cleanedInputString += adItemText[currentCharacter];
continue;
}
//IF the current character is an open bracket then mark it so we're inside brackets and move to the next character.
if (openBrackets.Contains(adItemText[currentCharacter]))
{
if (isInsideBrackets)
{
//If we are already inside of brackets then don't add anymore to the string just continue.
continue;
}
isInsideBrackets = true;
//Just gonna force parenthesis for now.
cleanedInputString += '(';
continue;
}
//IF the current character is a closing bracket then mark it as such and move to the next character (if any).
if (closedBrackets.Contains(adItemText[currentCharacter]))
{
//IF we're not inside brackets then there is an imbalance so discard this parenthesis.
if (!isInsideBrackets)
{
continue;
}
//Just gonna force parenthesis for now.
cleanedInputString += ')';
lastnumberStartingIndex = -1; //reset
//Clear the current working word.
isInsideBrackets = false;
continue;
}
//IF the current character is not a number and the previous character is a white space character
//then capitalize the current character and add it to the string.
if (!char.IsNumber(adItemText[currentCharacter]) && isPreviousCharWhiteSpace)
{
//Check to see the length of the string and determine if the word with the number needs to be capitalized.
if (char.IsNumber(cleanedInputString[cleanedInputString.Length - 2]))
{
BuildAbbreviationsAndWordsLists(adItemText, currentCharacter, out abbreviations, out words);
//Remove the last space if there are any abbreviations or words found.
if (abbreviations.Count > 0 || words.Count > 0)
{
cleanedInputString = cleanedInputString.Remove(cleanedInputString.Length - 1, 1);
}
//Begin checking to see how to place these items back into the final string.
if (abbreviations.Count >= 1 && words.Count == 0)
{
if (!isInsideBrackets)
{
cleanedInputString += abbreviations[0] + ")";
if (lastnumberStartingIndex != -1)
{
cleanedInputString = cleanedInputString.Insert(lastnumberStartingIndex, "(");
}
}
else
{
cleanedInputString += abbreviations[0] + ")";
}
break;
}
if (abbreviations.Count >= 1 && words.Count == 1)
{
cleanedInputString += abbreviations[0] + " " + words[0];
//Clear all braces since this format doesn't allow for braces in this set up.
cleanedInputString = cleanedInputString.Replace("(", "");
break;
}
if (abbreviations.Count >= 0 && words.Count >= 1)
{
if (abbreviations.Count != 0)
{
cleanedInputString += abbreviations[0];
}
cleanedInputString = words.Aggregate(cleanedInputString, (current, word) => current + (" " + word));
//Clear all braces since this format doesn't allow for braces in this set up.
cleanedInputString = cleanedInputString.Replace("(", "");
break;
}
}
//If all else fails simply assume this is the beginning of a new word and capitalize it.
cleanedInputString += char.ToUpperInvariant(adItemText[currentCharacter]);
}
//However, if the current character is not a number but the previous character is NOT a white space character
//then run a few checks before adding it to the string.
else if (!char.IsNumber(adItemText[currentCharacter]) && char.IsLetter(adItemText[currentCharacter]))
{
//IF the previous character is a number...
if (char.IsNumber(cleanedInputString[cleanedInputString.Length - 1]))
{
//Check to see the length of the string and determine if the word with the number needs to be capitalized.
BuildAbbreviationsAndWordsLists(adItemText, currentCharacter, out abbreviations, out words);
//Check to see if braces are necessary for the format we're going for.
if (abbreviations.Count >= 1 && words.Count == 0)
{
if (!isInsideBrackets)
{
cleanedInputString += abbreviations[0] + ")";
if (lastnumberStartingIndex != -1)
{
cleanedInputString = cleanedInputString.Insert(lastnumberStartingIndex, "(");
}
}
else
{
cleanedInputString += abbreviations[0] + ")";
}
break;
}
if (abbreviations.Count >= 1 && words.Count == 1)
{
cleanedInputString += abbreviations[0] + " " + words[0];
//Clear all braces since this format doesn't allow for braces in this set up.
cleanedInputString = cleanedInputString.Replace("(", "");
break;
}
if (abbreviations.Count >= 0 && words.Count >= 1)
{
if (abbreviations.Count != 0)
{
cleanedInputString += abbreviations[0];
}
cleanedInputString = words.Aggregate(cleanedInputString, (current, word) => current + (" " + word));
//Clear all braces since this format doesn't allow for braces in this set up.
cleanedInputString = cleanedInputString.Replace("(", "");
break;
}
}
else if (char.IsLetter(adItemText[currentCharacter - 1]) || adItemText[currentCharacter - 1] == '\'')
{
cleanedInputString += char.ToLowerInvariant(adItemText[currentCharacter]);
}
}
//IF a number is found, and we're not inside brackets, check to see if there is an opening parenthesis and if there aren't create one.
if (char.IsNumber(adItemText[currentCharacter]))
{
cleanedInputString += adItemText[currentCharacter];
if (lastnumberStartingIndex == -1)
{
lastnumberStartingIndex = cleanedInputString.Length - 1; //Non-index based system, minus one for the index
}
}
//Check for any allowed punctuation.
if (adItemText[currentCharacter] == '\'')
{
cleanedInputString += adItemText[currentCharacter];
}
//Check if the previous character is an "'".
else if (cleanedInputString[cleanedInputString.Length - 1] == '\'')
{
cleanedInputString += adItemText[currentCharacter];
}
//Since whitespace booleans are handled above, set the boolean for white spaces false.
//IF we've made it this far that means the current character is not a white space character.
isPreviousCharWhiteSpace = false;
//IF we're at the end of the string and we're inside brackets then balance out the open bracket.
if ((currentCharacter + 1) == adItemText.Length && isInsideBrackets)
{
cleanedInputString += ')';
}
//removedCharacterOffset++;
}
#if DEBUG
if (abbreviations.Count > 0)
{
LogConsole.WriteToLog(FrmLogConsole.Level.Debug, "Detected abbreviation(s) in input string \"" + adItemText + "\":");
foreach (var abbreviation in abbreviations)
{
LogConsole.WriteToLog(FrmLogConsole.Level.Debug, abbreviation);
}
}
else if (words.Count > 0)
{
LogConsole.WriteToLog(FrmLogConsole.Level.Debug, "Detected words(s) in input string \"" + adItemText + "\":");
foreach (var word in words)
{
LogConsole.WriteToLog(FrmLogConsole.Level.Debug, word);
}
}
#endif
return cleanedInputString;
}
/// <summary>
/// Infrastructure for the TextFormat class, not to be used with external code.
/// Parses the full ad item text, starting at the specified index, for abbreviations and words.
/// Once either of these objects have been found they are added to their respective Lists
/// and returned as outed variables to the calling code. Preserving acronyms is off by default
/// but if turned on keeps the cases of abbreviations as they are.
/// </summary>
/// <param name="adItemText">The full text to be parsed.</param>
/// <param name="startingIndex">Where to start looping through the characters in the text.</param>
/// <param name="abbreviations">A list of abbreviations that were found in the text.</param>
/// <param name="words">A list of words found in the text.</param>
/// <param name="preserveAcronyms">Whether or not to force normal casing rules on abbreviations.</param>
private static void BuildAbbreviationsAndWordsLists(string adItemText, int startingIndex, out List<string> abbreviations,
out List<string> words, bool preserveAcronyms = false)
{
abbreviations = new List<string>();
words = new List<string>();
var currentWorkingString = "";
//Starting at the next character, spin through and find all words or abbreviations that are separated by white space.
for (var i = startingIndex; i < adItemText.Length; i++)
{
//If the current character is a letter and if so add it to the current working string.
if (char.IsLetter(adItemText[i]))
{
currentWorkingString += adItemText[i];
}
//Check for the current character being a white space, showing the end of a word or abbreviation.
else if (char.IsWhiteSpace(adItemText[i]))
{
//Block against null values from messing things up.
if (string.IsNullOrEmpty(currentWorkingString)) continue;
//The end of what ever word we were on has been reached, so check to see what the string is.
if (IsWord(currentWorkingString))
{
words.Add(currentWorkingString);
}
else
{
abbreviations.Add(currentWorkingString);
}
//Clear the current working string to start on the next.
currentWorkingString = "";
}
//Run a check to see if this is the last character in the string.
if ((i + 1) != adItemText.Length) continue;
//The end of whatever word we were on has been reached, so check to see what the string is.
if (IsWord(currentWorkingString))
{
words.Add(currentWorkingString);
}
else
{
abbreviations.Add(currentWorkingString);
}
}
//Clean the cases of the abbreviations and words.
for (var i = 0; i < abbreviations.Count; i++)
{
//If preserve acronyms is set to true then just leave the cases of the abbreviations alone.
if (!preserveAcronyms)
{
abbreviations[i] = abbreviations[i].ToLowerInvariant();
}
}
for (var i = 0; i < words.Count; i++)
{
words[i] = words[i].ToLowerInvariant();
words[i] = CapitalizeFirstLetter(words[i]);
}
}
/// <summary>
/// Determines whether or not a string is an abbreviation or a word.
/// A word is defined as being at least three (3) characters long and having
/// at least one (1) vowel. Where as an abbreviation is defined as less then
/// three (3) characters long but has at least one (1) character, whether or not
/// the string that is two (2) or one (1) characters long has a vowel is meaningless
/// or being exactly three characters long but having zero (0) vowels.
/// </summary>
/// <param name="text">The text to determine whether or not its a word.</param>
/// <returns>A boolean indicating whether or not the text is a word.</returns>
public static bool IsWord(string text)
{
if (string.IsNullOrEmpty(text)) return false;
var isWord = true;
//Most abbreviations do not have vowels in them so check to see if the "abbreviation"
//isn't just a short word like "Box", as opposed to "lbs".
char[] vowels = { 'a', 'e', 'i', 'o', 'u', 'y' };
//Count the number of vowels the word has.
var vowelCount = text.Count(x => vowels.Contains(x));
//IF the string is exactly three (3) characters long and has more then zero (0) vowels then it is considered a word.
if (text.Length == 3 && vowelCount == 0)
{
isWord = false;
}
else if (text.Length < 3)
{
isWord = false;
}
//Return the verdict.
return isWord;
}
/// <summary>
/// Capitalizes the first letter of the text sent to this method.
/// </summary>
/// <param name="text">The text to be capitalized.</param>
/// <returns>The input text that has the first letter capitalized.</returns>
public static string CapitalizeFirstLetter(string text)
{
if (string.IsNullOrEmpty(text)) return string.Empty;
return text.First().ToString().ToUpperInvariant() + string.Join("", text.Skip(1));
}
/// <summary>
/// Add spaces between all words that have capital letters.
/// </summary>
/// <param name="text">The column header text to be made presentable.</param>
/// <param name="preserveAcronyms">Whether or not to do anything with text that's in all caps.</param>
/// <returns>The text with spaces.</returns>
public static string AddSpacesToSentence(string text, bool preserveAcronyms)
{
//http://stackoverflow.com/questions/272633/add-spaces-before-capital-letters
if (string.IsNullOrWhiteSpace(text))
return string.Empty;
var newText = new StringBuilder(text.Length * 2);
newText.Append(text[0]);
for (var i = 1; i < text.Length; i++)
{
if (char.IsUpper(text[i]))
if ((text[i - 1] != ' ' && !char.IsUpper(text[i - 1])) ||
(preserveAcronyms && char.IsUpper(text[i - 1]) &&
i < text.Length - 1 && !char.IsUpper(text[i + 1])))
newText.Append(' ');
newText.Append(text[i]);
}
return newText.ToString();
}
}
}
+76
View File
@@ -0,0 +1,76 @@
<?xml version="1.0" encoding="utf-8"?>
<assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1">
<assemblyIdentity version="1.0.0.0" name="MyApplication.app"/>
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
<security>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
<!-- UAC Manifest Options
If you want to change the Windows User Account Control level replace the
requestedExecutionLevel node with one of the following.
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
<requestedExecutionLevel level="highestAvailable" uiAccess="false" />
Specifying requestedExecutionLevel element will disable file and registry virtualization.
Remove this element if your application requires this virtualization for backwards
compatibility.
-->
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
</requestedPrivileges>
</security>
</trustInfo>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<!-- A list of the Windows versions that this application has been tested on and is
is designed to work with. Uncomment the appropriate elements and Windows will
automatically selected the most compatible environment. -->
<!-- Windows Vista -->
<!--<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />-->
<!-- Windows 7 -->
<!--<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}" />-->
<!-- Windows 8 -->
<!--<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />-->
<!-- Windows 8.1 -->
<!--<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />-->
<!-- Windows 10 -->
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />
</application>
</compatibility>
<!-- Indicates that the application is DPI-aware and will not be automatically scaled by Windows at higher
DPIs. Windows Presentation Foundation (WPF) applications are automatically DPI-aware and do not need
to opt in. Windows Forms applications targeting .NET Framework 4.6 that opt into this setting, should
also set the 'EnableWindowsFormsHighDpiAutoResizing' setting to 'true' in their app.config. -->
<application xmlns="urn:schemas-microsoft-com:asm.v3">
<windowsSettings>
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true/PM</dpiAware>
</windowsSettings>
</application>
<!-- Enable themes for Windows common controls and dialogs (Windows XP and later) -->
<!--
<dependency>
<dependentAssembly>
<assemblyIdentity
type="win32"
name="Microsoft.Windows.Common-Controls"
version="6.0.0.0"
processorArchitecture="*"
publicKeyToken="6595b64144ccf1df"
language="*"
/>
</dependentAssembly>
</dependency>
-->
</assembly>
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xrml="urn:mpeg:mpeg21:2003:01-REL-R-NS" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
<assemblyIdentity name="AdvertsingProfitControl.application" version="1.0.0.1" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="amd64" xmlns="urn:schemas-microsoft-com:asm.v1" />
<description asmv2:publisher="AdvertsingProfitControl" asmv2:product="AdvertsingProfitControl" xmlns="urn:schemas-microsoft-com:asm.v1" />
<deployment install="true" mapFileExtensions="true" />
<compatibleFrameworks xmlns="urn:schemas-microsoft-com:clickonce.v2">
<framework targetVersion="4.5" profile="Full" supportedRuntime="4.0.30319" />
</compatibleFrameworks>
<dependency>
<dependentAssembly dependencyType="install" codebase="AdvertsingProfitControl.exe.manifest" size="6289">
<assemblyIdentity name="AdvertsingProfitControl.exe" version="1.0.0.1" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="amd64" type="win32" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>BdpMI18xuF58t84pN4xrCnguGw/WzgI8+4NoHv0AZ2Q=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
</asmv1:assembly>
@@ -0,0 +1,112 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
<asmv1:assemblyIdentity name="AdvertsingProfitControl.exe" version="1.0.0.1" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="amd64" type="win32" />
<description asmv2:iconFile="Stretched Logo Collection.ico" xmlns="urn:schemas-microsoft-com:asm.v1" />
<application />
<entryPoint>
<assemblyIdentity name="AdvertsingProfitControl" version="0.9.5.2" language="neutral" processorArchitecture="amd64" />
<commandLine file="AdvertsingProfitControl.exe" parameters="" />
</entryPoint>
<trustInfo>
<security>
<applicationRequestMinimum>
<PermissionSet version="1" class="System.Security.NamedPermissionSet" Name="LocalIntranet" Description="Default rights given to applications on the local intranet" Unrestricted="true" ID="Custom" SameSite="site" />
<defaultAssemblyRequest permissionSetReference="Custom" />
</applicationRequestMinimum>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
<!-- UAC Manifest Options
If you want to change the Windows User Account Control level replace the
requestedExecutionLevel node with one of the following.
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
<requestedExecutionLevel level="highestAvailable" uiAccess="false" />
Specifying requestedExecutionLevel element will disable file and registry virtualization.
Remove this element if your application requires this virtualization for backwards
compatibility.
-->
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
</requestedPrivileges>
</security>
</trustInfo>
<dependency>
<dependentOS>
<osVersionInfo>
<os majorVersion="5" minorVersion="1" buildNumber="2600" servicePackMajor="0" />
</osVersionInfo>
</dependentOS>
</dependency>
<dependency>
<dependentAssembly dependencyType="preRequisite" allowDelayedBinding="true">
<assemblyIdentity name="Microsoft.Windows.CommonLanguageRuntime" version="4.0.30319.0" />
</dependentAssembly>
</dependency>
<dependency>
<dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="AdvertsingProfitControl.exe" size="3511296">
<assemblyIdentity name="AdvertsingProfitControl" version="0.9.5.2" language="neutral" processorArchitecture="amd64" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>OJ71svPIgpljDYB7Isp1dyJ+HAA2f5EAkzyTUGfVCPE=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<dependency>
<dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="HtmlRenderer.dll" size="221696">
<assemblyIdentity name="HtmlRenderer" version="1.5.0.5" language="neutral" processorArchitecture="msil" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>24PfjnyHf/sJFsFMmtbTH9TCfKqM9w/ueA9v7hWoFkA=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<dependency>
<dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="HtmlRenderer.WinForms.dll" size="60416">
<assemblyIdentity name="HtmlRenderer.WinForms" version="1.5.0.6" language="neutral" processorArchitecture="msil" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>WF/zxFwKgeKM8FANZnlU0EY/IhL18w1Px1iKE75KJWM=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<file name="Stretched Logo Collection.ico" size="370070">
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>EhpcVkhatavmpmzYIlqLL5P0WB1QFP8mU66foV/5u+c=</dsig:DigestValue>
</hash>
</file>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<!-- A list of the Windows versions that this application has been tested on and is
is designed to work with. Uncomment the appropriate elements and Windows will
automatically selected the most compatible environment. -->
<!-- Windows Vista -->
<!--<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />-->
<!-- Windows 7 -->
<!--<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}" />-->
<!-- Windows 8 -->
<!--<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />-->
<!-- Windows 8.1 -->
<!--<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />-->
<!-- Windows 10 -->
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />
</application>
</compatibility>
<application xmlns="urn:schemas-microsoft-com:asm.v3">
<windowsSettings>
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true/PM</dpiAware>
</windowsSettings>
</application>
</asmv1:assembly>
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xrml="urn:mpeg:mpeg21:2003:01-REL-R-NS" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
<assemblyIdentity name="AdvertsingProfitControl.application" version="1.0.0.1" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="amd64" xmlns="urn:schemas-microsoft-com:asm.v1" />
<description asmv2:publisher="AdvertsingProfitControl" asmv2:product="AdvertsingProfitControl" xmlns="urn:schemas-microsoft-com:asm.v1" />
<deployment install="true" mapFileExtensions="true" />
<compatibleFrameworks xmlns="urn:schemas-microsoft-com:clickonce.v2">
<framework targetVersion="4.5" profile="Full" supportedRuntime="4.0.30319" />
</compatibleFrameworks>
<dependency>
<dependentAssembly dependencyType="install" codebase="AdvertsingProfitControl.exe.manifest" size="6289">
<assemblyIdentity name="AdvertsingProfitControl.exe" version="1.0.0.1" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="amd64" type="win32" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>BdpMI18xuF58t84pN4xrCnguGw/WzgI8+4NoHv0AZ2Q=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
</asmv1:assembly>
@@ -0,0 +1,112 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
<asmv1:assemblyIdentity name="AdvertsingProfitControl.exe" version="1.0.0.1" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="amd64" type="win32" />
<description asmv2:iconFile="Stretched Logo Collection.ico" xmlns="urn:schemas-microsoft-com:asm.v1" />
<application />
<entryPoint>
<assemblyIdentity name="AdvertsingProfitControl" version="0.9.5.2" language="neutral" processorArchitecture="amd64" />
<commandLine file="AdvertsingProfitControl.exe" parameters="" />
</entryPoint>
<trustInfo>
<security>
<applicationRequestMinimum>
<PermissionSet version="1" class="System.Security.NamedPermissionSet" Name="LocalIntranet" Description="Default rights given to applications on the local intranet" Unrestricted="true" ID="Custom" SameSite="site" />
<defaultAssemblyRequest permissionSetReference="Custom" />
</applicationRequestMinimum>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
<!-- UAC Manifest Options
If you want to change the Windows User Account Control level replace the
requestedExecutionLevel node with one of the following.
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
<requestedExecutionLevel level="highestAvailable" uiAccess="false" />
Specifying requestedExecutionLevel element will disable file and registry virtualization.
Remove this element if your application requires this virtualization for backwards
compatibility.
-->
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
</requestedPrivileges>
</security>
</trustInfo>
<dependency>
<dependentOS>
<osVersionInfo>
<os majorVersion="5" minorVersion="1" buildNumber="2600" servicePackMajor="0" />
</osVersionInfo>
</dependentOS>
</dependency>
<dependency>
<dependentAssembly dependencyType="preRequisite" allowDelayedBinding="true">
<assemblyIdentity name="Microsoft.Windows.CommonLanguageRuntime" version="4.0.30319.0" />
</dependentAssembly>
</dependency>
<dependency>
<dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="AdvertsingProfitControl.exe" size="3511296">
<assemblyIdentity name="AdvertsingProfitControl" version="0.9.5.2" language="neutral" processorArchitecture="amd64" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>OJ71svPIgpljDYB7Isp1dyJ+HAA2f5EAkzyTUGfVCPE=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<dependency>
<dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="HtmlRenderer.dll" size="221696">
<assemblyIdentity name="HtmlRenderer" version="1.5.0.5" language="neutral" processorArchitecture="msil" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>24PfjnyHf/sJFsFMmtbTH9TCfKqM9w/ueA9v7hWoFkA=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<dependency>
<dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="HtmlRenderer.WinForms.dll" size="60416">
<assemblyIdentity name="HtmlRenderer.WinForms" version="1.5.0.6" language="neutral" processorArchitecture="msil" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>WF/zxFwKgeKM8FANZnlU0EY/IhL18w1Px1iKE75KJWM=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<file name="Stretched Logo Collection.ico" size="370070">
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>EhpcVkhatavmpmzYIlqLL5P0WB1QFP8mU66foV/5u+c=</dsig:DigestValue>
</hash>
</file>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<!-- A list of the Windows versions that this application has been tested on and is
is designed to work with. Uncomment the appropriate elements and Windows will
automatically selected the most compatible environment. -->
<!-- Windows Vista -->
<!--<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />-->
<!-- Windows 7 -->
<!--<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}" />-->
<!-- Windows 8 -->
<!--<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />-->
<!-- Windows 8.1 -->
<!--<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />-->
<!-- Windows 10 -->
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />
</application>
</compatibility>
<application xmlns="urn:schemas-microsoft-com:asm.v3">
<windowsSettings>
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true/PM</dpiAware>
</windowsSettings>
</application>
</asmv1:assembly>
@@ -0,0 +1,88 @@
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
td{margins:0px; padding:0; border:1px solid black; text-align:left} table{table-layout:fixed;} td{ width: 1px; white-space:nowrap; }
</style>
</head><body>
<table style="border-collapse: collapse">
<tr>
<td colspan="8" style="border:none; text-align:center; width:800px"><center>Weekly Inventory Control</center></td>
</tr><tr>
<td colspan="5" style="border:none; text-align:left">Name & Location</td><td colspan="3" style="border:none">Week Ending <u>1/9/2016</u></td>
</tr><tr>
<td colspan="5" style="height:15px; font-size:10px; text-align:center"><center>Purchases</center></td><td colspan="3" style="height:15px; font-size:10px; text-align:center"><center>Sales</center></td>
</tr><tr>
<td style="text-align:center">Date</td><td style="font-size:10px; text-align:center">Suppliers and Invoice Number</td><td style="font-size:10px; text-align:center">Net Amount of Invoices At Cost</td><td colspan="2" style="font-size:10px; text-align:center">Net Amount of <br>Invoices<br> Extended Retail</td><td>Sunday</td><td style="text-align:right">2,808</td><td>29</td>
</tr><tr>
<td>12/31/2015</td><td>1. Helgoth 1131</td><td>0.00</td><td style="text-align:right">540</td><td style="text-align:left; width:10px">00</td><td>Monday</td><td style="text-align:right">3,993</td><td>88</td>
</tr><tr>
<td>1/4/2016</td><td>2. Affilated Foods 420346</td><td>0.00</td><td style="text-align:right">325</td><td style="text-align:left; width:10px">31</td><td>Tuesday</td><td style="text-align:right">3,265</td><td>66</td>
</tr><tr>
<td>1/4/2016</td><td>3. Affilated Foods 420332</td><td>0.00</td><td style="text-align:right">5,234</td><td style="text-align:left; width:10px">30</td><td>Wednesday</td><td style="text-align:right">4,046</td><td>02</td>
</tr><tr>
<td>1/6/2016</td><td>4. Helgoth 1133</td><td>0.00</td><td style="text-align:right">525</td><td style="text-align:left; width:10px">00</td><td>Thursday</td><td style="text-align:right">3,612</td><td>90</td>
</tr><tr>
<td>1/6/2016</td><td>5. Affilated Foods 640007</td><td>0.00</td><td style="text-align:right">49</td><td style="text-align:left; width:10px">70</td><td>Friday</td><td style="text-align:right">3,551</td><td>91</td>
</tr><tr>
<td>1/6/2016</td><td>6. Affilated Foods 630117</td><td>0.00</td><td style="text-align:right">4,156</td><td style="text-align:left; width:10px">78</td><td>Saturday</td><td style="text-align:right">3,359</td><td>44</td>
</tr><tr>
<td>1/8/2016</td><td>7. Affilated Foods 840015</td><td>0.00</td><td style="text-align:right">207</td><td style="text-align:left; width:10px">75</td><td>TotalSales</td><td style="text-align:right">24,638</td><td>10</td>
</tr><tr>
<td>1/8/2016</td><td>8. Affilated Foods 830227</td><td>0.00</td><td style="text-align:right">6,542</td><td style="text-align:left; width:10px">70</td><td colspan="3" style="text-align:center">Taxable</td>
</tr><tr>
<td></td><td style="text-align:left">9.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td style="text-align:left">10.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td style="text-align:left">11.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td style="text-align:left">12.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td style="text-align:left">13.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td style="text-align:left">14.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td style="text-align:left">15.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td style="text-align:left">16.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td>17.</td><td></td><td></td><td></td><td colspan="3" style="text-align:center">Gross Profit</td>
</tr><tr>
<td></td><td style="text-align:left">18.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td style="text-align:left">19.</td><td></td><td></td><td></td><td></td><td></td><td></td>
</tr><tr>
<td></td><td>20.</td><td></td><td></td><td></td><td colspan="3" style="border-bottom:none">Dollar Gross Profit</td>
</tr><tr>
<td></td><td>21.</td><td></td><td></td><td></td><td style="border-top:none"></td><td style="text-align:right">7,056</td><td>56</td>
</tr><tr>
<td></td><td>Total Purchases</td><td></td><td></td><td></td><td colspan="3">% Gross Profit 41.9%</td>
</tr><tr>
<td></td><td>Less Transfer & Credits</td><td></td><td></td><td></td><td style="font-size:10px">Est. Wkly. Dept. Expense</td><td style="text-align:right">17,581</td><td>54</td>
</tr><tr>
<td></td><td>1.</td><td></td><td></td><td></td><td colspan="3" rowspan="2" style="border:none; font-size:12px">% Gross obtained by dividing<br>Total Sales into Gross Profit</td>
</tr><tr>
<td></td><td>2.</td><td></td><td></td><td></td><td colspan="2" style="border:none"></td><td style="border:none; border-right:1px solid black"></td>
</tr><tr>
<td></td><td>3.</td><td></td><td></td><td></td><td colspan="3" style="border:none">Manager_____________</td>
</tr><tr>
<td></td><td>4</td><td></td><td></td><td></td><td colspan="3" style="border:none"></td>
</tr><tr>
<td></td><td>5</td><td></td><td></td><td></td><td colspan="3" style="border:none"></td>
</tr><tr>
<td></td><td>6</td><td></td><td></td><td></td><td colspan="3" style="border:none"></td>
</tr><tr>
<td colspan="2">Total Purchases</td><td></td><td></td><td></td><td colspan="3" style="border:none"></td>
</tr><tr>
<td colspan="2">Less Total Transfers & Credits</td><td></td><td></td><td></td><td colspan="3" style="border:none"></td>
</tr><tr>
<td colspan="2">Net Purchases of Week</td><td></td><td></td><td></td><td colspan="3" style="border:none"></td>
</tr><tr>
<td colspan="2" style="border:none">Sales Per Man Hour_____</td><td colspan="3" style="border:none">Salary Percentage______</td><td colspan="3" style="border:none"></td>
</tr><tr>
<td colspan="2" style="border:none">Salary Dollars_____</td><td colspan="3" style="border:none">Supplies______</td><td colspan="3" style="border:none"></td>
</tr>
</table>
</body>
</html>
Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

@@ -0,0 +1,58 @@
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
th{margins:0; padding:0; vertical-align:bottom; height:35px; font-size:14px; border:1px solid black}td{margins:0; padding:0; border:1px solid black; font-size:14px; text-align:center; height:35px}
</style>
</head><body style="width:11in; height:8in">
<table style="margin-top:200px; width:100%">
<tr style="margin:0px; padding:0px">
<td style="font-size:14px; width:20%; vertical-align:bottom; border:none"><p>Store Name:<u> Allen's of Hastings</u></p></td><td style="width:50%; font-size:15px; margin:0px; padding: 0px 0px 0px 0px; border:none"><p><center><h2>Advertising Profit Control v 0.9.5.2</h2></center></p></td><td style="width:33%; padding: 0px 0px 0px 0px; margin:0px; border:none; vertical-align:bottom"><p><span style="margin-left:102px">Week Ending: <u>9/10/2016</u></span><br><span style="margin-left:86px">Department: <u>Produce</u></span></p></td>
</tr><tr style="margin:0px; padding:0px">
<td style="border:none"></td><td style="border:none"><p><span style="margin-right:280px">Projection</span><span>Actual</span></p></td><td style="border:none"><p style="margin-left:150px">Profit Analysis</p></td>
</tr>
</table><table style="border:none; border-collapse: collapse; width:11in; height:7.0in; table-layout:fixed">
<tr>
<th style="border-left:none">Ad Items</th><th style="background-color:#e9e9e9">Sold</th><th style="background-color:#e9e9e9">Sale<br>Price</th><th style="background-color:#e9e9e9">Total<br>Sales</th><th style="background-color:#e9e9e9">Cost</th><th style="background-color:#e9e9e9">$<br>Prof.<br>Retn.</th><th style="background-color:#e9e9e9">Total<br>$<br>Prof.<br>Retn.</th><th>Beg.<br>Inv.</th><th>Rec'd</th><th>Total</th><th>End.<br>Inv.</th><th>Sold</th><th>Sale<br>Price</th><th>Total<br>Sales</th><th>Cost</th><th>$<br>Prof.<br>Retn.</th><th>Total<br>$<br>Prof.<br>Retn.</th><td style="width:159px; border-right:none"><center>Department<br>Sales</center><p><span style="font-size:9px; vertical-align:bottom">1</span><span style="margin-left:60px">$0.00</span></p></td>
</tr><tr>
<td style="border:1px solid black; border-left:none"></td><td colspan="2" style="background-color:#e9e9e9; text-align:right">Total</td><td colspan="2" style="background-color:#e9e9e9; padding: 0px 0px 0px 5px">(A) $0.00</td><td colspan="2" style="background-color:#e9e9e9; padding: 0px 0px 0px 5px">(B) $0.00</td><td colspan="5" style="text-align:right">Total</td><td colspan="2" style="padding: 0px 0px 0px 5px">(A) $0.00</td><td></td><td colspan="2" style="padding: 0px 0px 0px 5px">(B) $0.00</td><td rowspan="2" style="border:none; border-right:1px solid black; border-right:none"><center style="margin-top:1px">Sales Produced By<br>Ad Items (A)</center><p><span style="font-size:9px; vertical-align:bottom">2</span><span style="margin-left:60px">$0.00</span></p></td><td rowspan="2" style="border:none; border-right:none"><center style="margin-top:1px">Sales Produced By<br>Ad Items (A)</center><p><span style="font-size:9px; vertical-align:bottom">2</span><span style="margin-left:60px">$0.00</span></p></td>
</tr><tr>
<td colspan="17" style="border-left:none"><b>Comments:</b> </td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td rowspan="2" style="border:none; border-top:1px solid black; border-right:none"><center style="margin-top:1px">Remaining<br>Sales</center><p><span style="font-size:9px; vertical-align:bottom">3</span><span style="margin-left:60px">$0.00 </span></p></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td rowspan="2" style="border:none; border-top:1px solid black; border-right:none"><center style="margin-top:1px;">Total $ Profit Return<br>From Ad Items (B)</center><p><span style="font-size:9px; vertical-align:bottom">4</span><span style="margin-left:60px">$0.00 </span></p></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td rowspan="2" style="border:none; border-top:1px solid black; border-right:none"><center style="margin-top:2px">Total $ Profit Return<br>From Remaining Sales</center><p><span style="font-size:9px; vertical-align:bottom">5</span><span style="margin-left:60px">$0.00</span></p></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td rowspan="2" style="border-right:none"><center style="margin-top:1px">Total $ Profit<br>Return</center><p><span style="font-size:9px; vertical-align:bottom">6</span><span style="margin-left:60px">$0.00</span></p></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr><tr>
<td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td><td style="border:none"></td>
</tr>
</table>
</body>
</html>
Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

+234
View File
@@ -0,0 +1,234 @@
namespace AdvertsingProfitControl
{
partial class FrmManageAdItems
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmManageAdItems));
this.mainLayoutPanel = new System.Windows.Forms.TableLayoutPanel();
this.adItemListView = new System.Windows.Forms.ListView();
this.columnOnePanel = new System.Windows.Forms.Panel();
this.deleteSelectedItem = new System.Windows.Forms.Button();
this.adItemFilterComboBox = new System.Windows.Forms.ComboBox();
this.letterSelectionLabel = new System.Windows.Forms.Label();
this.menuStrip1 = new System.Windows.Forms.MenuStrip();
this.fileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.closeFormFileMainMenu = new System.Windows.Forms.ToolStripMenuItem();
this.notificationLabel = new System.Windows.Forms.Label();
this.addItemButton = new System.Windows.Forms.Button();
this.adItemTextBox = new System.Windows.Forms.TextBox();
this.addItemLabel = new System.Windows.Forms.Label();
this.mainLayoutPanel.SuspendLayout();
this.columnOnePanel.SuspendLayout();
this.menuStrip1.SuspendLayout();
this.SuspendLayout();
//
// mainLayoutPanel
//
this.mainLayoutPanel.ColumnCount = 2;
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 45F));
this.mainLayoutPanel.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 55F));
this.mainLayoutPanel.Controls.Add(this.adItemListView, 1, 1);
this.mainLayoutPanel.Controls.Add(this.columnOnePanel, 0, 1);
this.mainLayoutPanel.Controls.Add(this.menuStrip1, 0, 0);
this.mainLayoutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.mainLayoutPanel.Location = new System.Drawing.Point(0, 0);
this.mainLayoutPanel.Margin = new System.Windows.Forms.Padding(2);
this.mainLayoutPanel.Name = "mainLayoutPanel";
this.mainLayoutPanel.RowCount = 3;
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 19F));
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.mainLayoutPanel.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.mainLayoutPanel.Size = new System.Drawing.Size(496, 445);
this.mainLayoutPanel.TabIndex = 0;
//
// adItemListView
//
this.adItemListView.Dock = System.Windows.Forms.DockStyle.Fill;
this.adItemListView.Location = new System.Drawing.Point(225, 21);
this.adItemListView.Margin = new System.Windows.Forms.Padding(2);
this.adItemListView.Name = "adItemListView";
this.mainLayoutPanel.SetRowSpan(this.adItemListView, 2);
this.adItemListView.Size = new System.Drawing.Size(269, 422);
this.adItemListView.Sorting = System.Windows.Forms.SortOrder.Ascending;
this.adItemListView.TabIndex = 5;
this.adItemListView.UseCompatibleStateImageBehavior = false;
this.adItemListView.View = System.Windows.Forms.View.Details;
//
// columnOnePanel
//
this.columnOnePanel.Controls.Add(this.addItemLabel);
this.columnOnePanel.Controls.Add(this.adItemTextBox);
this.columnOnePanel.Controls.Add(this.addItemButton);
this.columnOnePanel.Controls.Add(this.notificationLabel);
this.columnOnePanel.Controls.Add(this.deleteSelectedItem);
this.columnOnePanel.Controls.Add(this.adItemFilterComboBox);
this.columnOnePanel.Controls.Add(this.letterSelectionLabel);
this.columnOnePanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.columnOnePanel.Location = new System.Drawing.Point(2, 21);
this.columnOnePanel.Margin = new System.Windows.Forms.Padding(2);
this.columnOnePanel.Name = "columnOnePanel";
this.mainLayoutPanel.SetRowSpan(this.columnOnePanel, 2);
this.columnOnePanel.Size = new System.Drawing.Size(219, 422);
this.columnOnePanel.TabIndex = 1;
//
// deleteSelectedItem
//
this.deleteSelectedItem.Enabled = false;
this.deleteSelectedItem.Location = new System.Drawing.Point(9, 380);
this.deleteSelectedItem.Margin = new System.Windows.Forms.Padding(2);
this.deleteSelectedItem.Name = "deleteSelectedItem";
this.deleteSelectedItem.Size = new System.Drawing.Size(120, 33);
this.deleteSelectedItem.TabIndex = 4;
this.deleteSelectedItem.Text = "Delete Selected Item";
this.deleteSelectedItem.UseVisualStyleBackColor = true;
this.deleteSelectedItem.Click += new System.EventHandler(this.deleteSelectedItem_Click);
//
// adItemFilterComboBox
//
this.adItemFilterComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.adItemFilterComboBox.FormattingEnabled = true;
this.adItemFilterComboBox.Location = new System.Drawing.Point(81, 2);
this.adItemFilterComboBox.Margin = new System.Windows.Forms.Padding(2);
this.adItemFilterComboBox.Name = "adItemFilterComboBox";
this.adItemFilterComboBox.Size = new System.Drawing.Size(136, 21);
this.adItemFilterComboBox.TabIndex = 1;
//
// letterSelectionLabel
//
this.letterSelectionLabel.AutoSize = true;
this.letterSelectionLabel.Location = new System.Drawing.Point(6, 2);
this.letterSelectionLabel.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.letterSelectionLabel.Name = "letterSelectionLabel";
this.letterSelectionLabel.Size = new System.Drawing.Size(71, 13);
this.letterSelectionLabel.TabIndex = 0;
this.letterSelectionLabel.Text = "Select a filter:";
//
// menuStrip1
//
this.mainLayoutPanel.SetColumnSpan(this.menuStrip1, 2);
this.menuStrip1.ImageScalingSize = new System.Drawing.Size(24, 24);
this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.fileMainMenu});
this.menuStrip1.Location = new System.Drawing.Point(0, 0);
this.menuStrip1.Name = "menuStrip1";
this.menuStrip1.Padding = new System.Windows.Forms.Padding(4, 1, 0, 1);
this.menuStrip1.Size = new System.Drawing.Size(496, 19);
this.menuStrip1.TabIndex = 2;
this.menuStrip1.Text = "menuStrip1";
//
// fileMainMenu
//
this.fileMainMenu.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.closeFormFileMainMenu});
this.fileMainMenu.Name = "fileMainMenu";
this.fileMainMenu.Size = new System.Drawing.Size(37, 17);
this.fileMainMenu.Text = "&File";
//
// closeFormFileMainMenu
//
this.closeFormFileMainMenu.Name = "closeFormFileMainMenu";
this.closeFormFileMainMenu.Size = new System.Drawing.Size(152, 22);
this.closeFormFileMainMenu.Text = "&Close Form";
this.closeFormFileMainMenu.Click += new System.EventHandler(this.closeFormFileMainMenu_Click);
//
// notificationLabel
//
this.notificationLabel.AutoSize = true;
this.notificationLabel.Location = new System.Drawing.Point(9, 42);
this.notificationLabel.Name = "notificationLabel";
this.notificationLabel.Size = new System.Drawing.Size(0, 13);
this.notificationLabel.TabIndex = 3;
//
// addItemButton
//
this.addItemButton.Enabled = false;
this.addItemButton.Location = new System.Drawing.Point(116, 228);
this.addItemButton.Name = "addItemButton";
this.addItemButton.Size = new System.Drawing.Size(100, 32);
this.addItemButton.TabIndex = 3;
this.addItemButton.Text = "Add Item";
this.addItemButton.UseVisualStyleBackColor = true;
this.addItemButton.Click += new System.EventHandler(this.addItemButton_Click);
//
// adItemTextBox
//
this.adItemTextBox.Location = new System.Drawing.Point(116, 202);
this.adItemTextBox.Name = "adItemTextBox";
this.adItemTextBox.Size = new System.Drawing.Size(100, 20);
this.adItemTextBox.TabIndex = 2;
//
// addItemLabel
//
this.addItemLabel.AutoSize = true;
this.addItemLabel.Location = new System.Drawing.Point(19, 205);
this.addItemLabel.Name = "addItemLabel";
this.addItemLabel.Size = new System.Drawing.Size(77, 13);
this.addItemLabel.TabIndex = 6;
this.addItemLabel.Text = "Add New Item:";
//
// FrmManageAdItems
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(496, 445);
this.Controls.Add(this.mainLayoutPanel);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.MainMenuStrip = this.menuStrip1;
this.Margin = new System.Windows.Forms.Padding(2);
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "FrmManageAdItems";
this.Text = "Manage Ad Items";
this.Load += new System.EventHandler(this.frmManageAdItems_Load);
this.mainLayoutPanel.ResumeLayout(false);
this.mainLayoutPanel.PerformLayout();
this.columnOnePanel.ResumeLayout(false);
this.columnOnePanel.PerformLayout();
this.menuStrip1.ResumeLayout(false);
this.menuStrip1.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.TableLayoutPanel mainLayoutPanel;
private System.Windows.Forms.ListView adItemListView;
private System.Windows.Forms.Panel columnOnePanel;
private System.Windows.Forms.ComboBox adItemFilterComboBox;
private System.Windows.Forms.Label letterSelectionLabel;
private System.Windows.Forms.Button deleteSelectedItem;
private System.Windows.Forms.MenuStrip menuStrip1;
private System.Windows.Forms.ToolStripMenuItem fileMainMenu;
private System.Windows.Forms.ToolStripMenuItem closeFormFileMainMenu;
private System.Windows.Forms.Label notificationLabel;
private System.Windows.Forms.Label addItemLabel;
private System.Windows.Forms.TextBox adItemTextBox;
private System.Windows.Forms.Button addItemButton;
}
}
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?><trustInfo xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2"><security><applicationRequestMinimum><PermissionSet version="1" class="System.Security.NamedPermissionSet" Name="LocalIntranet" Description="Default rights given to applications on the local intranet" Unrestricted="true" ID="Custom" SameSite="site" /><defaultAssemblyRequest permissionSetReference="Custom" /></applicationRequestMinimum><requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3"><!-- UAC Manifest Options
If you want to change the Windows User Account Control level replace the
requestedExecutionLevel node with one of the following.
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
<requestedExecutionLevel level="highestAvailable" uiAccess="false" />
Specifying requestedExecutionLevel element will disable file and registry virtualization.
Remove this element if your application requires this virtualization for backwards
compatibility.
--><requestedExecutionLevel level="asInvoker" uiAccess="false" /></requestedPrivileges></security></trustInfo>
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xrml="urn:mpeg:mpeg21:2003:01-REL-R-NS" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
<assemblyIdentity name="AdvertsingProfitControl.application" version="1.0.0.1" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="amd64" xmlns="urn:schemas-microsoft-com:asm.v1" />
<description asmv2:publisher="AdvertsingProfitControl" asmv2:product="AdvertsingProfitControl" xmlns="urn:schemas-microsoft-com:asm.v1" />
<deployment install="true" mapFileExtensions="true" />
<compatibleFrameworks xmlns="urn:schemas-microsoft-com:clickonce.v2">
<framework targetVersion="4.5" profile="Full" supportedRuntime="4.0.30319" />
</compatibleFrameworks>
<dependency>
<dependentAssembly dependencyType="install" codebase="AdvertsingProfitControl.exe.manifest" size="6289">
<assemblyIdentity name="AdvertsingProfitControl.exe" version="1.0.0.1" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="amd64" type="win32" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>BdpMI18xuF58t84pN4xrCnguGw/WzgI8+4NoHv0AZ2Q=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
</asmv1:assembly>
@@ -0,0 +1,165 @@
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.config
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.pdb
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmAddRecord.resources
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmMain.resources
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.Properties.Resources.resources
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.pdb
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.LogConsole.resources
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.config
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.manifest
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.application
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.pdb
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmAddRecord.resources
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmMain.resources
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmShrink.resources
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.LogConsole.resources
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.Properties.Resources.resources
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.TrustInfo.xml
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe.manifest
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.application
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.pdb
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmAdSpecialRegister.resources
C:\Users\glmcc\Documents\Visual Studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmDeleteRecord.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.config
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.pdb
E:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.manifest
E:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.application
E:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe
E:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.pdb
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmAddRecord.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmAdSpecialRegister.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmDeleteRecord.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmMain.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmLogConsole.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmModifyRecord.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.Properties.Resources.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.TrustInfo.xml
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe.manifest
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.application
H:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.config
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.pdb
H:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.manifest
H:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.application
H:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe
H:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.pdb
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmAddRecord.resources
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmAdSpecialRegister.resources
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmDeleteRecord.resources
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmMain.resources
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmLogConsole.resources
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmModifyRecord.resources
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.Properties.Resources.resources
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.TrustInfo.xml
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe.manifest
H:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.application
I:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.config
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.pdb
I:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.manifest
I:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.application
I:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe
I:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.pdb
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmAddRecord.resources
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmAdSpecialRegister.resources
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmDeleteRecord.resources
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmMain.resources
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmLogConsole.resources
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmModifyRecord.resources
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.Properties.Resources.resources
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.TrustInfo.xml
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe.manifest
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.application
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.config
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.pdb
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.manifest
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.application
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.pdb
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmAddRecord.resources
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmAdSpecialRegister.resources
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmDeleteRecord.resources
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmMain.resources
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmLogConsole.resources
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmModifyRecord.resources
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.Properties.Resources.resources
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.TrustInfo.xml
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe.manifest
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.application
C:\Users\glmcc\Desktop\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.frmManageAdItems.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmManageAdItems.resources
I:\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmManageAdItems.resources
E:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.dll
E:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.pdb
E:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.WinForms.dll
E:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.WinForms.pdb
I:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.dll
I:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.WinForms.dll
I:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.pdb
I:\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.WinForms.pdb
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.pdb
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.manifest
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.application
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.pdb
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.dll
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.WinForms.dll
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.pdb
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.WinForms.pdb
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmAddRecord.resources
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmAdSpecialRegister.resources
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmDeleteRecord.resources
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmMain.resources
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmLogConsole.resources
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmManageAdItems.resources
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmModifyRecord.resources
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.Properties.Resources.resources
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.TrustInfo.xml
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe.manifest
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.application
C:\Users\glmcc\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.NewAddRecord.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.pdb
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe.manifest
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.application
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.exe
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\AdvertsingProfitControl.pdb
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.dll
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.WinForms.dll
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.pdb
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\Debug\HtmlRenderer.WinForms.pdb
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmAddRecord.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmAdSpecialRegister.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmDeleteRecord.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmMain.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmLogConsole.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmManageAdItems.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.FrmModifyRecord.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.NewAddRecord.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.Properties.Resources.resources
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.TrustInfo.xml
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.exe.manifest
C:\Users\Crypto\Documents\Visual Studio 2015\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\Debug\AdvertsingProfitControl.application
@@ -0,0 +1,112 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
<asmv1:assemblyIdentity name="AdvertsingProfitControl.exe" version="1.0.0.1" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="amd64" type="win32" />
<description asmv2:iconFile="Stretched Logo Collection.ico" xmlns="urn:schemas-microsoft-com:asm.v1" />
<application />
<entryPoint>
<assemblyIdentity name="AdvertsingProfitControl" version="0.9.5.2" language="neutral" processorArchitecture="amd64" />
<commandLine file="AdvertsingProfitControl.exe" parameters="" />
</entryPoint>
<trustInfo>
<security>
<applicationRequestMinimum>
<PermissionSet version="1" class="System.Security.NamedPermissionSet" Name="LocalIntranet" Description="Default rights given to applications on the local intranet" Unrestricted="true" ID="Custom" SameSite="site" />
<defaultAssemblyRequest permissionSetReference="Custom" />
</applicationRequestMinimum>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
<!-- UAC Manifest Options
If you want to change the Windows User Account Control level replace the
requestedExecutionLevel node with one of the following.
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
<requestedExecutionLevel level="highestAvailable" uiAccess="false" />
Specifying requestedExecutionLevel element will disable file and registry virtualization.
Remove this element if your application requires this virtualization for backwards
compatibility.
-->
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
</requestedPrivileges>
</security>
</trustInfo>
<dependency>
<dependentOS>
<osVersionInfo>
<os majorVersion="5" minorVersion="1" buildNumber="2600" servicePackMajor="0" />
</osVersionInfo>
</dependentOS>
</dependency>
<dependency>
<dependentAssembly dependencyType="preRequisite" allowDelayedBinding="true">
<assemblyIdentity name="Microsoft.Windows.CommonLanguageRuntime" version="4.0.30319.0" />
</dependentAssembly>
</dependency>
<dependency>
<dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="AdvertsingProfitControl.exe" size="3511296">
<assemblyIdentity name="AdvertsingProfitControl" version="0.9.5.2" language="neutral" processorArchitecture="amd64" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>OJ71svPIgpljDYB7Isp1dyJ+HAA2f5EAkzyTUGfVCPE=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<dependency>
<dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="HtmlRenderer.dll" size="221696">
<assemblyIdentity name="HtmlRenderer" version="1.5.0.5" language="neutral" processorArchitecture="msil" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>24PfjnyHf/sJFsFMmtbTH9TCfKqM9w/ueA9v7hWoFkA=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<dependency>
<dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="HtmlRenderer.WinForms.dll" size="60416">
<assemblyIdentity name="HtmlRenderer.WinForms" version="1.5.0.6" language="neutral" processorArchitecture="msil" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>WF/zxFwKgeKM8FANZnlU0EY/IhL18w1Px1iKE75KJWM=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<file name="Stretched Logo Collection.ico" size="370070">
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>EhpcVkhatavmpmzYIlqLL5P0WB1QFP8mU66foV/5u+c=</dsig:DigestValue>
</hash>
</file>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>
<!-- A list of the Windows versions that this application has been tested on and is
is designed to work with. Uncomment the appropriate elements and Windows will
automatically selected the most compatible environment. -->
<!-- Windows Vista -->
<!--<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />-->
<!-- Windows 7 -->
<!--<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}" />-->
<!-- Windows 8 -->
<!--<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />-->
<!-- Windows 8.1 -->
<!--<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />-->
<!-- Windows 10 -->
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />
</application>
</compatibility>
<application xmlns="urn:schemas-microsoft-com:asm.v3">
<windowsSettings>
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true/PM</dpiAware>
</windowsSettings>
</application>
</asmv1:assembly>
@@ -0,0 +1,10 @@
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\x64\Debug\apc.accdb
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\x64\Debug\AdvertsingProfitControl.exe.config
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\x64\Debug\AdvertsingProfitControl.exe
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\x64\Debug\AdvertsingProfitControl.pdb
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x64\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x64\Debug\AdvertsingProfitControl.frmMain.resources
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x64\Debug\AdvertsingProfitControl.Properties.Resources.resources
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x64\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x64\Debug\AdvertsingProfitControl.exe
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x64\Debug\AdvertsingProfitControl.pdb
@@ -0,0 +1,10 @@
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\x86\Debug\AdvertsingProfitControl.exe.config
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\x86\Debug\AdvertsingProfitControl.exe
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\x86\Debug\AdvertsingProfitControl.pdb
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x86\Debug\AdvertsingProfitControl.csprojResolveAssemblyReference.cache
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x86\Debug\AdvertsingProfitControl.frmMain.resources
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x86\Debug\AdvertsingProfitControl.Properties.Resources.resources
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x86\Debug\AdvertsingProfitControl.csproj.GenerateResource.Cache
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x86\Debug\AdvertsingProfitControl.exe
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\obj\x86\Debug\AdvertsingProfitControl.pdb
C:\Users\Crypto\documents\visual studio 2012\Projects\AdvertsingProfitControl\AdvertsingProfitControl\bin\x86\Debug\apcDatabase.accdb
+7
View File
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="HtmlRenderer.Core" version="1.5.0.5" targetFramework="net45" />
<package id="HtmlRenderer.PdfSharp" version="1.5.0.6" targetFramework="net45" />
<package id="HtmlRenderer.WinForms" version="1.5.0.6" targetFramework="net45" />
<package id="PDFsharp" version="1.32.3057.0" targetFramework="net45" />
</packages>