Click here to Skip to main content
15,894,405 members
Home / Discussions / WPF
   

WPF

 
AnswerRe: WPF Handling Events In MVVM Pin
El_Codero15-Feb-12 12:34
El_Codero15-Feb-12 12:34 
QuestionWPF ListBox As Hyperlinks Pin
Kevin Marois13-Feb-12 15:30
professionalKevin Marois13-Feb-12 15:30 
AnswerRe: WPF ListBox As Hyperlinks Pin
Abhinav S13-Feb-12 19:53
Abhinav S13-Feb-12 19:53 
QuestionDrag two columns in Datagrid Pin
Defender-NF12-Feb-12 22:49
Defender-NF12-Feb-12 22:49 
QuestionWPF Binding Tree Node Expanded Pin
Kevin Marois12-Feb-12 7:31
professionalKevin Marois12-Feb-12 7:31 
AnswerRe: WPF Binding Tree Node Expanded Pin
SledgeHammer0112-Feb-12 10:21
SledgeHammer0112-Feb-12 10:21 
GeneralRe: WPF Binding Tree Node Expanded Pin
Kevin Marois13-Feb-12 15:30
professionalKevin Marois13-Feb-12 15:30 
QuestionHow can I find out that a UserControl is Rendered ? Pin
rdinca9-Feb-12 19:21
rdinca9-Feb-12 19:21 
I have the following code from inside the UserControl.cs:

public void wait()
{
int i = 0;
while (i < 10)
{
i++;
System.Threading.Thread.Sleep(1000);
}
}

private void IsLoaded(object sender, RoutedEventArgs e)
{
wait();
}


I just want to wait 10 seconds AFTER the layout is rendered(you can see the buttons).

If i execute the code now, it will first wait 10 seconds and then it will render the layout.
I already tried with IsLoaded event for UserControl as you can see in the text and it is not working.


Now, the question I asked was in another context. The real situation is like this:

I have a Window from where I render different(Children.Add(UserControl)) UserControls after doing different calculations in the MainWindow.

The problem is that when I try to update a TextBlock from one of the UserControls by using a Method from the parent Window, the visual update(the text being modified) takes place at the end of the method. And because the operations inside the method takes a few second, a lag between action and display appears.

I have tried: UpdateLayou() after updating but it is not working.

Is there any possible way to render a UserControl immediately after I update one of its fields ?

I need to work using this architecture because I work with Windows Messages in WndProc.
AnswerRe: How can I find out that a UserControl is Rendered ? Pin
Abhinav S9-Feb-12 20:27
Abhinav S9-Feb-12 20:27 
GeneralRe: How can I find out that a UserControl is Rendered ? Pin
rdinca9-Feb-12 20:40
rdinca9-Feb-12 20:40 
AnswerRe: How can I find out that a UserControl is Rendered ? Pin
Abhinav S9-Feb-12 20:46
Abhinav S9-Feb-12 20:46 
AnswerRe: How can I find out that a UserControl is Rendered ? Pin
SledgeHammer0110-Feb-12 5:36
SledgeHammer0110-Feb-12 5:36 
QuestionExtracting cell content using ItemsSource in WPF DataGrid Pin
retZ9-Feb-12 3:39
retZ9-Feb-12 3:39 
AnswerRe: Extracting cell content using ItemsSource in WPF DataGrid Pin
Mycroft Holmes9-Feb-12 13:21
professionalMycroft Holmes9-Feb-12 13:21 
GeneralRe: Extracting cell content using ItemsSource in WPF DataGrid Pin
retZ9-Feb-12 13:38
retZ9-Feb-12 13:38 
QuestionHow to style Menu control (wpf) to remove left grid Pin
chayan127-Feb-12 20:08
chayan127-Feb-12 20:08 
AnswerRe: How to style Menu control (wpf) to remove left grid Pin
Pete O'Hanlon8-Feb-12 0:04
mvePete O'Hanlon8-Feb-12 0:04 
QuestionWindows 8 App Not Launching Pin
Kevin Marois7-Feb-12 8:04
professionalKevin Marois7-Feb-12 8:04 
AnswerRe: Windows 8 App Not Launching Pin
Pete O'Hanlon7-Feb-12 8:20
mvePete O'Hanlon7-Feb-12 8:20 
GeneralRe: Windows 8 App Not Launching Pin
Kevin Marois7-Feb-12 8:23
professionalKevin Marois7-Feb-12 8:23 
GeneralRe: Windows 8 App Not Launching Pin
Pete O'Hanlon7-Feb-12 8:31
mvePete O'Hanlon7-Feb-12 8:31 
GeneralRe: Windows 8 App Not Launching Pin
Kevin Marois7-Feb-12 8:36
professionalKevin Marois7-Feb-12 8:36 
GeneralRe: Windows 8 App Not Launching Pin
Kevin Marois7-Feb-12 8:46
professionalKevin Marois7-Feb-12 8:46 
GeneralRe: Windows 8 App Not Launching Pin
Pete O'Hanlon7-Feb-12 8:58
mvePete O'Hanlon7-Feb-12 8:58 
QuestionWPF Apps On Windows 8 Pin
Kevin Marois7-Feb-12 6:59
professionalKevin Marois7-Feb-12 6:59 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.