26 people following this project (follow)

Introduction

This is a beta release of Touch.NET – a .NET implementation of Sencha Touch, the mobile web control framework developed by Sencha. 

I wanted to bring tighter integration between Sencha Touch and the .NET applications I develop (e.g. ability to define controls in ASPX markup / code-behind, similar to Ext.NET), and this culminated in me releasing the small framework you see here now.  Touch.NET automatically renders the Sencha Touch JavaScript code, based on your .NET markup.

Please note this is an early release, so there are controls and properties missing here from Sencha’s framework (see below).  New releases with improved functionality will be available soon.  In the meantime, if you have any feedback on this initial release, please let me know as it would be gratefully received!

Touch.NET has been developed in .NET 4 (C#).  At the moment, the following controls have been ported across from Sencha Touch (with limited functionality):

  • Button
  • Chart
  • FieldSet
  • FormPanel
  • List
  • Model
  • Panel
  • PasswordField
  • SearchField
  • Store (New in beta 2: see code sample below)
  • TabPanel
  • TextField
  • Toolbar
  • ToolbarSpacer

Example usage

Add the Touch.NET DLL to your .NET project, then add the following declaration in your ASPX page:


 
Copy the Sencha Touch “resources” folder to your .NET project. 

Include references to the Sencha Touch CSS and JS files in the Head of your page:


 
Within the Body of the page, add your application markup.  The top-level node must always be “App”, which will contain your child controls.  For instance, the following markup produces the screenshot you see below:


 
Screenshot:

 

Populating a Store with data (in initial load of the page)

To populate a Store with data, see the following code sample:

Code-behind:

Screenshot:

Last edited Oct 19 2011 at 9:19 PM by DanielJGallo, version 4