Skip to content

Commit 4a0e7bf

Browse files
committed
some upd
Readme updated Changelog updated Binaries updated
1 parent 1cc69cf commit 4a0e7bf

File tree

7 files changed

+49
-34
lines changed

7 files changed

+49
-34
lines changed

README.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
# WinCCflexLogViewer
22

3-
WinCCflexLogViewer is a lightweight and simple-to-use WinCC Flexible and TIA Portal Data log Analyzer.
4-
Supports CSV (*.csv, *.txt) and SQLite (*.rdb) data formats.
5-
Allows to export parsed log data to CSV table for Excel etc.
3+
WinCCflexLogViewer is a lightweight and simple-to-use WinCC Flexible and TIA Portal Data log Viewer / Analyzer.
64

7-
The tool is a stand-alone GUI application developed in C# language and requires DotNet Framework 3.5 or higher.
5+
Supports CSV (*.csv, *.txt) and SQLite (*.rdb) Siemens data log formats.
6+
7+
Allows to export parsed log data to CSV file (for further analysis e.g.), print selected curves.
8+
9+
The tool is a stand-alone GUI application developed in C# language and requires .Net Framework 3.5 or higher.
810

911
## Thanks to
10-
**plc2k**
12+
**plc2k** http://plc2k.com/wincc-flexible-tia-portal-archive-viewer/
13+
**ZedGraph** https://github.com/ZedGraph/ZedGraph

WinCCFlexArchViewer/About.Designer.cs

Lines changed: 20 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

WinCCFlexArchViewer/About.resx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -120,14 +120,14 @@
120120
<data name="label4.Text" xml:space="preserve">
121121
<value>Mouse Controls:
122122
Pan: mouse wheel button
123-
Zoom In/Out: mouse wheel
123+
Zoom In/Out: mouse wheel
124124
Zoom Selection: mouse left
125-
Menu: mouse right button
125+
Menu: mouse right button
126126

127127
Command line arguments:
128128
-f "filename" open specified file
129129
-fullscreen start in fullscreen mode
130-
-hidefilebutton hide openfile button
131-
-hideprintbutton hide print button</value>
130+
-nofilebutton hide openfile button
131+
-noprintbutton hide print button</value>
132132
</data>
133133
</root>

WinCCFlexArchViewer/Main.Designer.cs

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

WinCCFlexArchViewer/Main.cs

Lines changed: 15 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,9 @@ public Main()
5858
DTrend.Selection.SelectionChangedEvent += new EventHandler(Selection_SelectionChangedEvent);
5959
DTrend.GraphPane.AxisChange();
6060
DTrend.Refresh();
61-
string[] commandLineArgs = Environment.GetCommandLineArgs();
62-
63-
// Парсинг аргументов командной строки
64-
for (int i = 0; i < commandLineArgs.Length; i++)
61+
string[] commandLineArgs = Environment.GetCommandLineArgs();
62+
63+
for (int i = 0; i < commandLineArgs.Length; i++) // Парсинг аргументов командной строки
6564
{
6665
string path = "";
6766
string a = commandLineArgs[i];
@@ -83,14 +82,13 @@ public Main()
8382
FormBorderStyle = FormBorderStyle.None;
8483
WindowState = FormWindowState.Maximized;
8584
}
86-
else if (a == "-hidefilebutton")
85+
else if (a == "-nofilebutton")
8786
{
8887
fileToolStripMenuItem.Visible = false;
8988
}
90-
else if (a == "-hideprintbutton")
89+
else if (a == "-noprintbutton")
9190
{
92-
printMenuItem.Visible = false;
93-
button_print.Visible = false;
91+
printMenuItem.Visible = button_print.Visible = false;
9492
}
9593
}
9694
}
@@ -281,7 +279,7 @@ private void parse_data(object sender, DoWorkEventArgs e)
281279
flag = 0;
282280
foreach (string text5 in list) //
283281
{
284-
if (flag == 0) flag++; //
282+
if (flag == 0) flag++;
285283
else
286284
{
287285
string[] array2 = text5.Split( new char[]{c} ); // Получаем массив элементов из строки списка лога
@@ -357,13 +355,14 @@ private void dataparsing_complete(object sender, RunWorkerCompletedEventArgs e)
357355
}
358356
num2++;
359357
}
358+
Color color = ColorTranslator.FromHtml(colors[numColor]);
360359
YAxis yaxis = new YAxis(text);
361360
DTrend.GraphPane.YAxisList.Add(yaxis);
362361
yaxis.Title.IsVisible = true;
363362
yaxis.Type = AxisType.Linear;
364-
yaxis.Color = ColorTranslator.FromHtml(colors[numColor]);
363+
yaxis.Color = color;
365364
yaxis.Scale.FontSpec.Size = 10f;
366-
yaxis.Scale.FontSpec.FontColor = ColorTranslator.FromHtml(colors[numColor]);
365+
yaxis.Scale.FontSpec.FontColor = color;
367366
yaxis.IsVisible = true;
368367
yaxis.Scale.MaxAuto = true;
369368
yaxis.Scale.MinAuto = true;
@@ -375,13 +374,13 @@ private void dataparsing_complete(object sender, RunWorkerCompletedEventArgs e)
375374
yaxis.MinorTic.IsOpposite = false;
376375
yaxis.Scale.Align = AlignP.Inside;
377376
yaxis.Title.FontSpec.Size = 10f;
378-
yaxis.Title.FontSpec.FontColor = ColorTranslator.FromHtml(colors[numColor]);
379-
Color color = ColorTranslator.FromHtml(colors[numColor]);
377+
yaxis.Title.FontSpec.FontColor = color;
378+
380379
LineItem lineItem = DTrend.GraphPane.AddCurve(text, pointPairList, color, SymbolType.None);
381380
lineItem.Line.IsOptimizedDraw = true;
382381
lineItem.Line.Width = 2f;
383382
lineItem.YAxisIndex = DTrend.GraphPane.YAxisList.IndexOf(text);
384-
dataGridView_data.Columns[text].DefaultCellStyle.ForeColor = ColorTranslator.FromHtml(colors[numColor]);
383+
dataGridView_data.Columns[text].DefaultCellStyle.ForeColor = color;
385384
ToolStripMenuItem toolStripMenuItem = new ToolStripMenuItem(text);
386385
toolStripMenuItem.ForeColor = ColorTranslator.FromHtml(colors[numColor]);
387386
ToolStripMenuItem toolStripMenuItem2 = new ToolStripMenuItem("hide/show");
@@ -443,7 +442,7 @@ private void setYminMax(object sender, EventArgs e)
443442
DTrend.Refresh();
444443
}
445444

446-
//
445+
//Устанавливает чек итема в соответствии с видимостью курвы
447446
private void toolMnuItemChSta(object sender, EventArgs e)
448447
{
449448
((ToolStripMenuItem)sender).Checked = DTrend.GraphPane.CurveList[((ToolStripMenuItem)sender).OwnerItem.Text].IsVisible;
@@ -546,8 +545,7 @@ private void fullscreenToolStripMenuItem_Click(object sender, EventArgs e)
546545
{
547546
FormBorderStyle = FormBorderStyle.Sizable;
548547
WindowState = FormWindowState.Normal;
549-
}
550-
548+
}
551549
}
552550

553551
//
@@ -838,7 +836,6 @@ private void Selection_SelectionChangedEvent(object sender, EventArgs e)
838836
curve.IsSelected = false;
839837
}
840838
}
841-
842839
}
843840
}
844841
}
512 Bytes
Binary file not shown.

changelog.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
1.9
2+
Simplified commandline args.
23
XAxis labels are now showing in 2 lines.
34
Other UI fixes.
45

0 commit comments

Comments
 (0)