What’s up guys?! A couple of weeks has passed since my last post, but here I am again to give you a very easy and nice way to convert a Word file (by Word, read .docx, .doc, .rtf, etc) to a PDF. I have searched a lot on the internet about conversion to PDF and it’s not something easy, although it is simple to understand this code I am going to give.
First of all, to get this tutorial working correctly, you MUST have Office installed in your computer. Otherwise it won’t work. You have plenty of other tutorials even using iTextSharp to create your PDF or Java using JodConverter and OpenOffice like this.
Read the rest of this entry »
Tags: .net, c#, convert, csharp, doc, docx, dotnet, pdf, rtf, word
What’s up guys?! I’m here again to talk a little bit more about database, on the other hand, it is not SQL Server nomore but Postgres. I’m working on a project that had a must-be-Postgres moment and before that I had worked with this database and C# once, in 2009. So, lots of thing changed since then.

Well, today I’m working with Npgsql…
… “Npgsql is a .Net Data Provider for Postgresql. It allows any program developed for .Net framework to access database server. It is implemented in 100% C# code. Works with Postgresql 7.x and above.”
Shall we?
Read the rest of this entry »
Tags: c#, csharp, database, dotnet, postgres, query, reflection, sql
What’s up guys?! I just wanted to say that I’m very happy cause of this blog, nowadays it’s around 100+ views per day, it makes me want to update here more! Speaking of which, I’m here today to show you a nice way to work with files in your database, no matter if it’s a .pdf, .doc or .jpg file.

Just want to make it clear, there are different ways to do the same thing, I’m just more confortable working with this one because it fits to me.
Read the rest of this entry »
Tags: .net, blob, c#, csharp, doc, dotnet, files, jpg, pdf, varbinary
What’s up guys?! Here I am again to show you a little bit of asynchronous communication in C#. A few months ago I ended up developing an application and learning more about asynchronous stuff. It’s pretty easy, MSDN documentation is pretty clear so I’ll try to be focus here.

If you’d like to read before getting started, check this out.
Read the rest of this entry »
Tags: asynchronous, c#, chat, csharp, dotnet, socket
Hello everybody! Again, after a long while without any single post here I am. Based on wordpress statistics, people are always looking for “c#, graphs, plot”.

So, since there’s already a post here explaining how to do that in a very simple way, I’m going to show you another way to do the same thing, using a powerful tool called ZedGraph.
“ZedGraph is a class library, user control, and web control for .net, written in C#, for drawing 2D Line, Bar, and Pie Charts. It features full, detailed customization capabilities, but most options have defaults for ease of use.”
Read the rest of this entry »
Tags: c#, chart, charting, csharp, graphs, vs2010, zedgraph
Hello everybody! After a long time without any single post, I’m back here to give you an awesome tip. How to use git for your C# projects, and the best part, with Dropbox, so you can access your files wherever you are. (Ok, that’s a little too much).
Git is a tool to control revision and you can find everything in here, the official website.



For my C# environment I use Windows 7 and Visual Studio 2010, if you have the same, I totally recommend that you install a gitBash, it can be easily downloaded and installed from here.
Read the rest of this entry »
Tags: c#, csharp, dotnet, dropbox, git, gitignore, visualstudio, vs2010
Hello people! It’s been an era since my last post, I’ve been busy and.. must confess, a little bit lazy to post here. But (again) I will try to keep this blog alive, since I’m dealing with different kind of problems every single day, I have a lot to contribute.

It was no different today, I had to deal with a simple thing, how to place my application in the System Tray, simple, huh? But I had never done it before, so I’m going to do it in 4 quick steps. There’s no mistake.
Read the rest of this entry »
Tags: .net, c#, csharp, dotnet, system tray, systray

Hello People! I’ve been busy and had no time for a new post, but I got into a curious situation two weeks ago, that was the first time I actually needed to work with different threads in C#, in this case, my application would not be busy while processing.
I know there are a lot of tutorials on the internet explaining about threads, so I decided to build an small application using Treads (really?), Reflection and Delegate, so it can be used in your app also.
First of all, you know understand a little bit of those important concepts very common in C#. So, I recommend that you take a look at those web sites:
Threads: http://msdn.microsoft.com/en-us/library/ms173178(v=vs.80).aspx
Reflection: http://msdn.microsoft.com/en-us/library/ms173183(v=vs.80).aspx
Delegate: http://msdn.microsoft.com/en-us/library/ms173171(v=vs.80).aspx
Well, since you already understand their purpose, let’s work on our code.
Read the rest of this entry »
Tags: "accessed from a thread other than the thread it was created on", .net, c#, csharp, dotnet, threads, visualstudio, vs2010
Ola, amigos! Here I am again to another tutorial. This time I’m going to give you a brief tutorial teaching you how to plot graphs using a component called Chart, its recommended for you to take a look at its documentation before.

Well, for almost for years developing in C#, last month was the first time I ended up drawing graphs in an application I’m developing. After a couple of hours looking at the internet, I found an easy way to do it. You only need to add the coordinates, x and y, or only one of those and that’s it. It’s done!
Read the rest of this entry »
Tags: .net, c#, chart, charting, draw, graphs, plot, visualstudio, vs2010
Hallo zusammen! Hello everybody! Wow, it’s been more than a month since my last post here. Things have been really rough at University. I’ll try again to keep a post per week, I have a job now as a .NET developer, so probably there will be more posts about C# than Rails.
But nothing’s lost yet! I’m still having fun with RoR at home when it’s possible.
And I came here today for a quick post and great tip for you, Rails beginner developer.

Well, I’m now using Ubuntu 11.04, since its release. Personally, I’m finding it awesome. For sure there are still a few bugs, but, I hardly recommend it. And since I’m still using Ubuntu, gedit/gmate is my favorite one.
Read the rest of this entry »
Tags: gedit, gmate, rails, ror, ruby, ubuntu