hyderabad Geographical information system(gis)

Monday, December 28, 2009



District government Hyderabad has launched HYDERABAD GIS Application On Web and Govt Depts . Hyderabad Gis Is Pakistanis `s Frist Online Gis Application . Hyderabad is First City in Pakistan who adopt Latest Gis Technology . Which will help in Planning , Development and Water , Sewerage & Drainage Management ,health , Eduction , Transportation ,in Hyderabad

.

Now District government Hyderabad also launch Hydeabadgis.com for Public and Hyderabad Google with 3d Google with Silverlight first time in world
this hole application is design In Silverlight and my Self Usama Wahab Khan and i am the team lead of hyderabad gis application Now hyderabad gis application is going to deploy in
other department of hyderabad govt
wasa
HDA
and other
application is design on latest technology called silverlight
Applicaiton features:

Map zooming
Map Panning
Map Print on high Scale and resolution's Image
User authentication
Measurement tool to calculate distance and area on map
find address
find plot
info tool
info landmark
map overview
save Book mark and map
and more

In this Project i used Silverlight 3.0 tech for gis and mapping technology

Silverlight Checkbox is Checked in TreeView

Friday, December 25, 2009

In Silverlight 2 Beta i was Big Problem To bind Data with treeview checkbox but its will become Very easy in Silverlight 3 Silverlight 3 Add new Property Called TreeViewItemCheckBox So Try this tutial



1 new project and Create Silverlight Application Call mysite



2 go Solution Explorer and right Click on page.xaml




3 Selcet Treeview Control from asset


4 and Drow treeview on Canvus AND NAMED TvCheckbox save



5 add New Class and named TreeViewDataSource and inherit INotifyPropertyChanged past this code in it

6 add this namespace to to XAML code
xmlns:controlsToolkit="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit" 6
back to Visaul Studio and go page.cs file add code this code on page load event

Try it Live


Download Source Code
thank
i hope its will helps you
by :Usama Wahab Khan

Nested Gridview Asp.net

Monday, December 21, 2009

Download Source Code

Asp.net FileUpload

Friday, December 18, 2009




there two simple way to upload files in asp.net


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);


// 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

 



Use Login Control for Custom User Authorization

Friday, November 20, 2009





1 add on new website
2 darg n drop login control

3 darg n drop logingStatus Control
4 add new database add Table tbluser

5 add two columns in Tbluser , user,password

6 double click on loginControl i will Create Authenticate Event like this
protected void Login1_Authenticate(object sender, AuthenticateEventArgs e)
7 add this code in Login1_Authenticate
8 add few temporary data in database tbluser Like username = usamawahabkhan , Password = abc
9 press five

by usama wahab khan

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
Browser Print support or any other Services another Problem when u will trying local file access But beauty of Mouse
events but Mouse wheel and right click for right click menu were absent in Silverlight 3 these are some
of Major Problem in Silverlight 3.0 .Now Silverlight come`s with all solution now in silverlight 4.0 can
access Local file , Make Print Feature enable in you Application or reporting Silverlight4.0 Provieds
PrintDocument class
PrintDocument pd = new PrintDocument(); pd.PrintPage += (s, args) =>   {       args.PageVisual = LayoutRoot;   }; pd.Print();

Silverlight 4.0 New Features

1 Network Authentication and Trusted Network Access
now Use NetWork Authentication and trusted Network Access in you application use you
Network Authentication Model in you biz applicaitons

2 COM Object Access in Trusted Applications
Till Silverlight 3.0 didn't Support COM Object But Silverlight Provide Environment like Destop App but did use any COM
Feature Now But in Silverlight 4.0 You Use COM Object or like Windows Sapi Access in Trusted Applicatoins
3.RIA Services support in Visual Studio 2010
Full Ria Services Support in vs2010 .
4.Local File Access
access any Local file on Silverlgiht application
5.Asynchronous Data Validation
data Validation another Problem in sl.30 solve in Microsoft silverlight 4.0 Beta
6.Printing API Basics
In Silverlight 3.0 Printing Classes Were Absent so there Big Problem for developer to Create Business Application in SL
Most of Practices Use Asp.net Support to Enable Printing Capability In Reporting ,or other Application but the beautifully
Support of Victor Graphic and Rich Graphical Layout they can not use it Now in Silverlight 4.0 Provides Printing Class
now you can Develop Fully Printable Rich media Application IN Sliverlight .4
7.DataGrid Enhancements
8.Using Silveright Controls As Drop Targets
9.RichTextArea
RichText Area is one of Most use Full Feature or web base Portals for Rich Text Data now you
can Create MsWord like Online Richtextbox in you application


10.MouseWheel API
there where lots of Solution were available
on Silverlight.net Forums for accessing
Mouse Wheels Events Support in Silverlight but now its Easy available in SL.4
11.Right Click Mouse Events Another Silverlight Problem in Right Events
Silverlight provide Most of mouse Events
mouse down,mouse up, mousemove
but mouse right click was absent in Sl
went You RightClick silverlight
context menu Sl.04 Beta
Provide RightClick Event "Element.MouseRightButtonUp"
Now you can Create custom context menu
in SL.04 Application

12.Notification API
You can use and make Noteifica withtion log
Data Error and other Notification Come`s in Application
SL.4 beta Provide NotificationWindow class
When SL Application is Out of Browser Mode
to Show Notification We Can Use NotificationWindow class


12.BiDi and Right-to-Left Support

13.Accessing the Global Clipboard Programmatically
Programmatically access clipbard specially in Rich Media Application.
14.Using the ViewBox Control
15.Hosting HTML Content
Silverlight 4.0 Support HTML Content in Silverlight Applicatons
Before SL4.0 it Was an Issue who To Create
iframe , web Browser ,any other html now its Become Very
Easy in 4.0
string html = "
Usama wahab khanWelcoem to Silverlight 4.0 Beta
"; HtmlContent.NavigateToString(html)
Accessing Web Camera and Microphone
Access Web Cams ,Microphones to Create
Chat Room Applicaton , like Yahoo ChatRoom,Skypy
but Online on Web
So Enjoy Silverlight Beta 4 New Feature
ill Post Each Tutorial of Silverlight Beta 4 New Features
thank you
Usama Wahab Khan

Use Full Links



Linq to SharePoint 2010 Provider by Bart De Smet

Tuesday, November 17, 2009




The LINQ to SharePoint project provides a custom query provider for LINQ that allows to query SharePoint lists using familiar LINQ syntax. LINQ stands for Language Integrated Query and is one of the core features of Microsoft's .NET Framework 3.5 release. its will support Custom Query Provieder that Translates Linq to CAML,the "Collaborative Application Markup Language" by SharePoint for querying by using Linq u didnt need other software to qury in caml like u2u as we know c#3.0 and vb.net 9.0 were support linq Entity Createion tool "SpMetal" to export sharepoint list definitions to entity Classes usedfor Querying and Visual Studio 2008 integration for entity Creation (a.ka SPML) make it more essay and simple you can connect sp site either using SharePoint Object Model or via the Share Point Web services Planned to Support for updating through Entity type This wonderfull Solution Invented by former Visual C# MVP, Bart De Smet now works at Microsoft Corporation on the WPF dev team in an SDE role. so enjoy enity sharepoint to linq






Sample
Updated for the 0.2.2.0 alpha release
var ctx = new SharePointDataContext(new Uri("http://wss.mycompany.local"));
ctx.Log = Console.Out;
var users = ctx.GetList(ctx);

var res = from u in users
orderby u.Birthdate descending
where u.FirstName.StartsWith("B") && u.Age >= 24 && u.FavoriteFood == FavoriteFood.Pizza
select new { u.FullName, u.Age, Interest = u.AccountBalance * 0.07 };

foreach (var u in res)
Console.WriteLine(u);



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

here u can see auto generated metadata and page routing it Product page dynamically generate from database
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

6. product page repeat again same exercise code like this

7 add Global.asax handler add this coe in protected void Application_Start(object sender, EventArgs e)

9 add this code in Product.aspx on pageload event or dynamic keyword and meatadata


10 add this code in default.aspx on pageload event or dynamic keyword and meatadata



Download SourceCode
and enjoy asp.net 4.0 or any other help contant me
By Usama wahab khan

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
like how to access edit values,add control in gridview and with data hide columns in girdview on runtime but
but column value should acesable and manymore. now in this totrial i will tell how to preform
Update , Copy ,Record, Delete (CRUD) Operation Gridview just few steps and you will do it by your selft

1 drag gridview on your form and autgeneratecolumn properties set to false

2 add 4Column type column 1,2 : boundedfield set there header and bindvalue col1 = Productid and cal2 = Productname and add 3rd column TemplateField type , 4th column command type checked update checkbox .

3 edit columns 1,2 and command columns convert on TemplateField

4 . click on gridview flag and edit template there you will see 4 columns in column 0 you have add dropdownlist .
5 select templatefooter in edittemplate add textbox in productname , dropdownlist in colum0 and label control in column productID endedittempalte
6 add database in aap_data folder form sample code
7 right click on girdview goto properties and fire three event 1 rowCreated, Rowupdateing,rowediting and past code give in sample code ;

8 add some css tag in header to hide productid



thank
Usama Wahab Khan
any help Contant me
usamawahabkhan@gmail.com

Office Ribbon Control (wpf)

Saturday, October 31, 2009


Now Create Office like layout application give`s new looks to your wpf applications . Now you can Enjoy Microsoft office Ribbon is Command bar Which is collection of tabs and the Organizes a Program`s Features at top of a Window.


A new WPF Ribbon Control will be available for download shortly after the release of WPF 4. It features skins for Windows 7 and Office, as well as all the standard Ribbon features that end-users are familiar with, including tabs and groups, dynamic resizing, quick access toolbar, application menu, contextual tabs, key tips, and more.

The WPF Ribbon will be fully extensible to meet changing guidelines for future releases. A CTP with a limited feature set is available today here