Asp.net FileUpload
Friday, December 18, 2009
Posted by Usama Wahab Khan at 4:45 AM 0 comments
Send Email in DotNet 3.5
Thursday, December 17, 2009
There two ways to Send Email in Dotnet
1 System.Web.Mail (Dotnet FrameWork 2.0 )
its now obsoleted in FrameWork 3.5
2. System.Net.Mail
to send Mail in 3.5 here Code
define this code or use myclass dotnet NewMail
// Instantiate a new instance of
MailMessage MailMessage mMailMessage = new MailMessage();
// Set the sender address of the mail message
mMailMessage.From = new MailAddress(from);
// Set the recepient address of the mail message
mMailMessage.To.Add(new MailAddress(to));
// Check if the bcc value is null or an empty string
if ((bcc != null) && (bcc != string.Empty))
{ // Set the Bcc address of the mail message
mMailMessage.Bcc.Add(new MailAddress(bcc)); }
// Check if the cc value is null or an empty value
if ((cc != null) && (cc != string.Empty))
{
// Set the CC address of the mail message
mMailMessage.CC.Add(new MailAddress(cc));
} // Set the subject of the mail message
mMailMessage.Subject = subject;
// Set the body of the mail message
mMailMessage.Body = body; // Secify the format of the body as HTML
mMailMessage.IsBodyHtml = true; // Set the priority of the mail message to normal
mMailMessage.Priority = MailPriority.Normal; // Instantiate a new instance of
SmtpClient SmtpClient mSmtpClient = new SmtpClient(); // Send the mail message
mSmtpClient.Send(mMailMessage);
Or Define this code in your Web.config file
By Usama Wahab khan
Posted by Usama Wahab Khan at 11:55 PM 0 comments
Use Login Control for Custom User Authorization
Friday, November 20, 2009

1 add on new website

Posted by Usama Wahab Khan at 1:19 AM 0 comments
Silverlight Beta 4 New Feature
Wednesday, November 18, 2009
Now Microsoft release Silverlight Beta 4 New and Very Useful Features. Silverlight 3.0 was have Some major problems Like Assessing Com Object Silverlight didn't Provide`s Printing Support Developer have to us
PrintDocument pd = new PrintDocument(); pd.PrintPage += (s, args) => { args.PageVisual = LayoutRoot; }; pd.Print();| Usama wahab khan | Welcoem to Silverlight 4.0 Beta |
Posted by Usama Wahab Khan at 11:13 PM 0 comments
Labels: C#, Silverlight
Linq to SharePoint 2010 Provider by Bart De Smet
Tuesday, November 17, 2009


Posted by Usama Wahab Khan at 10:51 PM 0 comments
Labels: Share Point, visual Studio 2010
SEO Support in Asp.net 4.0 Matedata and Page Ruting
Friday, November 13, 2009
SEO( Search engine optimization ) is One of the Important Part for internet base Website SEO or E-Marketing is Very Important for get you site top take in Search engg:
or get more Visitor, Normally Search engines bot scan pages like mysite.com\asp you site and save you meta specially Keywords . but mostly the did get dynamic pages we were crated by the help of qureystring like mysite.com\MobileProduct.aspx?Product="Mobile" . Before asp.net 4.0 where were generate Metadata like Dynamic Keywords,Description,Title , for dynamic website like shopping cart there were hundreds
Product in database but u Search Engg only listed those pages those were query Now in asp.net 4.0 we had solution all of these problems we can resistor Our dynamic Pages with the help of asp.net 4.0 feature called Page Routing it has been introduce in Asp.net MVC now you can use this feature in asp.net-4.0 here i try to create one demo application where i had Products, Category's i will care Product page and route them and each page have dynamically generate keyword,title metadata
1. vs 2010 >New Website and named mycartapplicaiton
2. Right click on App_data folder add northwinds database from sample crate linq to sql add table and view
3. Right click on solution explorer and add two asp.net webform Product.aspx,Categories.aspx.
3 add gridview and set template like this on default.aspx
set sqldatasorce with wizard connectionstring >select columns [CategoryName], [Description], [CategoryID], [Picture] FROM table[Categories]
its will look like this
4.add gridview on categories.aspx
5. add sqldatasorce wizard for girdview ConnectionString>Select view Alphabetical list of products and columns ProductName, QuantityPerUnit, UnitPrice, UnitsInStock, UnitsOnOrder, ReorderLevel, Discontinued click on where button you will route option like this
Posted by Usama Wahab Khan at 10:10 PM 2 comments
Labels: Asp.net, Asp.net 4.0, dotnet 4.0, linq, visual Studio 2010
DropDownList In GridView (CRUD) Operation and Hide Row in Girdview
Wednesday, November 4, 2009
Update , Copy ,Record, Delete (CRUD) Operation Gridview in asp.net Programmability is little bit difficult but its just a few techniques game and nothing else that

Posted by Usama Wahab Khan at 10:17 PM 0 comments
Labels: Asp.net, Databinding, dotnet














