Visual Basic.NET
  Home arrow Visual Basic.NET arrow Page 5 - Developing Pocket PC Applications using Vi...
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Silverlight  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
ASP Web Hosting  
ASP.NET Web Hosting 
Windows Web Hosting
 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
VISUAL BASIC.NET

Developing Pocket PC Applications using Visual Studio.NET 2003
By: Jagadish Chaterjee
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 27
    2006-04-05

    Table of Contents:
  • Developing Pocket PC Applications using Visual Studio.NET 2003
  • What are Pocket PC, Pocket PC Phone and Smart Phone?
  • Creating your first Pocket PC application using Visual Studio.NET 2003
  • Executing your first Pocket PC application using Visual Studio.NET 2003 IDE
  • Working with a datagrid control on Pocket PC using Visual Studio.NET 2003

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Developing Pocket PC Applications using Visual Studio.NET 2003 - Working with a datagrid control on Pocket PC using Visual Studio.NET 2003


    (Page 5 of 5 )

    Life would not be complete without using a “datagrid” control in any .NET application.  Now, let us implement a “datagrid” control even with a Pocket PC application.

    Follow the steps to achieve the same:

    • Delete all the controls you played in the previous section (available on the form).
    • Add a new button (called “Fetch”) and a “datagrid” that fits the width of the form.
    • Open your code window and copy the following code:

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e
    As System.EventArgs) Handles Button1.Click
            Dim dr As DataRow
            Dim dt As New DataTable
            dt.Columns.Add("empno")
            dt.Columns.Add("ename")
            dt.Columns.Add("sal")
            dt.Columns.Add("deptno")

            dr = dt.NewRow
            dr("empno") = 1001
            dr("ename") = "Jag"
            dr("sal") = 2500
            dr("deptno") = 10
            dt.Rows.Add(dr)

            dr = dt.NewRow
            dr("empno") = 1002
            dr("ename") = "Win"
            dr("sal") = 3500
            dr("deptno") = 10
            dt.Rows.Add(dr)

            dr = dt.NewRow
            dr("empno") = 1003
            dr("ename") = "Dhan"
            dr("sal") = 5000
            dr("deptno") = 20
            dt.Rows.Add(dr)

            Me.DataGrid1.DataSource = dt
        End Sub

    • Press F5 to execute your application.
    • After a few seconds, once emulator is loaded, press on the “Fetch” button. 
    • It should give you the output in the following figure (Fig8).

    I developed the application using Microsoft Windows Server 2003 Standard Edition with Microsoft Visual Studio.NET 2003 Enterprise Architect and Pocket PC SDK 2003 (along with additional emulators downloaded).  The entire solution for this article is freely available in the form of a downloadable zip file. 

    In my upcoming articles, I shall concentrate further on developing advanced Pocket PC applications.  So, keep up with the website!

    Any comments, suggestions, feedback, bugs, errors, enhancements are highly appreciated at jag_chat@yahoo.com


    DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware.

       · Hello guys. This is an introductory article to develop Pocket PC app using VS. The...
     

    VISUAL BASIC.NET ARTICLES

    - User-defined Functions using Visual Basic Ap...
    - Understanding Object Binding in VBA
    - Mastering the Message Box
    - Testing a Windows Forms Application
    - Using Visual Basic.NET Features to Code a Wi...
    - Correcting Code in a Windows Forms Applicati...
    - Write Readable Code and Comments for Windows...
    - How to Code and Test a Windows Forms Applica...
    - Adding Features to a Windows Forms Applicati...
    - How to Design a Windows Forms Application
    - LINQ to XML Programming Using Visual Basic.N...
    - Understanding Delegates using Visual Basic.N...
    - Create a Sudoku Puzzle Generator using VB.NET
    - Entity Creation and Messaging in a VB.NET Te...
    - Movement and Player Statistics in a VB.NET T...





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 6 Hosted by Hostway
    For more Enterprise Application Development news, visit eWeek