Lovely old Green president

6:17 AM

Fixing my last post

3:45 PM

In my last post I speak about Syntax Highlighters and told you about their difference.
To day I was read a blog that was on blogger system and use SyntaxHighlighter and dont have the "BR " tag problem.I decide to finde how it works , so look his source page and finde a line of code that i dont use for my blog.when i use that, the blogger problem with "BR" problem solved and SyntaxHighlighter worked.

here is the code :

SyntaxHighlighter.config.bloggerMode = true;

Syntax Highlighting

2:32 AM

last hour I decide to install a syntax highlighting in my blog.

I try :
  1. chili
  2. syntaxhighlighter
  3. CopySourceAsHTML

I was explain each of them for those who wants to use them.

Chili :

chili is a nice Jquery plug in that works good but you cant use it in blogger
easily,because chili needs a space that they library put in there.

SyntaxHighlighter :

SyntaxHighlighter is a good highlighter but it has a bug with "BR" tags. i
don't want to see that in my codes :-&

CopySourceAsHTML :

that's a soooooo nice plug in for VS.Net 2008.it's an open source project that
you can download and install it on your vs.net 2008 with out any key files and
etc . . .

this plug in is very easy to use, when you write some code on your vs.net you
can highlight it and Right click on that and select "Copy as HTML" then he ask
you a question and then you can paste your standard HTML form any where you
like.

I love it,that's a nice plug in.download and enjoy it.

Use LINQ Like Oprator for Unicode Languages

11:48 PM

Last day I want to make an LINQ query for selecting some data from data context

I write this code at the first :

1 Dim fn As New DatadcDataContext


2 Dim users = From user In fn.Users _


3 Where user.UserName Like "%مسعود" _


4 Select user





I didn't get any result , that's because of my like operator.

Like operator cant understand Unicode values.

I was angry about that and search the solution for about 3 days and Finlay fined that :)

if you want to use Like operator for LINQ queries you have to do this :

first import this name space :


1 Imports System.Data.Linq.SqlClient



next you must change your LINQ query like this :

1 Dim fn As New DatadcDataContext


2 Dim users = From user In fn.Users _


3 Where SqlMethods.Like(user.UserName, "%مسعود") _


4 Select user


your done !!! enjoy it ^_^

Hard Start !!!

5:11 PM

hi all !

I don't know but i think that its better to have a weblog on blogger system for my writes !

I will write about this subjects in my weblog :
  • whole of .Net programming
  • ASP.NET ( I love it tooooo much )
  • LINQ , MVC and any technology that Microsoft has !
  • Jquery
  • IRAN :p

I'm not good in English but I try to write correctly, I want all to tell me my wrongs in grammar and words.

Masoud :)