Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > .NET 3.5 and Visual Studio. 2008 > .NET Framework 3.5
.NET Framework 3.5 For discussion of the Microsoft .NET Framework 3.5.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the .NET Framework 3.5 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old February 1st, 2010, 10:53 AM
Registered User
Join Date: Jan 2010
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Firing 1 usercontrol used for 3 different window at page load with different data

Hi Every one,

Iam Divya working as developer. I had some issues. In my 2 years this is the first forum i saw which is very active in posting the answers. I hope you could solve this also.

Here is my app description:
We are following Model -View -View Model Pattern for WPF Window Project. I have an Window (contains only an XamData Grid) Which is complete User control.
This User Control is used in 3 windows(Male Window, Female, Child) Under 3 tabs.

These 3 windows displays different window data in the grid on Page Load . the type of data(male data, female data, Child data) in grid depends on below navigation path .

Children Window--------------->>child ID,stage ID (parameters)------>> Child tab open----->> diplay Child data

Gents Window -------------->> case ID, male ID( parameters)---------->>Male tab open----->> display Male data

Ladies Window----------------->>pass id, birth id, job id(parametsr)---------->>Female tab open ----->> display Female data.

I have one View -- that is Usercontrol with Xam data grid ( having 12 columns). All the 3 windows have the same columns but different data is displayed in page load ( depends on different navigation which passes diiferent parameters for each window to display.

I have only one view model--

#Region "Constructors"
Public Sub New(ByVal context As WInfoContext)
ContextInfo = context

' This loads data on page .

mUnitList = GetUnitList()

End Sub


HomePage.VB (from here the windows are launched)
Private Sub UnitListClick(ByVal sender As Object, ByVal e As Navigation)

Dim target As New WindowLaunch()

With target

.ContentType = GetType(UnitListView)

End With

e.NewContentInfo = target

e.NewContentBehavior = ContentLoadBehavior.NewWindow

End Sub


This page contains a XAMDATAGRID and left navigation links/tabs. By selecting the stage or case(depending on the selected stage of male /female/child ,it displays that particular window through left navigation/tabs

How to display different window data on diffrent tabs page loads. I have only 1 constructor in View model. How does this works?? How to invoke my single constructor for 3 window displays. I heard that this forum is having full of dotnet experts. Please let me know if you need any more data.

Thanking you in advance.

Similar Threads
Thread Thread Starter Forum Replies Last Post
how to prevent a web page/window page from copying pradeeppatnaik81 C# 2 April 9th, 2008 03:36 AM
Page won't load data in IE rinventive PHP How-To 8 June 23rd, 2006 10:03 PM
trying to load db data into data grid itsajourney Beginning VB 6 2 June 7th, 2005 12:05 PM
Grid Page IndexChanged Event not Firing srinuRocks General .NET 1 March 14th, 2005 01:27 AM
set size of window on load SoC Javascript How-To 3 September 14th, 2004 03:22 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.