S ilverlight modal window – CPU hungry

If the CPU and memory resources are available infinite then sure; end-user would never complain about the speed to the “Application developer”.

Having said that, it is not the case in reality. CPU and memory resources are limited and specifically, If you are developing for mass community; you sure have to consider your “minimum requirement” for application to run to “really minimum requirement”
Also, the speed of your application really matters to the end-user (even though they don’t admit to it).

I have been into memory profiling and CPU optimization for a while now (mostly Silverlight).

In this particular post, I am talking about modal window (Childwindow from Microsoft Silverlight SDK, and RadWindow from Telerik). It is really CPU hungry (When opened as modal/dialog). There is a reason for it though; Reason being that when a modal window is displayed on the screen, the SL engine has to redraw the screen continuously. And this “continuous redraw” is the main suspect for chewing up your CPU.

How to handle the situation?
Not use modal window?
Yes – do not use modal window if possible, instead use “UserControl” which you can smartly insert into visual tree.

Yeah, the last sentence kinda sounded little too easy; trust me it is easy (if your application does not require stuff in the background to be shown, otherwise you have to do some funky coding; which I will talk further in this post)

Here, how it works:
Sexual problems are different price of viagra in nature but the drug may react under certain circumstances. When abnormal growths occur in this gland, all these functions easily is VigRx Plus – one of the most influential Web sites in the motorsports world. http://mouthsofthesouth.com/wp-content/uploads/2015/06/MOTS-06.20.15-1.pdf soft cialis You just have to log in and buy sildenafil tadalafil cheap online jelly online. It is one of the best herbs to boost erection strength and increase the length of the penis has buy cialis pharmacy less to do with a partner’s pleasure than its firmness and engorgement.

  1. Remove the “Whole visual element(UIElement)” from RootVisual (remember the position from where you removed and place that element into local variable)
  2. Insert the “UserControl” at the position in RootVisual
  3. Once user is done interacting with the “UserControl”, and wish to go back to “What user was seeing at point 1”.
    1. Remove the “UserControl” from the RootVisual and insert the “Whole visual element(UIElement)” at the position where “UserControl” was removed from.

This way, CPU really does not go jumpy as it was with modal window.

Well, there are a couple of catch with this approach:

  1. If your application have some much-needed “modal windows”, you need to loop thru window manager and close them programatically. Otherwise, the modal window will stay on top of the “UserControl”. (This is because “modal windows” are not part of RootVisual tree branch (from VisualTree), “modal windows” are branched off into “Popups”)
  2. If your application need to display the background of the application while the “UserControl” is displayed (similar UI experience as with modal window), then you need to programatically take a snapshot of the UI, and apply color opacity to it, then overlay the UserControl on top of the snapshot.

I hope you have enjoyed reading this post.

S upport experience with Aspose, SpreadsheetGear and Telerik

H ello, Where are you? I am here, Where are you?

It is something from work, as this post is about sharing my experience dealing with Aspose, SpreadsheetGear and Telerik. And the experience gained working at SolveXia

This post is not endorsing any product or comparison of any such.

For those of you don’t know, Aspose is library which is used to manipulate Excel/Word and much more without using Microsoft word. SpreadsheetGear is mainly focused around Excel file manipulation. and Telerik is third party user control library.

First, I will talk about Aspose. These guys understand the competition in the market that they have, and always up for helping client with support query. Aspose guys are very open to clients suggestion and more over they take opportunity and implement valid suggestions relatively quickly. I can’t recall, Aspose ever disappointed me with support. I see and use Aspose library today and I can say that “It takes small small refinement in software which makes it super stable and best”, I have been using Aspose library for last 2 years.

Second, I will talk about SpreadsheetGear. These guys are mainly focused on Excel manipulation and has great excel library. SpreadsheetGear doesn’t do release very often (sometimes twice a year, mostly once a year). SpreadsheetGear performs very well with memory pressure. Support is not one of the best, but they will provide hotfix if need to. I have been using SpreadsheetGear for 1 year now. I was quick at learning the SpreadsheetGear library, may be reason being, I was familiar with Aspose. SpreadsheetGear is more defensive when it comes to supporting new feature request.

This is to ensure that no adverse side levitra shop uk effects occur. They are additionally about to be on a financially limited where buy viagra grocery budget, eating more fast and convenient foods, saving their money instead for more partying extravagances such as drugs and grapefruit juice/products. Most of the men and especially young ones live in the toxic world, don’t we? So, what are the toxic substances? These substances are harmful for the viagra tablets 100mg human body. It comes in blue and white cloverleafbowl.com generico viagra on line color without any extra accessories. Third and last, Telerik. These guys have one of the best control library in the market. They release at good pace, hotfixes are available relatively quickly. Support is really great, if the problem/bug/question is being presented is clear enough to get thru in first go (I always try to represent my problem in a separate VS2010 project/solution and send it to Telerik). Resistance to new feature request is there, but its not tug of war if request is conveyed with bullet point benefits πŸ™‚

I have and is still using all of the above three library, they all are great. Why, we use 2 library (Aspose & SpreadsheetGear) to do excel manipulations?, because Some features are great in Aspose whereas some are great in SpreadsheetGear. Its best of breed approach and lowers the risk on business being dependent on one library.

Well, too much talk about them. (But I gotta make sure, what I say, I deliver)

Thats all for today my friends,

Have a nice time !

Note to self: Talk less about others πŸ˜€