hello, i found in the msdn two methodes to change view type of the listview (icons,list,details,...),
the first methode is to use the function SetWindowLong with GWL_STYLE,
the second methode is to use the message LVM_SETVIEW,
i noticed that the LVM_SETVIEW is applicable only in windows xp,but i have no problem i am writting the program to windows xp, my question is what is the best methode to chage the view type,
thank you in advance.
Always send a specific message rather than use SetWindowLong if one is available. I can't remember where I saw this written but it was in MSDN somewhere.
The main reason is that SetWindowLong does not run any control-specific code that may be needed, especially if there is already data in the control. If there is a message that appears to do the same thing, there is probably a reason and you should use the message.
Cheers,
Zooba :U
thank you zooba for the information