.NET Open Source Softwares

Open source softwares written in VB .NET and C#

Blogger Backup

The Blogger Backup Utility is an open source software to backup existing blogger.com blogs/posts to your local hard drive. It uses the GData C# Library and it can backup your latest post up to the most earliest blog entry. It save each post as XML file.

AUTHOR
gduncan411

PLATFORM
Framework: Microsoft .NET Framework 3.5
IDE: Visual Studio 2008

BEST PRACTICE FOR
File and Data Streams

SAMPLE SCREENSHOTS

Blogger Backup main screen

Blogger Backup main screen

Blogger backup add blogger account

Blogger backup add blogger account

Blogger backup process

Blogger backup process

DOWNLOAD URL
You can download the setup package from here
via CodePlex
Full source code here
via CodePlex

Filed under: VB .NET , ,

Computer Performance Monitoring Tool

Computer Monitoring Tool can track resource performance of multiple machine across the network. It displays CPU percentage, Memory Available and Disk Usage. This is perfect for system administrators who want to be alerted on probable system downtime. Aside from resources utilization, it also alert stakeholders if a server/machine is offline. It Uses WMI Classes to get the data from another computer. This tool is just a major revision of an existing performance monitoring I found at Codeproject.com (sorry forgot the page. credit to the author). It adapted the WMI coding style from that project, added a database and included a lot more features.

AUTHOR
foxtrot0911

PLATFORM
Framework: Microsoft .NET Framework 2.0
IDE: Visual Studio 2005

BEST PRACTICE FOR
Windows Management Instrumentation

SAMPLE SCREENSHOTS

Computer Monitoring Tool

Computer Monitoring Tool

Machines maintenance

Machines maintenance

Stakeholders Maintenance

Stakeholders Maintenance

Processes Tab

Processes Tab

SAMPLE CODES/TECHNIQUES
Here’s how to connect to remote computer’s WMI database

if (Dns.GetHostName() == strHostName)
{
mgmtScope = new ManagementScope(“\\\\” + strHostName+ “\\root\\cimv2″);
}
else
{
options = new ConnectionOptions();
options.Username = strUserName;
options.Password = strPassword;

// scope object for remote machine
mgmtScope = new ManagementScope(“\\\\” + strHostName + “\\root\\cimv2″,options);

}

// connect to machine to monitor. Return 0 if not able to connect
try
{
mgmtScope.Connect();
}
catch (System.UnauthorizedAccessException)
{
return 0;
}
catch (System.Runtime.InteropServices.COMException)
{
return 0;
}
catch
{
return 0;
}

To get the CPU utilization, call the WMI query “Win32_PerfRawData_PerfOS_Processor”

// CPU %
mPath_CPU = new ManagementPath();
mPath_CPU.RelativePath = “Win32_PerfRawData_PerfOS_Processor.Name=’0′”;
mObject_CPU = new ManagementObject(mgmtScope,mPath_CPU,null);

To retrieve available memory, use “Win32_PerfRawData_PerfOS_Memory”

mPath_Mem = new ManagementPath();
mPath_Mem.RelativePath = “Win32_PerfRawData_PerfOS_Memory”;
mc = new ManagementClass(mgmtScope,mPath_Mem,null);

DOWNLOAD URL
You can download the setup package from here
From Mediafire/Setup executable
Full source code here
From Mediafire/Source Code

Filed under: C# , , , ,

Proxy Log Analyzer

Proxy log analyzer can parse various web proxy logĀ  formats and display it in a spreadsheet form. Using this software, Administrator can monitor frequent sites visited by each internet user. The software can maintain list of IPs and its corresponding owner. Each column on the spreadsheet can be sorted so the administrator can view the proxy log by IP, owner, datetime and website visited.

AUTHOR
foxtrot0911

PLATFORM

Framework: Microsoft .NET Framework 3.5
IDE: Visual C# 2008 Express Edition

BEST PRACTICE FOR

Reading files using StreamReader
Use of LINQ to query from Collection

SAMPLE SCREENSHOTS

Proxy log reader

Proxy log reader

Spreadsheet viewer

Spreadsheet viewer

SAMPLE CODES/TECHNIQUES
Below is the code for reading the log file. It uses StreamReader namespace to parse the file line by line.

private bool ReadLog(string LogPath)
{
bool lreturn = true;

FileInfo[] d;
DirectoryInfo dir = new DirectoryInfo(@LogPath);
if (dir.Exists)
{
d = dir.GetFiles(Settings.Default.LOG_EXTENSION);

foreach (FileInfo f in d)
{
try
{
WriteLog(“Reading file ” + f.Name + “…”);
StreamReader tmpstream = File.OpenText(@f.FullName);
string strraw = tmpstream.ReadLine();
while (strraw != null)
{
string[] strinfo1 = strraw.Split(new string[] { ” – - ” }, StringSplitOptions.None);
string[] strcmd = ReadRaw(strinfo1[1]).Split(new char[] { ‘|’ });
WriteLog(“Inserting to database the reading from ” + strinfo1[0] + “…”);
if (SaveToDB(strinfo1[0], strcmd))
{
WriteLog(“Successfully inserted.”, Color.Blue);
}
strraw = tmpstream.ReadLine();

}
tmpstream.Close();
WriteLog(“Moving file to ” + @Settings.Default.FINISH_FOLDER);
f.MoveTo(@Settings.Default.FINISH_FOLDER + “\\” + f.Name);
}
catch (Exception ex)
{
lreturn = false;
WriteLog(“Error while reading file. ” + ex.Message, Color.Red);
}
}
}
else
{
WriteLog(“Directory does not exist. “, Color.Red);
}
return lreturn;
}

Query from Class collection using LINQ

clsAccountables accs = new clsAccountables();
var linqaccs = (from clsAccountable o in accs
where o.Accountable.Trim().ToLower() != “test”
select o.Accountable).Distinct();
cboAccountable.Items.Clear();
cboAccountable.Items.Add(“Unknown”);
foreach (var linqacc in linqaccs)
{
cboAccountable.Items.Add(linqacc.ToString());
}

DOWNLOAD URL
You can download the full source code on the following location:

From Mediafire

From FileFactory

From morefreesoftware.com

Filed under: C# , , , , , , , ,

Hello wordpress! ~foxtrot0911

Hi! I am fryan the owner of www.fryan0911.com. Today, i will launch my new blog here at wordpress. This blog will contain open source softwares that were created using Microsoft .NET technology. Most of these softwares were originally developed by myself but I will also try to post some sourcecodes from other people which I think will be useful for .NET beginners. My target readers are those who are starting to know .NET programming such asVB.NET and C#. Although users who just want to download useful free software or those who simply interested are very welcome too. Each of my post will be in the following format:

TITLE

DESCRIPTION

AUTHOR

PLATFORM

BEST PRACTICE FOR

SAMPLE SCREENSHOTS

SAMPLE CODES/TECHNIQUES

DOWNLOAD URL

Aside from this blog, you can also visit my other sites:

Tech Blog – www.fryan0911.com

Free Software Collection – www.morefreesoftware.com

Beginner Guides Portal – www.beginnerguideplus.com

My goal is to help readers as many as I can. That’s it for my first post. Good luck to us all!

Filed under: C#, VB .NET , , , , , ,