guyfromfl Posted April 17, 2007 Share Posted April 17, 2007 I am trying to change an object's color by passing a variable to the object I know i left alot out but this is just to show you what i have in mind: sub mnuColorsBlue_click strBackColor = "Color.Blue" changeColor(strBackColor) end sub sub changeColor(strBackColor) me.mnuMoney.BackColor = strBackColor end sub is this even possible? vb keeps telling me the color has to be less than infinity Link to comment https://forums.phpfreaks.com/topic/47336-vb-2005-change-an-objects-color-using-a-variable/ Share on other sites More sharing options...
Dreous Posted April 19, 2007 Share Posted April 19, 2007 Have you tried somehtng like newColor = _ Color.(255, 0, 0, 0) ( which is black) try writing it in a value instead of the color it self. Link to comment https://forums.phpfreaks.com/topic/47336-vb-2005-change-an-objects-color-using-a-variable/#findComment-232989 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.