Feeds:
Posts
Comments

Archive for March, 2008

Now a day’s event management is becoming a very popular idea especially in case of web application development. Most of the application is synchronizing with outlook contacts and calendar. Here is a small tool to create event both hour event and day event. This concept is very simple creating a ics file and sending as mail attachment.
event1.png
I have written an small article on how to send event through mail. Please check here to get complete code.
http://www.codeproject.com/KB/applications/SendAppointment.aspx

Read Full Post »

ASP.NET 3.5 introduces a new data binding control named the ListView. ASP.NET already has a lot data bind control; it should be more than 10. But the good news is, ListView can literally replace all other data binding controls in ASP.NET. ListView control makes data binding easier than previous controls. It has included styling with CSS, flexible pagination, and sorting, inserting, deleting, and updating features.

ListView control

I have written an article on ASP:ListView in CodeProject, Please go through it to get complete source code of ListView. My Article on ASP:ListView

Read Full Post »

Advanced SEO for web developers

I saw a nice video today in MIX site this is about Search Engine Optimization. It’s a big video and I really learnt a lot about SEO after see that. You can also see that. Just download SEO video from here and enjoy.
I have written a brief on that video hope you can learn vey basic things from here too

  1. Use HTML semantically
    • Example:
      Good: <H1>this is an Article</H1>
      Bad: <span class=”header1”> this is an Article</span>
      Because: Heading and title tag are more important to robot then span and JavaScript class.
      So be careful to use of common tags its priority sequence is like that <a>, <h1>, <title>, <Meta>, <table>
  2. JavaScript and CSS

    (more…)

Read Full Post »

Sometime we may need to import contact from client machine’s outlook, in this case we can write javascript to import outlook contacts easily. Here is the code how to do that.

var Const_olFolderContacts = 10;
var objApp = new ActiveXObject(“Outlook.Application”);
var objNS = objApp.GetNamespace(“MAPI”);
var colContacts = objNS.GetDefaultFolder(Const_olFolderContacts).Items
for( var i=1; i<=colContacts.count;i++)
{
 var v = colContacts.item(i);
 alert(v[“FullName”]+” (“+v[“Email1Address”]+”)”);
}

if this code does not works , please do the following so it should work

In Internet Explorer , go to Tools | Internet Options | Security  -> from ‘Custom Level’ go to ‘Initialize and script ActiveX controls not marked as safe for scripting’ and select ‘Prompt” — this should work now

have got a big detailes code here, you can check this too another code

Read Full Post »

Sometime for big solutions really feel pain to see IDE is perfoming slower. And sometime i need to work from home using remote dersktop of my office. Remote desktop got slower if at the same time get IDE slower too then no way to work. So searched in the internet and got some good solutios. Now really can work faster. Sharing some of the tip

1. web.config should not have <compilation batch=”false” />
2. Turn off AutoToolboxPopulate (Tools -> Options -> Windows Forms Designer set AutoToolboxPopulate False)
3. Turn off Track Active item (Tools -> Options -> Projects and Solutions uncheck Track Active Item in Solution Explorer)
4. Disable Navigation Bar(Tools -> Options -> Text Editor -> C#, uncheck Navigation bar)
5. Move file in App_Code into a class library project
6. Disable validation Options for HTML Editing (Tools -> Options -> Validation -> Clear show error checkbox)

-Hope you are working faster now

Read Full Post »

Where column IN(@parameter)

I faced problem when i tried to send parameter in a store procedure which parameter is located in the ‘IN’ of the query. first i written a query ‘select * from users where in IN(1,2,4)’ — worrls nicely, then i tried to use store procedure to parametarize data i have written a store procedure look like that

create proc getuser( @ids as varchar(50) ) AS select * from users where in IN(@ids) — not working. why will it work you are giving parameter as varchar but you are give id as integer, what you want to do change parameter type? it is no a solution too as you will send all id once through the parameter.

So the solution is

create proc proc_test
(@ids  nvarchar(100))
AS
declare @sql  as nvarchar(1000)
set @sql = N’SELECT * FROM JoinPool WHERE ID IN (‘ + @ids + ‘)’
EXECUTE sp_executesql @sql

exec proc_test ‘1,2,3,5’  — will return result 🙂

Read Full Post »