Cree un componente personalizado para el interruptor de luz

I will have to use lightswitch for a project.

I know that we can create some UserControl, and specify "Custom usercontrol" when selecting the way to display the information.

But, is it possible to create a generic userControl, which can be selected the same way as "Grid" or "List"?

Because I've some usercontrol libraries and I would like to use some user control of it in a generic manner?

(e.g. have my custom usercontrol which display a grid, and still have the possibility to select which column will be displayed without having to create a new usercontrol for each datatype)


preguntado el 08 de noviembre de 11 a las 10:11

2 Respuestas

A reference for custom controls is lightswitchhelpwebsite.

You should to know that create a 'specific' custom control is easy but create a generic custom control is quite dificult. Then, it is not possible to write here document, code and samples to make a generic custom control.

Michael Washington (Microsoft) says that their book explains how to do this: Michael Washington's book can help to you.

Another interesting resource is Visual Studio LightSwitch Training Kit Jul.2011

respondido 11 nov., 11:02

The best way to do this is to write a Custom Control Extension. You can find out more details on how to do this through the MSDN help page.

respondido 09 nov., 11:16

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.