Modal Window Picker in Visual Studio LightSwitch 2011


Visual Studio LightSwitch is a Microsoft tool used for building business applications. There are many controls available in LightSwitch which represent the data but a Modal Window Picker is a special control which represents the your data in a special way. The Modal Window picker has a special feature which provides the user with a strong search and filter capability across a number of different fields in a table.

How To use Modal Window Picker

Step 1 : First of all open Visual Studio LightSwitch->New project->Select LightSwitch->Select LightSwitch application->Write name (ModalWindowPicker)->Ok.


Step 2 : Click on create new table to create the table.


Step 3 : Create the tables as for example student and course.



Step 4 : Now we will establish a relationship among these tables.

click on relationship->Select name and multiplicity->Ok.


Step 5 : Now we will add a screen. Right-click on screens->Add screen.


Step 6 : Select new data screen->Select screen data (Student)->Ok.


Step 7 : In the same manner we will add a new data screen for the course table. Like as in the following image.


Step 8 : Expand course in CreateNewStudent screen->Select Modal Window Picker.


Step 9 : Run application (Press F5). Click on create new course->Write the name of course->Save.

In the same way you can create many courses.


Step 10 : Now click on create new student->Fill data.

When you will click on courses then open a modal window in which you can pick any course then ok and save.


Step 11 : When you select MCA course from the modal window then your screen will display the student information as in the following image.



So in this article you saw, how to use Modal Window Picker in LightSwitch application.

Some Helpful Resources