El Libro del Día: 2016-08-08
Titulo: Professional AngularJS
Autor: Valeri Karpov, Diego Netto
Editorial: Wrox
Nro Paginas: 399
Capítulos:
CHAPTER 1 Building a Simple AngularJS Application
CHAPTER 2 Intelligent Workflow and Build Tools
CHAPTER 3 Architecture
CHAPTER 4 Data Binding
CHAPTER 5 Directives
CHAPTER 6 Templates, Location, and Routing
CHAPTER 7 Services, Factories, and Providers
CHAPTER 8 Server Communication
CHAPTER 9 Testing and Debugging AngularJS Applications
CHAPTER 10 Moving On
APPENDIX Resources
Descarga:
Professional_AngularJS
Blog de Luis Dueñas dedicado a la difusión del Desarrollo en Microsoft .NET, Visual Studio, WinForms, WebForms, MVC, ASP .NET, jQuery, AJAX, HTML5, JavaScript, Móviles, etc. Encontrarás Libros, Demos, Artículos Técnicos, Entrenamiento.
Mostrando las entradas con la etiqueta Templates. Mostrar todas las entradas
Mostrando las entradas con la etiqueta Templates. Mostrar todas las entradas
lunes, 8 de agosto de 2016
El Libro del Día: Professional AngularJS
Etiquetas:
AngularJS,
Apps,
Architecture,
Build Tools,
Data Binding,
Debugging,
Diego Netto,
Directives,
Factories,
Libros,
Location,
Professional,
Providers,
Routing,
Services,
Templates,
Testing,
Valeri Karpov,
Workflow,
Wrox
martes, 9 de febrero de 2016
El Libro del Día: Meteor in Action
El Libro del Día: 2016-02-09
Titulo: Meteor in Action
Autor: Stephan Hochhaus, Manuel Schoebel
Editorial: Manning
Nro Paginas: 372
Capítulos:
Part 1: Look - A Shoting Start
1. A better way to build apps
2. My fridge. A reactive game
Part 2: 3,2,1 - Impact
3. Working with templates
4. Working with data
5. Fully reactive editing
6. Users, authentications, and permissions
7. Exchanging data
8. Routing using Iron.Router
9. The package system
10. Advanced server methods
Part 3: Leaving the Crater
11. Building and debugging
12. Going into production
Descarga:
Meteor_in_Action
Titulo: Meteor in Action
Autor: Stephan Hochhaus, Manuel Schoebel
Editorial: Manning
Nro Paginas: 372
Capítulos:
Part 1: Look - A Shoting Start
1. A better way to build apps
2. My fridge. A reactive game
Part 2: 3,2,1 - Impact
3. Working with templates
4. Working with data
5. Fully reactive editing
6. Users, authentications, and permissions
7. Exchanging data
8. Routing using Iron.Router
9. The package system
10. Advanced server methods
Part 3: Leaving the Crater
11. Building and debugging
12. Going into production
Descarga:
Meteor_in_Action
Etiquetas:
Apps,
authentications,
Data,
editing,
exchanging,
Game,
in Action,
Libros,
Manning,
Manuel Schoebel,
Meteor,
Methods,
Package,
permissions,
reactive,
Routing,
Server,
Stephan Hochhaus,
Templates,
Users
jueves, 10 de septiembre de 2015
El Libro del Día: Ember.js Web Development with Ember CLI
El Libro del Día: 2015-09-10
Titulo: Ember.js Web Development with Ember CLI
Autor: Suchit Puri
Editorial: Packt
Nro Paginas: 174
Capítulos:
Chapter 1: Getting Started with Building Ambitious Ember.js Applications with Ember CLI
Chapter 2: Understanding Ember.js Object-oriented Patterns
Chapter 3: Rendering Using Templates
Chapter 4: Managing Application State Using Ember.js Routes
Chapter 5: Handling Display Logic Using Ember.js Controllers
Chapter 6: Communicating with the API Server Using ember data
Chapter 7: Building Reusable Components
Descarga:
Ember.js_Web_Development_with_Ember_CLI
Titulo: Ember.js Web Development with Ember CLI
Autor: Suchit Puri
Editorial: Packt
Nro Paginas: 174
Capítulos:
Chapter 1: Getting Started with Building Ambitious Ember.js Applications with Ember CLI
Chapter 2: Understanding Ember.js Object-oriented Patterns
Chapter 3: Rendering Using Templates
Chapter 4: Managing Application State Using Ember.js Routes
Chapter 5: Handling Display Logic Using Ember.js Controllers
Chapter 6: Communicating with the API Server Using ember data
Chapter 7: Building Reusable Components
Descarga:
Ember.js_Web_Development_with_Ember_CLI
Etiquetas:
API Server,
Components,
Controllers,
Data,
Display Logic,
Ember CLI,
Ember.js,
Javascript,
Libros,
Object oriented,
Packt,
Patterns,
Routes,
State,
Suchit Puri,
Templates,
Web Development
martes, 11 de agosto de 2015
El Libro del Día: Learning ExtJS
El Libro del Día: 2015-08-11
Titulo: Learning ExtJS (Fourth Edition)
Autor: Carlos A. Méndez, Crysfel Villa, Armando Gonzalez
Editorial: Packt
Nro Paginas: 453
Capítulos:
Chapter 1: An Introduction to Ext JS 5
Chapter 2: The Core Concepts
Chapter 3: Components and Layouts
Chapter 4: It's All about the Data
Chapter 5: Buttons and Toolbars
Chapter 6: Doing It with Forms
Chapter 7: Give Me the Grid
Chapter 8: DataViews and Templates
Chapter 9: The Tree Panel
Chapter 10: Architecture
Chapter 11: The Look and Feel
Chapter 12: Responsive Configurations and Tablet Support
Chapter 13: From Drawing to Charting
Chapter 14: Finishing the Application
Chapter 15: What's Next?
Descarga:
Learning_ExtJS
Titulo: Learning ExtJS (Fourth Edition)
Autor: Carlos A. Méndez, Crysfel Villa, Armando Gonzalez
Editorial: Packt
Nro Paginas: 453
Capítulos:
Chapter 1: An Introduction to Ext JS 5
Chapter 2: The Core Concepts
Chapter 3: Components and Layouts
Chapter 4: It's All about the Data
Chapter 5: Buttons and Toolbars
Chapter 6: Doing It with Forms
Chapter 7: Give Me the Grid
Chapter 8: DataViews and Templates
Chapter 9: The Tree Panel
Chapter 10: Architecture
Chapter 11: The Look and Feel
Chapter 12: Responsive Configurations and Tablet Support
Chapter 13: From Drawing to Charting
Chapter 14: Finishing the Application
Chapter 15: What's Next?
Descarga:
Learning_ExtJS
Etiquetas:
Architecture,
Armando Gonzalez,
Buttons,
Carlos A. Méndez,
Charting,
Components,
Crysfel Villa,
Data,
DataViews,
Drawing,
ExtJS,
Forms,
Grid,
Layouts,
Learning,
Libros,
Packt,
Templates,
Toolbars,
Tree Panel
lunes, 22 de junio de 2015
El Libro del Día: Beginning JSON
El Libro del Día: 2015-06-22
Titulo: Beginning JSON
Autor: Ben Smith
Editorial: Apress
Nro Paginas: 353
Capítulos:
Chapter 1: JavaScript Basics
Chapter 2: Special Objects
Chapter 3: String Manipulation
Chapter 4: Introducing JSON
Chapter 5: Creating JSON
Chapter 6: Parsing JSON
Chapter 7: Persisting JSON: I
Chapter 8: Data Interchange
Chapter 9: X-Origin Resources
Chapter 10: Serving JSON
Chapter 11: Posting JSON
Chapter 12: Persisting JSON: II
Chapter 13: Working with Templates
Chapter 14: Putting It All Together
Descarga:
Beginning_JSON
Titulo: Beginning JSON
Autor: Ben Smith
Editorial: Apress
Nro Paginas: 353
Capítulos:
Chapter 1: JavaScript Basics
Chapter 2: Special Objects
Chapter 3: String Manipulation
Chapter 4: Introducing JSON
Chapter 5: Creating JSON
Chapter 6: Parsing JSON
Chapter 7: Persisting JSON: I
Chapter 8: Data Interchange
Chapter 9: X-Origin Resources
Chapter 10: Serving JSON
Chapter 11: Posting JSON
Chapter 12: Persisting JSON: II
Chapter 13: Working with Templates
Chapter 14: Putting It All Together
Descarga:
Beginning_JSON
Etiquetas:
Apress,
Beginning,
Ben Smith,
Creating,
Data,
Interchange,
Javascript,
JSON,
Libros,
Objects,
Parsing,
Persisting,
Posting,
Resources,
Serving,
String,
Templates
jueves, 21 de mayo de 2015
El Libro del Día: Custom SharePoint Solutions with HTML and JavaScript
El Libro del Día: 2015-05-21
Titulo: Custom SharePoint Solutions with HTML and JavaScript
Autor: Brandon Atkinson
Editorial: Apress
Nro Paginas: 240
Capítulos:
Chapter 1: Setting Up Your Environment
Chapter 2: Introduction to SharePoint Front-End Solutions
Chapter 3: Content Editor and Script Editor Web Parts
Chapter 4: Building Custom Web Parts Using HTML and JavaScript
Chapter 5: Using JSLink to Style List Web Parts
Chapter 6: Content Search Web Part and Display Templates
Chapter 7: Working with SharePoint’s Built-in JavaScript Functions and Properties
Chapter 8: Working with the JavaScript Object Model
Chapter 9: Working with the REST API
Descarga:
Custom_SharePoint_Solutions_HTML_JavaScript
Titulo: Custom SharePoint Solutions with HTML and JavaScript
Autor: Brandon Atkinson
Editorial: Apress
Nro Paginas: 240
Capítulos:
Chapter 1: Setting Up Your Environment
Chapter 2: Introduction to SharePoint Front-End Solutions
Chapter 3: Content Editor and Script Editor Web Parts
Chapter 4: Building Custom Web Parts Using HTML and JavaScript
Chapter 5: Using JSLink to Style List Web Parts
Chapter 6: Content Search Web Part and Display Templates
Chapter 7: Working with SharePoint’s Built-in JavaScript Functions and Properties
Chapter 8: Working with the JavaScript Object Model
Chapter 9: Working with the REST API
Descarga:
Custom_SharePoint_Solutions_HTML_JavaScript
Etiquetas:
Apress,
Brandon Atkinson,
Content Editor,
Content Search,
Environment,
Frontend,
Functions,
HTML,
Javascript,
JOM,
JSLink,
Libros,
Properties,
REST API,
Script Editor,
SharePoint,
Solutions,
Templates,
Web Parts
miércoles, 4 de marzo de 2015
El Libro del Día: Bootstrap for ASP.NET MVC
El Libro del Día: 2015-03-04
Titulo: Bootstrap for ASP.NET MVC
Autor: Pieter van der Westhuizen
Editorial: Packt
Nro Paginas: 198
Capítulos:
Chapter 1: Getting Started with ASP.NET MVC and Bootstrap
Chapter 2: Using Bootstrap CSS and HTML Elements
Chapter 3: Using Bootstrap Components
Chapter 4: Using Bootstrap JavaScript Plugins
Chapter 5: Creating ASP.NET MVC Bootstrap Helpers
Chapter 6: Creating T4 Templates to Scaffold Bootstrap Views
Chapter 7: Converting a Bootstrap HTML Template into a Usable ASP.NET MVC Project
Chapter 8: Using the jQuery DataTables Plugin with Bootstrap
Chapter 9: Making Things Easier with the TwitterBootstrapMVC Library
Appendix: Bootstrap Resources
Descarga:
Bootstrap_for_ASP.NET_MVC
Titulo: Bootstrap for ASP.NET MVC
Autor: Pieter van der Westhuizen
Editorial: Packt
Nro Paginas: 198
Capítulos:
Chapter 1: Getting Started with ASP.NET MVC and Bootstrap
Chapter 2: Using Bootstrap CSS and HTML Elements
Chapter 3: Using Bootstrap Components
Chapter 4: Using Bootstrap JavaScript Plugins
Chapter 5: Creating ASP.NET MVC Bootstrap Helpers
Chapter 6: Creating T4 Templates to Scaffold Bootstrap Views
Chapter 7: Converting a Bootstrap HTML Template into a Usable ASP.NET MVC Project
Chapter 8: Using the jQuery DataTables Plugin with Bootstrap
Chapter 9: Making Things Easier with the TwitterBootstrapMVC Library
Appendix: Bootstrap Resources
Descarga:
Bootstrap_for_ASP.NET_MVC
Etiquetas:
ASP.NET,
Bootstrap,
Components,
CSS,
DataTables,
Elements,
Helpers,
HTML,
Javascript,
jQuery,
Libros,
MVC,
Packt,
Pieter van der Westhuizen,
Plugins,
Scaffold,
T4,
Templates,
TwitterBootstrapMVC,
Views
martes, 17 de febrero de 2015
El Libro del Día: HTML5 Boilerplate Web Development
El Libro del Día: 2015-02-17
Titulo: HTML5 Boilerplate Web Development
Autor: Divya Manian
Editorial: Packt
Nro Paginas: 174
Capítulos:
Chapter 1: Before We Begin
Chapter 2: Starting Your Project
Chapter 3: Creating Your Site
Chapter 4: Adding Interactivity and Completing Your Site
Chapter 5: Customizing the Apache Server
Chapter 6: Making Your Site Better
Chapter 7: Automate Deployment With the Build Script
Appendix: You Are an Expert, Now What
Descarga:
HTML5_Boilerplate_Web_Development
Titulo: HTML5 Boilerplate Web Development
Autor: Divya Manian
Editorial: Packt
Nro Paginas: 174
Capítulos:
Chapter 1: Before We Begin
Chapter 2: Starting Your Project
Chapter 3: Creating Your Site
Chapter 4: Adding Interactivity and Completing Your Site
Chapter 5: Customizing the Apache Server
Chapter 6: Making Your Site Better
Chapter 7: Automate Deployment With the Build Script
Appendix: You Are an Expert, Now What
Descarga:
HTML5_Boilerplate_Web_Development
Etiquetas:
Apache,
Automate,
Boilerplate,
Build Script,
Completing,
Customizing,
Deployment,
Divya Manian,
HTML5,
Interactivity,
Libros,
Nicolas Gallagher,
Packt,
Paul Irish,
Site Better,
Templates,
Web Development
martes, 20 de enero de 2015
El Libro del Día: Pro JavaScript Development
El Libro del Día: 2015-01-20
Titulo: Pro JavaScript Development
Autor: Den Odell
Editorial: Apress
Nro Paginas: 454
Capítulos:
Chapter 1: Object-Oriented JavaScript
Chapter 2: Documenting JavaScript
Chapter 3: Writing High-Quality JavaScript
Chapter 4: Boosting JavaScript Performance
Chapter 5: Design Patterns: Creational
Chapter 6: Design Patterns: Structural
Chapter 7: Design Patterns: Behavioral
Chapter 8: Design Patterns: Architectural
Chapter 9: Managing Code File Dependencies
Chapter 10: Mobile JavaScript Development
Chapter 11: Building Games with Canvas API
Chapter 12: Using WebRTC for Video Chat
Chapter 13: Using Client-Side Templates
Chapter 14: The Node.js Application Platform
Chapter 15: Build Tools and Automation
Chapter 16: Browser Developer Tools
Descarga:
Pro_JavaScript_Development
Titulo: Pro JavaScript Development
Autor: Den Odell
Editorial: Apress
Nro Paginas: 454
Capítulos:
Chapter 1: Object-Oriented JavaScript
Chapter 2: Documenting JavaScript
Chapter 3: Writing High-Quality JavaScript
Chapter 4: Boosting JavaScript Performance
Chapter 5: Design Patterns: Creational
Chapter 6: Design Patterns: Structural
Chapter 7: Design Patterns: Behavioral
Chapter 8: Design Patterns: Architectural
Chapter 9: Managing Code File Dependencies
Chapter 10: Mobile JavaScript Development
Chapter 11: Building Games with Canvas API
Chapter 12: Using WebRTC for Video Chat
Chapter 13: Using Client-Side Templates
Chapter 14: The Node.js Application Platform
Chapter 15: Build Tools and Automation
Chapter 16: Browser Developer Tools
Descarga:
Pro_JavaScript_Development
Etiquetas:
Apress,
Architectural,
Behavioral,
Canvas,
Creational,
Den Odell,
Dependencies,
Design Patterns,
Documenting,
Games,
Javascript,
Libros,
Mobile,
Node.js,
OOP,
Performance,
Structural,
Templates,
Tools,
WebRTC
jueves, 13 de noviembre de 2014
El Libro del Día: WPF 4 Unleashed
El Libro del Día: 2014-11-13
Titulo: WPF 4 Unleashed
Autor: Adam Nathan
Editorial: Sams
Nro Paginas: 844
Capítulos:
Part I Background
1 Why WPF, and What About Silverlight?
2 XAML Demystified
3 WPF Fundamentals
Part II Building a WPF Application
4 Sizing, Positioning, and Transforming Elements
5 Layout with Panels
6 Input Events: Keyboard, Mouse, Stylus, and Multi-Touch
7 Structuring and Deploying an Application
8 Exploiting Windows 7
Part III Controls
9 Content Controls
10 Items Controls
11 Images, Text, and Other Controls
Part IV Features for Professional Developers
12 Resources
13 Data Binding
14 Styles, Templates, Skins, and Themes
Part V Rich Media
15 2D Graphics
16 3D Graphics
17 Animation
18 Audio, Video, and Speech
Part VI Advanced Topics
19 Interoperability with Non-WPF Technologies
20 User Controls and Custom Controls
21 Layout with Custom Panels
Descarga:
WPF_4_Unleashed
Titulo: WPF 4 Unleashed
Autor: Adam Nathan
Editorial: Sams
Nro Paginas: 844
Capítulos:
Part I Background
1 Why WPF, and What About Silverlight?
2 XAML Demystified
3 WPF Fundamentals
Part II Building a WPF Application
4 Sizing, Positioning, and Transforming Elements
5 Layout with Panels
6 Input Events: Keyboard, Mouse, Stylus, and Multi-Touch
7 Structuring and Deploying an Application
8 Exploiting Windows 7
Part III Controls
9 Content Controls
10 Items Controls
11 Images, Text, and Other Controls
Part IV Features for Professional Developers
12 Resources
13 Data Binding
14 Styles, Templates, Skins, and Themes
Part V Rich Media
15 2D Graphics
16 3D Graphics
17 Animation
18 Audio, Video, and Speech
Part VI Advanced Topics
19 Interoperability with Non-WPF Technologies
20 User Controls and Custom Controls
21 Layout with Custom Panels
Descarga:
WPF_4_Unleashed
miércoles, 12 de noviembre de 2014
El Libro del Día: Windows Presentation Foundation 4.5 Cookbook
El Libro del Día: 2014-11-12
Titulo: Windows Presentation Foundation 4.5 Cookbook
Autor: Pavel Yosifovich
Editorial: Packt
Nro Paginas: 464
Capítulos:
Chapter 1: Foundations
Chapter 2: Resources
Chapter 3: Layout and Panels
Chapter 4: Using Standard Controls
Chapter 5: Application and Windows
Chapter 6: Data Binding
Chapter 7: Commands and MVVM
Chapter 8: Styles, Triggers, and Control Templates
Chapter 9: Graphics and Animation
Chapter 10: Custom Elements
Chapter 11: Threading
Descarga:
Windows_Presentation_Foundation_4.5_Cookbook
Titulo: Windows Presentation Foundation 4.5 Cookbook
Autor: Pavel Yosifovich
Editorial: Packt
Nro Paginas: 464
Capítulos:
Chapter 1: Foundations
Chapter 2: Resources
Chapter 3: Layout and Panels
Chapter 4: Using Standard Controls
Chapter 5: Application and Windows
Chapter 6: Data Binding
Chapter 7: Commands and MVVM
Chapter 8: Styles, Triggers, and Control Templates
Chapter 9: Graphics and Animation
Chapter 10: Custom Elements
Chapter 11: Threading
Descarga:
Windows_Presentation_Foundation_4.5_Cookbook
Etiquetas:
Animation,
Application,
Commands,
Controls,
Data Binding,
Foundations,
Graphics,
Layout,
Libros,
MVVM,
Packt,
Panels,
Pavel Yosifovich,
Resources,
Styles,
Templates,
Threading,
Triggers,
Windows,
WPF
martes, 11 de noviembre de 2014
El Libro del Día: WPF 4.5 in C#
El Libro del Día: 2014-11-11
Titulo: Pro WPF 4.5 in C#
Autor: Matthew MacDonald
Editorial: Apress
Nro Paginas: 1095
Capítulos:
Part I: Fundamentals
Chapter 1: Introducing WPF
Chapter 2: XAML
Chapter 3: Layout
Chapter 4: Dependency Properties
Chapter 5: Routed Events
Part II: Deeper Into WPF
Chapter 6: Controls
Chapter 7: The Application
Chapter 8: Element Binding
Chapter 9: Commands
Chapter 10: Resources
Chapter 11: Styles and Behaviors
Part III: Drawing and Animation
Chapter 12: Shapes, Brushes, and Transforms
Chapter 13: Geometries and Drawings
Chapter 14: Effects and Visuals
Chapter 15: Animation Basics
Chapter 16: Advanced Animation
Part IV: Templates and Custom Elements
Chapter 17: Control Templates
Chapter 18: Custom Elements
Part V: Data
Chapter 19: Data Binding
Chapter 20: Formatting Bound Data
Chapter 21: Data Views
Chapter 22: Lists, Trees, and Grids
Part VI: Windows, Pages, and Rich Controls
Chapter 23: Windows
Chapter 24: Pages and Navigation
Chapter 25: Menus, Toolbars, and Ribbons
Chapter 26: Sound and Video
Chapter 27: 3-D Drawing
Part VII: Documents and Printing
Chapter 28: Documents
Chapter 29: Printing
Part VIII: Additional Topics
Chapter 30: Interacting with Windows Forms
Chapter 31: Multithreading
Chapter 32: The Add-in Model
Chapter 33: ClickOnce Deployment
Descarga:
Pro_WPF_4.5_C#
Titulo: Pro WPF 4.5 in C#
Autor: Matthew MacDonald
Editorial: Apress
Nro Paginas: 1095
Capítulos:
Part I: Fundamentals
Chapter 1: Introducing WPF
Chapter 2: XAML
Chapter 3: Layout
Chapter 4: Dependency Properties
Chapter 5: Routed Events
Part II: Deeper Into WPF
Chapter 6: Controls
Chapter 7: The Application
Chapter 8: Element Binding
Chapter 9: Commands
Chapter 10: Resources
Chapter 11: Styles and Behaviors
Part III: Drawing and Animation
Chapter 12: Shapes, Brushes, and Transforms
Chapter 13: Geometries and Drawings
Chapter 14: Effects and Visuals
Chapter 15: Animation Basics
Chapter 16: Advanced Animation
Part IV: Templates and Custom Elements
Chapter 17: Control Templates
Chapter 18: Custom Elements
Part V: Data
Chapter 19: Data Binding
Chapter 20: Formatting Bound Data
Chapter 21: Data Views
Chapter 22: Lists, Trees, and Grids
Part VI: Windows, Pages, and Rich Controls
Chapter 23: Windows
Chapter 24: Pages and Navigation
Chapter 25: Menus, Toolbars, and Ribbons
Chapter 26: Sound and Video
Chapter 27: 3-D Drawing
Part VII: Documents and Printing
Chapter 28: Documents
Chapter 29: Printing
Part VIII: Additional Topics
Chapter 30: Interacting with Windows Forms
Chapter 31: Multithreading
Chapter 32: The Add-in Model
Chapter 33: ClickOnce Deployment
Descarga:
Pro_WPF_4.5_C#
lunes, 10 de noviembre de 2014
El Libro del Día: Illustrated WPF
El Libro del Día: 2014-11-10
Titulo: Illustrated WPF
Autor: Daniel Solis
Editorial: Apress
Nro Paginas: 531
Capítulos:
CHAPTER 1 Introduction to Windows Presentation Foundation
CHAPTER 2 Overview of WPF Programming
CHAPTER 3 WPF Architecture and Applications
CHAPTER 4 XAML
CHAPTER 5 Layout
CHAPTER 6 Content and Controls
CHAPTER 7 Dependency Properties
CHAPTER 8 Data Binding
CHAPTER 9 Routing Events and Commands
CHAPTER 10 Other Controls and Elements
CHAPTER 11 Resources
CHAPTER 12 Styles
CHAPTER 13 Control Templates
CHAPTER 14 Page Navigation Programs
CHAPTER 15 More Data Binding
CHAPTER 16 Trees, Tabs, and Other Controls
CHAPTER 17 Text and Documents
CHAPTER 18 Graphics in WPF
CHAPTER 19 Animation
CHAPTER 20 Audio and Video
Descarga:
Illustrated_WPF
Titulo: Illustrated WPF
Autor: Daniel Solis
Editorial: Apress
Nro Paginas: 531
Capítulos:
CHAPTER 1 Introduction to Windows Presentation Foundation
CHAPTER 2 Overview of WPF Programming
CHAPTER 3 WPF Architecture and Applications
CHAPTER 4 XAML
CHAPTER 5 Layout
CHAPTER 6 Content and Controls
CHAPTER 7 Dependency Properties
CHAPTER 8 Data Binding
CHAPTER 9 Routing Events and Commands
CHAPTER 10 Other Controls and Elements
CHAPTER 11 Resources
CHAPTER 12 Styles
CHAPTER 13 Control Templates
CHAPTER 14 Page Navigation Programs
CHAPTER 15 More Data Binding
CHAPTER 16 Trees, Tabs, and Other Controls
CHAPTER 17 Text and Documents
CHAPTER 18 Graphics in WPF
CHAPTER 19 Animation
CHAPTER 20 Audio and Video
Descarga:
Illustrated_WPF
Etiquetas:
Animation,
Apress,
Audio,
Commands,
Content,
Controls,
Daniel Solis,
Data Binding,
Dependency,
Documents,
Events,
Graphics,
Layout,
Libros,
Resources,
Styles,
Templates,
Video,
WPF,
XAML
martes, 4 de noviembre de 2014
El Demo del Día: Paginación en un GridView con Columna de CheckBoxs
Paginación en un GridView con Columna de CheckBoxs
Después de mas de 2 meses retomamos los posts de ASP .NET WebForms, en esta ocasión publicaré un caso práctico muy útil.
Requerimiento
Se desea listar registros en forma paginada usando el GridView pero mostrando una columna con Checks que permita seleccionar los registros para un uso posterior como grabar datos en el servidor.
Problema
Si creamos una grilla sin paginar con una columna de tipo CheckBox no hay problemas, pero si paginamos, al seleccionar los checks de una pagina y cambiar de pagina se perderán debido a que la grilla siempre se tiene que enlazar nuevamente para mostrar la pagina seleccionada.
Solución
Para solucionar el problema debemos enlazar la columna checkbox a una propiedad de la entidad del negocio de tipo boolean, luego debemos almacenar el valor seleccionado, lo cual se puede hacer de 2 formas:
1. Guardar el valor cada vez que se selecciona el check, ya sea para marcar o desmarcar.
2. Guardar los valores seleccionados al regresar al servidor ya sea al cambiar de página o al hacer PostBack mediante algún botón.
Definitivamente, la mejor opción es la segunda, es decir, cada vez que ocurra un Postback guardaremos los checks seleccionados de la pagina actual.
Crear el Procedimiento Almacenado en la Base de Datos de SQL Server
Create Procedure uspProductsListar
As
Select ProductID,ProductName,SupplierID,CategoryID,UnitPrice,UnitsInStock
From Products
Crear la Aplicación Web en ASP .NET Web Form
Crear un "Nuevo Sitio web vacío de ASP .NET" en C# llamado "GridView_Paginado_Checks".
Para simplificar el Demo no he creado librerías de clases y las clases las he incluido dentro de la aplicación Web.
Crear la Clase Entidad del Negocio
Crear la clase beProducto escribiendo el siguiente código:
using System;
namespace GridView_Paginado_Checks
{
public class beProducto
{
public bool Seleccion { get; set; }
public int IdProducto { get; set; }
public string Nombre { get; set; }
public int IdProveedor { get; set; }
public int IdCategoria { get; set; }
public decimal PrecioUnitario { get; set; }
public short Stock { get; set; }
}
}
Nota: La propiedad Seleccion es la que se va a enlazar al check para guardar el valor seleccionado.
Crear la Clase de Acceso a Datos
Crear la clase daProducto escribiendo el siguiente código:
using System;
using System.Data; //CommadType
using System.Data.SqlClient; //SqlConnection, SqlCommand, SqlDataReader
using System.Collections.Generic; //List
namespace GridView_Paginado_Checks
{
public class daProducto
{
public List<beProducto> listar(SqlConnection con)
{
List<beProducto> lbeProducto = null;
SqlCommand cmd = new SqlCommand("uspProductsListar", con);
cmd.CommandType = CommandType.StoredProcedure;
SqlDataReader drd = cmd.ExecuteReader(CommandBehavior.SingleResult);
if (drd != null)
{
lbeProducto = new List<beProducto>();
int posIdProducto = drd.GetOrdinal("ProductID");
int posNombre = drd.GetOrdinal("ProductName");
int posIdProveedor = drd.GetOrdinal("SupplierID");
int posIdCategoria = drd.GetOrdinal("CategoryID");
int posPrecioUnitario = drd.GetOrdinal("UnitPrice");
int posStock = drd.GetOrdinal("UnitsInStock");
beProducto obeProducto;
while (drd.Read())
{
obeProducto = new beProducto();
obeProducto.IdProducto = drd.GetInt32(posIdProducto);
obeProducto.Nombre = drd.GetString(posNombre);
obeProducto.IdProveedor = drd.GetInt32(posIdProveedor);
obeProducto.IdCategoria = drd.GetInt32(posIdCategoria);
obeProducto.PrecioUnitario = drd.GetDecimal(posPrecioUnitario);
obeProducto.Stock = drd.GetInt16(posStock);
lbeProducto.Add(obeProducto);
}
drd.Close();
}
return (lbeProducto);
}
}
}
Nota: Tiene que haberse creado el Procedimiento Almacenado "uspProductsListar" en la BD Northwind.
Crear la Clase de Reglas del Negocio
Crear la clase brProducto escribiendo el siguiente código:
using System;
using System.Collections.Generic; //List
using System.Data.SqlClient; //SqlConnection
using System.Configuration; //ConfigurationManager
namespace GridView_Paginado_Checks
{
public class brProducto
{
public List<beProducto> listar()
{
List<beProducto> lbeProducto = null;
string conexion = ConfigurationManager.ConnectionStrings["conNW"].ConnectionString;
using (SqlConnection con = new SqlConnection(conexion))
{
try
{
con.Open();
daProducto odaProducto = new daProducto();
lbeProducto = odaProducto.listar(con);
}
catch (SqlException ex)
{
foreach (SqlError err in ex.Errors)
{
//Capturar cada error y grabar un Log
}
}
} //con.Close(); con.Dispose(); con = null;
return (lbeProducto);
}
}
}
Nota: Hay que hacer referencia a la librería "System.Configuration.dll" para usar la clase ConfigurationManager para leer el archivo de configuración.
Crear el Archivo de Hoja de Estilo
Agregar un archivo de hoja de estilo llamado ACME.css y escribir lo siguiente:
body {
background-color:aqua;
}
.Titulo {
background-color:black;
color:white;
text-transform:uppercase;
font-size:xx-large;
font-weight:bold;
}
.AnchoTotal {
width:100%;
}
.Centrado {
text-align:center;
}
.Subtitulo {
background-color:white;
color:blue;
text-transform:capitalize;
font-size:x-large;
font-weight:bold;
}
.FilaCabecera {
background-color: lightgray;
color:black;
}
.FilaDatos {
background-color: white;
color:blue;
}
Crear la Pagina ASP .NET como un Formulario Web Form
Agregar un Formulario Web Form al proyecto llamado: "ListaProductos.aspx" y escribir lo siguiente:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ListaProductos.aspx.cs" Inherits="GridView_Paginado_Checks.ListaProductos" %>
<%@ Import Namespace="GridView_Paginado_Checks" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
<link href="ACME.css" rel="stylesheet" type="text/css" />
</head>
<body>
<form id="form1" runat="server">
<div>
<table class="AnchoTotal">
<tr class="Titulo">
<td>Paginacion en un GridView con Columna de Checks</td>
</tr>
<tr class="Subtitulo">
<td>Selecciona de la Lista de Productos</td>
</tr>
<tr>
<td>
<asp:GridView ID="gvProducto" AllowPaging="true" AutoGenerateColumns="false"
Width="800px" runat="server" OnPageIndexChanging="paginarProductos">
<HeaderStyle CssClass="FilaCabecera" />
<RowStyle CssClass="FilaDatos" />
<PagerStyle CssClass="FilaCabecera" />
<Columns>
<asp:TemplateField ItemStyle-Width="20px">
<ItemTemplate>
<asp:CheckBox ID="chkSeleccion" runat="server"
Checked="<%#((beProducto)Container.DataItem).Seleccion%>" />
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Código" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).IdProducto%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Descripción del Producto"
ItemStyle-Width="200px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).Nombre%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Id Prov" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).IdProveedor%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Id Cat" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).IdCategoria%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Pre Unit" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).PrecioUnitario.ToString("n2")%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Stock" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).Stock%>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</td>
</tr>
<tr>
<td class="Centrado">
<asp:Button ID="btnGrabar" Text="Grabar" runat="server"
OnClick="grabarProductosSeleccionados" />
</td>
</tr>
<tr>
<td><asp:Label ID="lblMensaje" Font-Bold="true" runat="server"/></td>
</tr>
</table>
</div>
</form>
</body>
</html>
El preview del diseño se mostrará similar a la siguiente figura:
Escribir el siguiente código C# en la página:
using System;
using System.Text; //StringBuilder
using System.Collections.Generic; //List
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
namespace GridView_Paginado_Checks
{
public partial class ListaProductos : System.Web.UI.Page
{
List<beProducto> lbeProducto;
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
brProducto obrProducto = new brProducto();
lbeProducto = obrProducto.listar();
Session["Productos"] = lbeProducto;
gvProducto.DataSource = lbeProducto;
gvProducto.DataBind();
}
else
{
guardarChecksPagina();
}
}
protected void paginarProductos(object sender, GridViewPageEventArgs e)
{
lbeProducto = (List<beProducto>)Session["Productos"];
gvProducto.PageIndex = e.NewPageIndex;
gvProducto.DataSource = lbeProducto;
gvProducto.DataBind();
}
private void guardarChecksPagina()
{
lbeProducto = (List<beProducto>)Session["Productos"];
int indice;
for (int i = 0; i < gvProducto.Rows.Count; i++)
{
indice = (gvProducto.PageIndex * gvProducto.PageSize) + i;
lbeProducto[indice].Seleccion =
((CheckBox)gvProducto.Rows[i].Cells[0].Controls[1]).Checked;
}
Session["Productos"] = lbeProducto;
}
protected void grabarProductosSeleccionados(object sender, EventArgs e)
{
StringBuilder sb = new StringBuilder("Ids Seleccionados: ");
lbeProducto = (List<beProducto>)Session["Productos"];
//List<beProducto> lbeSeleccion = lbeProducto.FindAll(x => x.Seleccion.Equals(true));
for (int i = 0; i < lbeProducto.Count; i++)
{
if (lbeProducto[i].Seleccion)
{
sb.Append(lbeProducto[i].IdProducto);
sb.Append(", ");
}
}
sb = sb.Remove(sb.Length - 2, 2);
lblMensaje.Text = sb.ToString();
}
}
}
Nota: La principal función es "guardarChecksPagina" que se llama en los PostBacks y permite guardar todos los checks de la pagina actual en la lista de objetos.
Además en la función controladora "grabarProductosSeleccionados" asociada al click del botón "btnGuardar" se usa un StringBuilder para concatenar los códigos de todos los checks seleccionados y mostrarlos en el Label "lblMensaje".
En esta función hay una linea comentada que permite crear una lista solo con los productos seleccionados, para nuestro caso solo se mostrará en pantalla, pero si se debe enviar al servidor solo los productos seleccionados usar esta linea y comentar el resto.
Modificar el Archivo Web.Config para especificar la cadena de conexión a Northwind
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<connectionStrings>
<add name="conNW" providerName="System.Data.SqlClient"
connectionString="uid=UsuarioNW;pwd=123456;data source=DSOFT\Sqlexpress;
initial catalog=Northwind"/>
</connectionStrings>
<system.web>
<compilation debug="true" targetFramework="4.5" />
<httpRuntime targetFramework="4.5" />
</system.web>
</configuration>
Probar la Pagina Web
Guardar el Sitio Web, clic derecho a la Pagina "ListaProductos.aspx" y seleccionar "Ver en el explorador". Se mostrará una ventana similar a la siguiente figura:
Seleccionar checks de diferentes paginas y verificar que se han quedado seleccionados al cambiar de pagina, luego click al botón "Guardar" para confirmar los códigos solo de los productos seleccionados, tal como se muestra en la siguiente figura:
Comentario Final
En este post hemos visto como mantener los registros seleccionados usando una columna tipo check en una grilla paginada, la cual usa plantillas de datos para las columnas y asocia la propiedad checked del checkbox a una propiedad Seleccion del modelo o entidad del negocio.
Descarga:
GridView_Paginado_Checks
Después de mas de 2 meses retomamos los posts de ASP .NET WebForms, en esta ocasión publicaré un caso práctico muy útil.
Requerimiento
Se desea listar registros en forma paginada usando el GridView pero mostrando una columna con Checks que permita seleccionar los registros para un uso posterior como grabar datos en el servidor.
Problema
Si creamos una grilla sin paginar con una columna de tipo CheckBox no hay problemas, pero si paginamos, al seleccionar los checks de una pagina y cambiar de pagina se perderán debido a que la grilla siempre se tiene que enlazar nuevamente para mostrar la pagina seleccionada.
Solución
Para solucionar el problema debemos enlazar la columna checkbox a una propiedad de la entidad del negocio de tipo boolean, luego debemos almacenar el valor seleccionado, lo cual se puede hacer de 2 formas:
1. Guardar el valor cada vez que se selecciona el check, ya sea para marcar o desmarcar.
2. Guardar los valores seleccionados al regresar al servidor ya sea al cambiar de página o al hacer PostBack mediante algún botón.
Definitivamente, la mejor opción es la segunda, es decir, cada vez que ocurra un Postback guardaremos los checks seleccionados de la pagina actual.
Crear el Procedimiento Almacenado en la Base de Datos de SQL Server
Create Procedure uspProductsListar
As
Select ProductID,ProductName,SupplierID,CategoryID,UnitPrice,UnitsInStock
From Products
Crear la Aplicación Web en ASP .NET Web Form
Crear un "Nuevo Sitio web vacío de ASP .NET" en C# llamado "GridView_Paginado_Checks".
Para simplificar el Demo no he creado librerías de clases y las clases las he incluido dentro de la aplicación Web.
Crear la Clase Entidad del Negocio
Crear la clase beProducto escribiendo el siguiente código:
using System;
namespace GridView_Paginado_Checks
{
public class beProducto
{
public bool Seleccion { get; set; }
public int IdProducto { get; set; }
public string Nombre { get; set; }
public int IdProveedor { get; set; }
public int IdCategoria { get; set; }
public decimal PrecioUnitario { get; set; }
public short Stock { get; set; }
}
}
Nota: La propiedad Seleccion es la que se va a enlazar al check para guardar el valor seleccionado.
Crear la clase daProducto escribiendo el siguiente código:
using System;
using System.Data; //CommadType
using System.Data.SqlClient; //SqlConnection, SqlCommand, SqlDataReader
using System.Collections.Generic; //List
namespace GridView_Paginado_Checks
{
public class daProducto
{
public List<beProducto> listar(SqlConnection con)
{
List<beProducto> lbeProducto = null;
SqlCommand cmd = new SqlCommand("uspProductsListar", con);
cmd.CommandType = CommandType.StoredProcedure;
SqlDataReader drd = cmd.ExecuteReader(CommandBehavior.SingleResult);
if (drd != null)
{
lbeProducto = new List<beProducto>();
int posIdProducto = drd.GetOrdinal("ProductID");
int posNombre = drd.GetOrdinal("ProductName");
int posIdProveedor = drd.GetOrdinal("SupplierID");
int posIdCategoria = drd.GetOrdinal("CategoryID");
int posPrecioUnitario = drd.GetOrdinal("UnitPrice");
int posStock = drd.GetOrdinal("UnitsInStock");
beProducto obeProducto;
while (drd.Read())
{
obeProducto = new beProducto();
obeProducto.IdProducto = drd.GetInt32(posIdProducto);
obeProducto.Nombre = drd.GetString(posNombre);
obeProducto.IdProveedor = drd.GetInt32(posIdProveedor);
obeProducto.IdCategoria = drd.GetInt32(posIdCategoria);
obeProducto.PrecioUnitario = drd.GetDecimal(posPrecioUnitario);
obeProducto.Stock = drd.GetInt16(posStock);
lbeProducto.Add(obeProducto);
}
drd.Close();
}
return (lbeProducto);
}
}
}
Nota: Tiene que haberse creado el Procedimiento Almacenado "uspProductsListar" en la BD Northwind.
Crear la Clase de Reglas del Negocio
Crear la clase brProducto escribiendo el siguiente código:
using System;
using System.Collections.Generic; //List
using System.Data.SqlClient; //SqlConnection
using System.Configuration; //ConfigurationManager
namespace GridView_Paginado_Checks
{
public class brProducto
{
public List<beProducto> listar()
{
List<beProducto> lbeProducto = null;
string conexion = ConfigurationManager.ConnectionStrings["conNW"].ConnectionString;
using (SqlConnection con = new SqlConnection(conexion))
{
try
{
con.Open();
daProducto odaProducto = new daProducto();
lbeProducto = odaProducto.listar(con);
}
catch (SqlException ex)
{
foreach (SqlError err in ex.Errors)
{
//Capturar cada error y grabar un Log
}
}
} //con.Close(); con.Dispose(); con = null;
return (lbeProducto);
}
}
}
Nota: Hay que hacer referencia a la librería "System.Configuration.dll" para usar la clase ConfigurationManager para leer el archivo de configuración.
Crear el Archivo de Hoja de Estilo
Agregar un archivo de hoja de estilo llamado ACME.css y escribir lo siguiente:
body {
background-color:aqua;
}
.Titulo {
background-color:black;
color:white;
text-transform:uppercase;
font-size:xx-large;
font-weight:bold;
}
.AnchoTotal {
width:100%;
}
.Centrado {
text-align:center;
}
.Subtitulo {
background-color:white;
color:blue;
text-transform:capitalize;
font-size:x-large;
font-weight:bold;
}
.FilaCabecera {
background-color: lightgray;
color:black;
}
.FilaDatos {
background-color: white;
color:blue;
}
Crear la Pagina ASP .NET como un Formulario Web Form
Agregar un Formulario Web Form al proyecto llamado: "ListaProductos.aspx" y escribir lo siguiente:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ListaProductos.aspx.cs" Inherits="GridView_Paginado_Checks.ListaProductos" %>
<%@ Import Namespace="GridView_Paginado_Checks" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
<link href="ACME.css" rel="stylesheet" type="text/css" />
</head>
<body>
<form id="form1" runat="server">
<div>
<table class="AnchoTotal">
<tr class="Titulo">
<td>Paginacion en un GridView con Columna de Checks</td>
</tr>
<tr class="Subtitulo">
<td>Selecciona de la Lista de Productos</td>
</tr>
<tr>
<td>
<asp:GridView ID="gvProducto" AllowPaging="true" AutoGenerateColumns="false"
Width="800px" runat="server" OnPageIndexChanging="paginarProductos">
<HeaderStyle CssClass="FilaCabecera" />
<RowStyle CssClass="FilaDatos" />
<PagerStyle CssClass="FilaCabecera" />
<Columns>
<asp:TemplateField ItemStyle-Width="20px">
<ItemTemplate>
<asp:CheckBox ID="chkSeleccion" runat="server"
Checked="<%#((beProducto)Container.DataItem).Seleccion%>" />
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Código" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).IdProducto%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Descripción del Producto"
ItemStyle-Width="200px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).Nombre%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Id Prov" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).IdProveedor%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Id Cat" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).IdCategoria%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Pre Unit" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).PrecioUnitario.ToString("n2")%>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Stock" ItemStyle-Width="80px">
<ItemTemplate>
<%#((beProducto)Container.DataItem).Stock%>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</td>
</tr>
<tr>
<td class="Centrado">
<asp:Button ID="btnGrabar" Text="Grabar" runat="server"
OnClick="grabarProductosSeleccionados" />
</td>
</tr>
<tr>
<td><asp:Label ID="lblMensaje" Font-Bold="true" runat="server"/></td>
</tr>
</table>
</div>
</form>
</body>
</html>
Escribir el siguiente código C# en la página:
using System;
using System.Text; //StringBuilder
using System.Collections.Generic; //List
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
namespace GridView_Paginado_Checks
{
public partial class ListaProductos : System.Web.UI.Page
{
List<beProducto> lbeProducto;
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
brProducto obrProducto = new brProducto();
lbeProducto = obrProducto.listar();
Session["Productos"] = lbeProducto;
gvProducto.DataSource = lbeProducto;
gvProducto.DataBind();
}
else
{
guardarChecksPagina();
}
}
protected void paginarProductos(object sender, GridViewPageEventArgs e)
{
lbeProducto = (List<beProducto>)Session["Productos"];
gvProducto.PageIndex = e.NewPageIndex;
gvProducto.DataSource = lbeProducto;
gvProducto.DataBind();
}
private void guardarChecksPagina()
{
lbeProducto = (List<beProducto>)Session["Productos"];
int indice;
for (int i = 0; i < gvProducto.Rows.Count; i++)
{
indice = (gvProducto.PageIndex * gvProducto.PageSize) + i;
lbeProducto[indice].Seleccion =
((CheckBox)gvProducto.Rows[i].Cells[0].Controls[1]).Checked;
}
Session["Productos"] = lbeProducto;
}
protected void grabarProductosSeleccionados(object sender, EventArgs e)
{
StringBuilder sb = new StringBuilder("Ids Seleccionados: ");
lbeProducto = (List<beProducto>)Session["Productos"];
//List<beProducto> lbeSeleccion = lbeProducto.FindAll(x => x.Seleccion.Equals(true));
for (int i = 0; i < lbeProducto.Count; i++)
{
if (lbeProducto[i].Seleccion)
{
sb.Append(lbeProducto[i].IdProducto);
sb.Append(", ");
}
}
sb = sb.Remove(sb.Length - 2, 2);
lblMensaje.Text = sb.ToString();
}
}
}
Nota: La principal función es "guardarChecksPagina" que se llama en los PostBacks y permite guardar todos los checks de la pagina actual en la lista de objetos.
Además en la función controladora "grabarProductosSeleccionados" asociada al click del botón "btnGuardar" se usa un StringBuilder para concatenar los códigos de todos los checks seleccionados y mostrarlos en el Label "lblMensaje".
En esta función hay una linea comentada que permite crear una lista solo con los productos seleccionados, para nuestro caso solo se mostrará en pantalla, pero si se debe enviar al servidor solo los productos seleccionados usar esta linea y comentar el resto.
Modificar el Archivo Web.Config para especificar la cadena de conexión a Northwind
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<connectionStrings>
<add name="conNW" providerName="System.Data.SqlClient"
connectionString="uid=UsuarioNW;pwd=123456;data source=DSOFT\Sqlexpress;
initial catalog=Northwind"/>
</connectionStrings>
<system.web>
<compilation debug="true" targetFramework="4.5" />
<httpRuntime targetFramework="4.5" />
</system.web>
</configuration>
Probar la Pagina Web
Guardar el Sitio Web, clic derecho a la Pagina "ListaProductos.aspx" y seleccionar "Ver en el explorador". Se mostrará una ventana similar a la siguiente figura:
Seleccionar checks de diferentes paginas y verificar que se han quedado seleccionados al cambiar de pagina, luego click al botón "Guardar" para confirmar los códigos solo de los productos seleccionados, tal como se muestra en la siguiente figura:
Comentario Final
En este post hemos visto como mantener los registros seleccionados usando una columna tipo check en una grilla paginada, la cual usa plantillas de datos para las columnas y asocia la propiedad checked del checkbox a una propiedad Seleccion del modelo o entidad del negocio.
Descarga:
GridView_Paginado_Checks
Etiquetas:
.NET,
ADO.NET,
AllowPaging,
ASP.NET,
C#,
CheckBox,
CSS,
Data Binding,
Data Templates,
Demos,
GridView,
Lduenas,
Listas Objetos,
NewPageIndex,
Paginar,
Session,
StringBuilder,
Templates,
Web Forms
lunes, 8 de septiembre de 2014
El Libro del Día: Programming Windows Store Apps with HTML, CSS, and JavaScript
El Libro del Día: 2014-09-08
Titulo: Programming Windows Store Apps with HTML, CSS, and JavaScript
Autor: Kraig Brockschmidt
Editorial: Microsoft
Nro Paginas: 1311
Capítulos:
Chapter 1 The Life Story of a Windows Store App: Characteristics of the Windows Platform
Chapter 2 Quickstart
Chapter 3 App Anatomy and Performance Fundamentals
Chapter 4 Web Content and Services
Chapter 5 Controls and Control Styling
Chapter 6 Data Binding, Templates, and Collections
Chapter 7 Collection Controls
Chapter 8 Layout and Views
Chapter 9 Commanding UI
Chapter 10 The Story of State, Part 1: App Data and Settings
Chapter 11 The Story of State, Part 2: User Data, Files, and OneDrive
Chapter 12 Input and Sensors
Chapter 13 Media
Chapter 14 Purposeful Animations
Chapter 15 Contracts
Chapter 16 Alive with Activity: Tiles, Notifications, the Lock Screen, and Background Tasks
Chapter 17 Devices and Printing
Chapter 18 WinRT Components: An Introduction
Chapter 19 Apps for Everyone, Part 1: Accessibility and World-Readiness
Chapter 20 Apps for Everyone, Part 2: The Windows Store
Appendix A Demystifying Promises
Appendix B WinJS Extras
Appendix C Additional Networking Topics
Appendix D Provider-Side Contracts
Descarga:
Programming_WindowsStore_Apps_HTML_CSS_JavaScript
Titulo: Programming Windows Store Apps with HTML, CSS, and JavaScript
Autor: Kraig Brockschmidt
Editorial: Microsoft
Nro Paginas: 1311
Capítulos:
Chapter 1 The Life Story of a Windows Store App: Characteristics of the Windows Platform
Chapter 2 Quickstart
Chapter 3 App Anatomy and Performance Fundamentals
Chapter 4 Web Content and Services
Chapter 5 Controls and Control Styling
Chapter 6 Data Binding, Templates, and Collections
Chapter 7 Collection Controls
Chapter 8 Layout and Views
Chapter 9 Commanding UI
Chapter 10 The Story of State, Part 1: App Data and Settings
Chapter 11 The Story of State, Part 2: User Data, Files, and OneDrive
Chapter 12 Input and Sensors
Chapter 13 Media
Chapter 14 Purposeful Animations
Chapter 15 Contracts
Chapter 16 Alive with Activity: Tiles, Notifications, the Lock Screen, and Background Tasks
Chapter 17 Devices and Printing
Chapter 18 WinRT Components: An Introduction
Chapter 19 Apps for Everyone, Part 1: Accessibility and World-Readiness
Chapter 20 Apps for Everyone, Part 2: The Windows Store
Appendix A Demystifying Promises
Appendix B WinJS Extras
Appendix C Additional Networking Topics
Appendix D Provider-Side Contracts
Descarga:
Programming_WindowsStore_Apps_HTML_CSS_JavaScript
Etiquetas:
App Data,
Collections,
Controls,
CSS,
Data Binding,
Files,
HTML,
Javascript,
Kraig Brockschmidt,
Layout,
Libros,
Microsoft,
Performance,
Sensors,
Services,
Templates,
User Data,
Views,
Web Content,
Windows Store
viernes, 5 de septiembre de 2014
El Libro del Día: Building Windows 8.1 Apps from the Ground Up
El Libro del Día: 2014-09-05
Titulo: Building Windows 8.1 Apps from the Ground Up
Autor: Emanuele Garofalo, Antonio Liccardi, Michele Aponte
Editorial: Apress
Nro Paginas: 377
Capítulos:
Chapter 1: Introduction to Windows 8.1
Chapter 2: Windows Runtime Environment
Chapter 3: Designing the User Experience
Chapter 4: Choose Your Way
Chapter 5: Managing the Application Life Cycle
Chapter 6: Start Up Your App
Chapter 7: Take Advantage of the Environment
Chapter 8: Data Management
Chapter 9: Listening to the World
Chapter 10: Accessibility and Globalization
Chapter 11: Sell Your App
Appendix A: Live Tile and Toast Templates
Appendix B: Windows Store Developer Account
Descarga:
Building_Windows8.1_Apps_GroundUp
Titulo: Building Windows 8.1 Apps from the Ground Up
Autor: Emanuele Garofalo, Antonio Liccardi, Michele Aponte
Editorial: Apress
Nro Paginas: 377
Capítulos:
Chapter 1: Introduction to Windows 8.1
Chapter 2: Windows Runtime Environment
Chapter 3: Designing the User Experience
Chapter 4: Choose Your Way
Chapter 5: Managing the Application Life Cycle
Chapter 6: Start Up Your App
Chapter 7: Take Advantage of the Environment
Chapter 8: Data Management
Chapter 9: Listening to the World
Chapter 10: Accessibility and Globalization
Chapter 11: Sell Your App
Appendix A: Live Tile and Toast Templates
Appendix B: Windows Store Developer Account
Descarga:
Building_Windows8.1_Apps_GroundUp
Etiquetas:
Accessibility,
Antonio Liccardi,
Application Life Cycle,
Apress,
Data Management,
Emanuele Garofalo,
Globalization,
Libros,
Live Tile,
Michele Aponte,
Templates,
Windows 8.1,
Windows Runtime,
Windows Store
jueves, 14 de agosto de 2014
El Libro del Día: Pro Silverlight 5 in C#
El Libro del Día: 2014-08-14
Titulo: Pro Silverlight 5 in C# (4th Edition)
Autor: Matthew MacDonald
Editorial: Apress
Nro Paginas: 970
Capítulos:
Chapter 1: Introducing Silverlight
Chapter 2: XAML
Chapter 3: Layout
Chapter 4: Dependency Properties and Routed Events
Chapter 5: Elements
Chapter 6: The Application Model
Chapter 7: Navigation
Chapter 8: Shapes and Transforms
Chapter 9: Brushes, Bitmaps, and Printing
Chapter 10: Animation Basics
Chapter 11: Advanced Animation
Chapter 12: Sound, Video, and Deep Zoom
Chapter 13: Silverlight 3D
Chapter 14: Styles and Behaviors
Chapter 15: Control Templates
Chapter 16: Multithreading
Chapter 17: Browser Integration
Chapter 18: Out-of-Browser Applications
Chapter 19: ASP.NET Web Services
Chapter 20: Data Binding
Chapter 21: Data Controls
Chapter 22: File Access
Chapter 23: Networking
Descarga:
Pro_Silverlight_5_C#
Titulo: Pro Silverlight 5 in C# (4th Edition)
Autor: Matthew MacDonald
Editorial: Apress
Nro Paginas: 970
Capítulos:
Chapter 1: Introducing Silverlight
Chapter 2: XAML
Chapter 3: Layout
Chapter 4: Dependency Properties and Routed Events
Chapter 5: Elements
Chapter 6: The Application Model
Chapter 7: Navigation
Chapter 8: Shapes and Transforms
Chapter 9: Brushes, Bitmaps, and Printing
Chapter 10: Animation Basics
Chapter 11: Advanced Animation
Chapter 12: Sound, Video, and Deep Zoom
Chapter 13: Silverlight 3D
Chapter 14: Styles and Behaviors
Chapter 15: Control Templates
Chapter 16: Multithreading
Chapter 17: Browser Integration
Chapter 18: Out-of-Browser Applications
Chapter 19: ASP.NET Web Services
Chapter 20: Data Binding
Chapter 21: Data Controls
Chapter 22: File Access
Chapter 23: Networking
Descarga:
Pro_Silverlight_5_C#
Etiquetas:
3D,
Animation,
Apress,
Bitmaps,
Brushes,
C#,
Elements,
Layouts,
Libros,
Matthew MacDonald,
Multithreading,
Navigation,
Printing,
Routed Events,
Shapes,
Silverlight,
Styles,
Templates,
Transforms,
XAML
domingo, 3 de agosto de 2014
El Libro del Día: Professional jQuery
El Libro del Día: 2014-08-03
Titulo: Professional jQuery
Autor: Cesar Otero
Editorial: Wrox
Nro Paginas: 338
Capítulos:
PART I JQUERY FUNDAMENTALS
CHAPTER 1 Getting Started
CHAPTER 2 JavaScript Primer
CHAPTER 3 The jQuery Core
CHAPTER 4 DOM Element Selection and Manipulation
CHAPTER 5 Event Handling
CHAPTER 6 HTML Forms, Data, and Ajax
CHAPTER 7 Animations and Effects
PART II APPLIED JQUERY
CHAPTER 8 jQuery UI Part I - Making Things Look Slick
CHAPTER 9 jQuery UI Part II - Mouse Interactions
CHAPTER 10 Writing Effective jQuery Code
CHAPTER 11 jQuery Templates
CHAPTER 12 Writing jQuery Plugins
CHAPTER 13 Advanced Asynchronous Programming with jQuery Deferred
CHAPTER 14 Unit Testing with QUnit
APPENDIX Plugins Used In this Book
Descarga:
Professional_jQuery
Titulo: Professional jQuery
Autor: Cesar Otero
Editorial: Wrox
Nro Paginas: 338
Capítulos:
PART I JQUERY FUNDAMENTALS
CHAPTER 1 Getting Started
CHAPTER 2 JavaScript Primer
CHAPTER 3 The jQuery Core
CHAPTER 4 DOM Element Selection and Manipulation
CHAPTER 5 Event Handling
CHAPTER 6 HTML Forms, Data, and Ajax
CHAPTER 7 Animations and Effects
PART II APPLIED JQUERY
CHAPTER 8 jQuery UI Part I - Making Things Look Slick
CHAPTER 9 jQuery UI Part II - Mouse Interactions
CHAPTER 10 Writing Effective jQuery Code
CHAPTER 11 jQuery Templates
CHAPTER 12 Writing jQuery Plugins
CHAPTER 13 Advanced Asynchronous Programming with jQuery Deferred
CHAPTER 14 Unit Testing with QUnit
APPENDIX Plugins Used In this Book
Descarga:
Professional_jQuery
Etiquetas:
AJAX,
Animations,
Asynchronous,
Cesar Otero,
DOM,
Effects,
Forms,
HTML,
Javascript,
jQuery,
jQuery UI,
Libros,
Plugins,
Professional,
QUnit,
Templates,
Wrox
miércoles, 18 de junio de 2014
Libro La Biblia de Visual Basic .NET - Preguntas de Repaso - Capítulo 5
Preguntas de Repaso: Desarrollando Aplicaciones Web con ASP .NET
1. En que espacio de nombres se
encuentra ASP .NET?
2. Con qué nombre se le conoce al IDE de
Visual Studio para desarrollar Sitios Web?
3. Menciona 3 Lenguajes con que podemos
desarrollar aplicaciones web en ASP .NET
4. Qué características de ASP .NET hacen
que las aplicaciones sean mas rápidas?
5. Por qué las páginas ASP .NET que usan
controles web pueden verse en cualquier Browser?.
6. Qué es un formulario web en ASP .NET?
7. Cómo se clasifican los controles del
servidor?
8. Por qué una pagina ASP .NET es lenta
solo la primera vez que carga?
9. Cómo se llama el proceso que ejecuta
los servicios del IIS?
10. En cuantas ubicaciones se puede crear
un nuevo sitio web?
11. Qué ejecutable debe correr en caso de
que no este registrado ASP .NET en IIS en vez de volver a instalar primero el
IIS y luego Visual Studio?
12. Qué es un control web intrínseco?
13. Mencione 5 controles web intrínsecos.
14. Cuando se trabaja con archivos en una
aplicación web, cuál es el directorio por defecto donde se leen o escriben los
archivos en disco?
15. A qué usuario debemos dar permiso en
la carpeta para que la aplicación web pueda leer o escribir un archivo en ASP
.NET?
16. En que lado debe realizarse las
validaciones de una página: en el cliente o el servidor y porqué?
17. Cómo se llama el algoritmo de
seguridad usado para comprobar si el que usa el sistema, por ejemplo la pagina
es un usuario o un programa.
18. Qué debe hacerse para que al generar
varios números al azar con consecutivamente no devuelvan el mismo número?
19. Cuál es la forma mas simple de subir
un archivo desde la pagina hacia el servidor?
20. Cuál es el tamaño máximo del archivo
por defecto al usar el control FileUpload y que debe hacerse para aumentar la
capacidad?
21. Cuál es la alternativa mas simple
para validar sin usar directamente Javascript en el cliente en ASP NET?
22. Menciona 3 controles de validación de
ASP .NET?
23. Con qué control web se valida que un
campo sea obligatorio?
24. Qué control de validación usaría para
validar una fecha?
25. Qué control de validación usaría para
validar un RUC, DNI ó teléfono?
26. Menciona 3 propiedades comunes de
todos los controles de validación.
27. Cuál es la propiedad mas importante
del control de validación que indica qué control se debe validar?
28. Cómo se llama el control que muestra
un resumen con los mensajes de error de todos los controles de validación?
29. Para qué se usan las Hojas de Estilo
en Cascada?
30. Qué ventajas tiene usar archivos CSS
en una página ASP .NET?
31. Para qué se usan las páginas
principales y qué extensión tienen?
32. Qué ventajas tiene usar páginas
principales en ASP .NET?
33. Menciona los 3 controles web de
navegación.
34. Con qué control web podemos ver la
ubicación donde nos encontramos en el sitio web?
35. Cómo se llama el archivo XML donde se
definen las páginas que tendrá el sitio web?
36. Cómo se llama el objeto que permite
enlazar un mapa de sitio en un Menú o en un TreeView?
37. Cuál es la forma más simple de implementar fichas en un
sitio web de ASP .NET?
38. Con qué propiedad del control web
MultiView se especifica que vista (View) se va a visualizar?
39. Que propiedad tienen los controles
web que indica que se debe guardar el estado o los valores en el cliente para
que no se pierdan al hacer Postback?
40. Cuál es el control web mas usado en
una aplicación con ASP .NET?
41. Cómo se llama la propiedad que
permite crear dinámicamente las columnas en un control GridView?
42. Qué pasos debe realizar para
personalizar columnas en un GridView?
43. Cuantos tipos de paginación podemos
tener en una aplicación web?
44. Qué propiedades debe configurase para
paginar un GridView?
45. En qué evento hay que programar la
paginación del GridView?
46. Qué propiedad debe configurase para
ordenar las columnas en un GridView?
47. En qué evento hay que programar la
ordenación en el GridView?
48. Qué evento del control GridView puede
usarse para crear dinámica mente controles?
49. Qué instrucción de enlace de datos es
mas eficiente: DataBinder.Eval o Container.DataItem?
50. Con qué propiedad del GridView se
especifica el registro que se va a editar?
51. Cuál es la diferencia entre guardar
un dato usando el objeto Session y usando el objeto ViewState?
52. Qué se debe hacer para que una
columna del GridView al pasar al modo edición no sea siempre un TextBox?
53. Cuál es la ventaja de usar plantillas
en controles enlazados a datos?
54. Menciona 3 controles web que soporten
plantillas.
55. Si se usa un control Repeater y se
enlaza a un origen de datos, que hace falta para visualizar sus datos?
56. Cuál es el principal elemento de una
plantilla que nunca debe faltar y especifica el diseño de las filas a
repetirse?
57. Con qué etiquetas (tags) se indica en
una plantilla que vamos a usar código incrustado del servidor, por ejemplo para
llamar a una función?
58. Cuál es la diferencia del control
DataList con respecto al Repeater?
59. Qué indica el elemento
AlternatingItemTemplate en una plantilla?
60. En qué tipo de controles (HTML o Web)
puede usarse el código incrustado del servidor?
61. Qué es una plantilla jerárquica y
para qué sirve?
62. En una plantilla de un DataList con
qué código incrustado del servidor se obtiene el índice de la fila actual
enlazada al origen de datos?
viernes, 13 de junio de 2014
El Libro del Día: ASP.NET jQuery Cookbook
El Libro del Día: 2014-06-13
Titulo: ASP.NET jQuery Cookbook
Autor: Sonal Aneel Allana
Editorial: Packt
Nro Paginas: 308
Capítulos:
Chapter 1: Working with ASP.NET Controls
Chapter 2: Validation of ASP.NET Controls
Chapter 3: Working with GridView Control
Chapter 4: Working with Image Control
Chapter 5: Animations in ASP.NET
Chapter 6: AJAX and ASP.NET (Part I)
Chapter 7: AJAX and ASP.NET (Part II)
Chapter 8: Client Templating in jQuery
Descarga:
ASP.NET_jQuery_Cookbook
Titulo: ASP.NET jQuery Cookbook
Autor: Sonal Aneel Allana
Editorial: Packt
Nro Paginas: 308
Capítulos:
Chapter 1: Working with ASP.NET Controls
Chapter 2: Validation of ASP.NET Controls
Chapter 3: Working with GridView Control
Chapter 4: Working with Image Control
Chapter 5: Animations in ASP.NET
Chapter 6: AJAX and ASP.NET (Part I)
Chapter 7: AJAX and ASP.NET (Part II)
Chapter 8: Client Templating in jQuery
Descarga:
ASP.NET_jQuery_Cookbook
Etiquetas:
.NET,
AJAX,
Animations,
ASP .NET,
Javascript,
jQuery,
Libros,
Packt,
Sonal Aneel Allana,
Templates
Suscribirse a:
Entradas (Atom)




















