Wednesday 13 March 2013

Seo networking blog

Thought this would be helpful to share this blog to my readers. It's a seo blog. Seo is very important for freelance coders or anyone who wants to get there website seen.

Seo networking blog

New study subject


Today, I begin studying Component Services. I always wanted to tried learning about this subject. And here I am, and I will try to do my best !

Presentation


Hi, my name is james. I will not detail my life, because you are probably not interested in that. I have a computer since I have 12-13 years old. I begin programming (real programming) 2 years ago. So, I studied in a private school to learn programming because I wanted to to a career in that. I have learned abit of C, a bit of C++, Java, SQL, and VB6. I can say that we haven't really learned a lot in a particular language. At the end of the year,I got a training course in a company that develops in VB.NET. This is where it got interesting... I enjoyed .NET. Not just VB.NET but also C# and Managed C++. This is where I became to really love programming. I havedone 2 certifications since this date, and I am currently studying for the third to get my MCAD title. And now, I am more open to otherlanguages, such as C and Java.

MCAD Training - Part 1

I just got through XML Web Services and they talk a lot about Serialization and I found out that they don't really go through the explanation of what is happening in the process. So I borrowed a book from a friend called "Designing Enterprise Applications with Visual Basic.Net. This book clears every single question I had. I think that I can't post the text from the book, so here is a link on MSDN abot that. Sorry C# guys, but you will have to translate. I don't think this a problem anyway :).

Windows Service


At first, I didn't want to begin a journey on this subject. But then I begin reading this chapter today ... and what the .. it was something very easy to do with Visual Studio.

Step 1 : Add code to the OnStart, OnStop, OnContinue and OnPause.
Step 2 : Go to the designer of the Web Service. Right-Click, Add Installer.
Step 3 : Go to the Bin directory
Step 4 : installutil nameofyourapp.exe
Step 5 : Enjoy

English


Oooh and I forgot to say that English is not my primary language, but I will try the most as I can to get better. Sorry.

Tips and tricks


Today, I have tried FxCop from GotDotNet, and the first warning was about the assembly not marked with ComVisible attribute. What this attribute does in fact is to limit access to components from Vb6 or else, to your assembly. Here is how you can do that:

Step 1: Open AssemblyInfo file.
Step 2: Add this or if needed.)

So it's all. I hope this is a worthy advice.

Mistake


Well, we all do some mistake in our life, and yesterday I have done a big one, believe me. I erased one client on the client server by mistake. Fortunately, they have a backup. Right now, I am restoring one of them on my SQL Server, and it will probably take a long time.

We all learn from mistake and I will share with you what I have done to recover everything.

The most important is to admit that your the one who have done that. You'll be better after.
Get the backup file. Restore it using Enterprise Manager/All task/Restore Database.
If it's on a .Bak file, choose the "From Device" option. In the Options Tab modify the path to point over to your SQL Server and Database file. Click Ok. Done!

Little program


I have just finished working on a little program that converts a SQL Select statement to an Insert statement. It's really simple and I will try to post it somewhere on the web, and as soon as I can, I will give you the link.

.Net Reflecto


I want to show you a program that I have just discovered on http://www.aisto.com/roeder/dotnet/. It's called the Lutz Roeder's .Net Reflector. I highly recommend it because it allows you to check everything that is contained in a dll (or .exe) and it can show you the code in C#, Vb, IL and Delphi. Great tool!!!

Pragmatic Programmer


If you are searching for a great book to learn about programming, read Pragmatic Programmer. Advices in this book are all great, and can you only become better. I just can't believe how much this book is usefull. Go there to take a look at it.

TOP @n in T-SQL



Today I was trying to select a predetermined number of rows in a table. I tried passing a parameter to the TOP operator.. Syntax Error.

SELECT TOP @n ID FROM TableName

After a small research I found two solutions to this problem.

First, the SET ROWCOUNT. This example explain everything :

SET ROWCOUNT @n
SELECT ID FROM TableName
SET ROWCOUNT 0

Then the second is with dynamic SQL :

use Northwind
declare @a int, @str varchar(100)
set @a = 10set @str = 'select top ' + cast(@a as varchar(100)) + ' * from Orders'exec (@str)

A little more complex, but worth to take a look at it.

Oh and also, on the new SQL Server that will be coming soon, this problem is solved and you can pass parameter to the TOP operator.

Unable to access HTTPS



This weekend, I had to face this problem. I had search for about 2 hours what could have caused that. With no success at all. Then (nothing to loose) I installed TuneUp 2004 Trial version, to see something I haven’t seen. Then it tells me there was a Norton Internet Security installation in progress... It was the problem. So for uninstalling the pending installation (?), I usedthe rnav2003.exe, but it did not worked. So I finished the installation with all the error I could get, and then uninstalled it successfully. And everything was back to normal. Ohh and it wasn’t my computer of course. :P

Logging In IIS


You can use Response.AppendToLog( string ). It's the most efficient way to do it. You must also not forget to check the Uri Query box. Here is the way to do this :

1. Open IIS.
2. Navigate to the Web Site (default : Default Web Site)
3. Properties.
4. Go to the log properties
5. Extended properties
6. Check Uri Query
7. Apply

Here you go.

Logging In IIS


You can use Response.AppendToLog( string ). It's the most efficient way to do it. You must also not forget to check the Uri Query box. Here is the way to do this :

1. Open IIS.
2. Navigate to the Web Site (default : Default Web Site)
3. Properties.
4. Go to the log properties
5. Extended properties
6. Check Uri Query
7. Apply

Here you go.

Code generator software

Well, today I tested several Code Generator on the market, and found out that it is not an easy world. People say that we should not re-develop something that has been done before. So my expectations were lowered a bit, but I will continue to work on it, and "do exactly what I wanted to do". But for those you are interested in this kind of software, you should take a look at MyGeneration. Excellent software in my opinion.

Code generator 1.0

Since I begin programming, I have this dream of generating automatically my data access code, and finally this day has come. So today, I have done some work concerning the parameters of Stored Procedure. At first, I wanted to retrieve the stored procedure's text and parse it to get all the parameters, type and so on. But I checked on Data Access Application Block from Microsoft and found out that I can derive parameters with an instance of a command object to get everything I need. It can't be better. So I think to put my project on some site (probably GotDotNet) and share with you my entire advance. Oh and I forgot to mention that it will use the codedom namespace eventually.

It's been a long time



I've been very busy those days, so I didn't post anything. But now I have a few minutes, so why not. I have to recommend you a book intituled Design Pattern written by Gamma, Helm, Johnson and Vlissides. It is about eprouved pattern that really works with description, pros ans cons, example, etc. It is not meant to be read from the beginning to the end and is designed to be a reference. So far I've got through a single design pattern and my coding has already improved because of that.

Design Pattern and Pragmatic Programmer are now at the top on my best book and I will keep them for the rest of my life. I planned, in the next week, to acquire Code Complete Vol 1 or 2. Based on several opinion, it's supposed to be worth a look.

The code generator project hasn't been beginning and maybe will become obsolete in the next week, for some reason, people here doesn't enjoy the idea of developing one.

I decided that next week, I will go through the System.Reflection Namespace, question of learning more and more.

RowFilter of a DataView



It is something that I worked on for 6 hours, and finally I found a way to get it works.

Here is the way to get all row that has a field between two dates :

String.Format("DATE >= #{0}# AND DATE REQUIS < #{1}#", CDate(txtDebut.Text).ToShortDateString(), CDate(txtFin.Text).AddDays(1).ToShortDateString())

Don't forget that you should not try that with a Date that is converted in a string, it won't work.

SharePoint 2003 - Adventure


I now have the mission of setting a SharePoint portal in the company I work for. Today, I just tried to put a page in it, and so far I have not been able. So if you have any good links, suggestions or anything else.. please help me!

deep dives web platform presentation


Tomorrow morning i'm attending to this presentation about ASP.NET 2.0 (since it's what I working with). This one is presented by Adam Gallant who is a .Net Developer Specialist and has been working for Microsoft since 1993. I hope it will not be a marketing speech but a code-oriented one (that's what I'm interested in). 4 hours of full new things for me and I will probably not be deceived (and probably get another bunch of cd that will stay on the desk for another 3 months...). I will get you informed as soon as I can.

Oh and another thing, we switched to C# at my job :) Can't be better I think :)


Deep Dives web platform


2 days ago, I went to a Deep Dives about Asp.Net 2.0. Everyone of my team has agreed to call it 'DDO' (Drag and Drop Oriented). It have been a real pain to listen it until the end. Maybe we got 10 minutes of code, that is when the presentator's computer wasn't freezing because he was running Virtual Pc on it (why didn't he shuts it down for the presentation). Well, it's not his fault, the one who was supposed to do it, was too late because of his plane, and it was not in English but in French because of that. We get some great gifts to compensate. A book to introduce Asp.net 2.0 and a backpack.

So, here is a resume :

The first 3 hours, the presentator talked about Master Page, Theme and Skin. Really interesting in the fact that everything will be so easy in the futur. Just drag your theme into a specified folder, and modify Web.Config to get it activated on the run. Oh and some really interesting stuff in the Code (or app_code later) directory. Just drag a code file in here to get it compiled and ready to run in the project. Also we can now have multiple programming languages on the same project. And there is no more vbproj or csproj file on a Web Site project. A project will be a directory. We did not talk about Edit and Continue.

For the next hour, we talked about Data Acess, MemberShip, IdeaBlade, WebPart, SharePoint. This was so much condensated that we didn't learn a lot, but enough to get a general idea about it. There is now a DataSourceObject object that is supposed to get better separated layer in the tiered application. MemberShip will really be a joke from now on. No more login, managing user, role, personal information, etc.. Everything is now integrated and can be accessed via WebAdmin.axd (maybe wrong). We have also taked a look at Web Part, who really simplified dynamic Web Page. The user will only see what he wants to see and can reorganize everything.

Now for Idea Blade, we do not had the time to look at it, but I have done some research on my own. For what I have seen in the demo, it's an advanced ORM, to link with database, and create our Data Acess Layer. I will take a look at it, in the next few days.

Visual Studio IDE


If you have something to share on tips you have to get the most of Visual Studio, don't hesitate. My current favorite is Ctrl-Space to get the intellisense, when it does not show. :)


Or Select+Tab to indent, and Select+shift+Tab to unindent.

Or /// one line before the function to automatically add code documentation (C#). Said code will automatically create web documentation pages. Check info about web server doc.

Can't think of others right now, but will surely let you know if something comes to mind.

Intellisense in the Immediate Mode Command Window


Here is the tip of the day. But you already propably know. The command window is a great tool to use when you are debugging. But it seems some people doesn't know about it, and now thoses ones will knows.

Open the Command Window from the View Menu. If you see an ­­>, type "immed" (without "") to switch to immediate mode.

Now you can see all values you can normally see in debug mode. So if you are tired to "Add Watch", "Add Quick Watch", etc, you can now be happy about the fact that you can debug without using the mouse. Enjoy.

Standards Master 2005


I have signed for the Standards Master 2005 Beta for the Visual Studio 2005. I hope I get choosed, because, I'm currently using VS2005 to test home, and soon we will introduce it to the company I work for in the next weeks I believe. I strongly believe in coding standars and hope we can approve some soon. You sould check those links, if you are interested in the subject :

.NET Naming Conventions
Design Guidelines for Class Library Developers
Google-Suche
Naming Guidelines
Visual Basic .NET Sample Guidelines

On the road of 70-310


The big difference between the 70-305 (ASP.NET) and 70-310 (XML Web Service) is the lack of interest. I have liked to study the ASP.NET certification because I was using it everyday. I've learned so much in so little time that I (I think) became very efficient with web development. When I say web development I do not talk about design and stuff, because this is where I lack some interest in these times. Generally, I try to learn as much as I can, in my spare time, but this domain I try to stay out at this time. I really enjoy writing object-oriented code and since I’m just beginning I’m learning almost all of the time. Maybe some days, I will be interested more with HTML and XHTML and CSS.

So for the 70-310, my current advice is to get through every aspect of XML file. How to query SQL Server to return XML, W3C specifications, synchronizing XMLDataDocument with DataSet, navigating through node. And almost as important of know how to write the code, know the terms! There is so much term for everything, it can be a pain to read documentation and still don't understand anything.

Oh, and I just got Gran Turismo 4 on Playstation 2. Really great game in my opinion. But it stills not a subject I will venture into.

MSDN User Group Tour: Interoperability - Resume


Great confenrence done by Luc Gauthier. Again it was not in-deep, but enough to understand the basic to allow you to go on your own. Web Services is the way to interoperate. I highly recommend, if you go in that direction, to read and learn as much as you can. It is not easy as it seems. By example, Java.Lang.Util.String is not the same as System.String. I'll try to go on Msdn and bring some link back here, in the next days.

MSDN User Group Tour: Interoperability


I'm attending to this event, in about 30 minutes. I wil write a resume tomorrow.

Refactoring: Improving the Design of Existing Code

This book is all about refactoring. And God knows we need it. In my short career  I have seen entire systems who should have had a major refactoring. Before buying it, you should know you need a basic understanding of Java. If you do, you'll like it. Excellent book !

Visual Studio Tips and Tricks


Visual Studio IDE Tips and Tricks

I'm very interested in macro, so if you have any good advices to help me start with, don't be afraid to share please.

Edit : Current favorite

Crtl-Space - Show intellisense
Ctrl-K-C - Comment line
Ctrl-K-U - Uncomment line
Ctrl-Z - Undo

Custom shortcut

Alt-A - Add a Watch
Alt-Ctrl-Q - Quick Watch

I also use VbCommenter on VB projects to comment functions and class.
Also XmlVisualizer to see what a data control contains ( dataset, datatable, datarow, etc.).

Class Generator


I'm returning back to my idea of doing a Code Generator, but with less expectations. Instead of generating class from an entire database, I will take only one table and generating the entire class to access it. I mean, to have method like Save, Load, Delete and to create stored procedure automatically.

I will have an update as soon as possible in the day.

Oh and forgot to mention that I'm still studying for 70-310. I't awfull how much you learn stuff from this one.

Community



I have been thinking lately to get involved more in the .Net community. You know, make a name and all that. I have tried to post answer in the Code Project forum. But some are more faster than other, and the easy question are already been answered. And I have always thinking about presenting stuff to people. I'll get you more informed in the days to come.

Oh, and if you have suggestion, tell me please :)

And for an update, Visual Studio 2005 Beta 2 is out, and have been playing with it the last few days, and it seems great. More to come.