This is a migrated thread and some comments may be shown as answers.

Logviewer(listbox) not updating synchronously

0 Answers 40 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Deepak
Top achievements
Rank 1
Deepak asked on 28 Jan 2012, 11:16 AM

I have used MVVm pattern in my application having three views.I wanted display log messages(status,error etc) in 1st window( in listbox ).I have created singleton class(loghelper) with function AddLog(),which i am calling whever i wanna update log msg & to write to log file also.so whenver this method gets called ,it triggers event(in loghelper class) and the eventhandler in respective view model gets called and there it adds log messages to Source(ObservableCollection which is bound to list box).
Now the problem is eventhough log message is added to collection for each log msg ,message is not updating synchronously in list box.View looks like freezing for a minute and all messages updates at a time.
I am not using multithreading here.
plz Let me know what causes this problem?

No answers yet. Maybe you can help?

Tags
General Discussions
Asked by
Deepak
Top achievements
Rank 1
Share this question
or