c# - tabControlPages remove picture -


try find solution next - on mouseenter - show picture on tabcontrol page , on mouseleave - clear it. done - show pic on tab.

there lot of question refered "how show" picture - this , this or this ant lot of others. use next way - add imagelist , show pic on mouseenter -

private void tabcontrolpages_mouseenter(object sender, eventargs e)     {         tabpageadd.imageindex = 0;     } 

for removing - try read methods on msdn - have found nothing (maybe not found). variant think, can put in collection transparent icon , change on mouseleave, think it's not perfect solution. if use imagelisticons.images.clear(); - it's clear imagelist - , expected.

so, ther solution avaliable correct way hide/show icon on tab tabcontrol ?

just set imageindex = -1 remove tab icon:

private void tabcontrolpages_mouseleave(object sender, eventargs e) {     tabpageadd.imageindex = -1; } 

Comments

Popular posts from this blog

c++ - CryptStringToBinary API behavior -

c++ - Correct method for redrawing a layered window -

java.util.scanner - How to read and add only numbers to array from a text file -