Coding optimization and performances
I am trying as much as I can how to optimize my code.
So I try to understand for example the performances issues between two ways of coding and of course which produce the same result.
For example, if I affect a background html color to a table I can write:
MyTable.Style.Add("background-color", Mycolor)
or I can do the same like that:MyTable.BackColor = ColorTranslator.FromHTML(Mycolor)
Indeed I have the same questions for many little things, like searching for a control:
Is it better to use Findcontrol, or if the DOM never change, access it directly by its child index position like MyParent.Controls.Item(1) ?
All these questions, must have an impact on performances. I would like to know too is the CLR at the end don't bother and create the same code.