Patrick Winkler Posted October 11, 2016 Share Posted October 11, 2016 (edited) Hello, I'm failing to assign a color to a LB cell. It should look like this: # Init col_color_idx = vs.InsertLBColumn(dialogID, kList_Brws, i, strings.col_clr, 40) vs.SetLBItemDisplayType(dialogID, kList_Brws, i, 1) #xxx vs.SetLBColumnOwnerDrawnType(dialogID, kList_Brws, i, col_color_idx, OwnerDrawType_Enum.solid_rect ) ... instert_pos = 0 i = vs.InsertLBItem(dialogID, kList_Brws, instert_pos, '???') ... vs.SetLBItemFillForeColor(dialogID, kList_Brws, i, col_color_idx, redIndex, greenIndex, blueIndex) vs.SetLBItemFillBackColor(dialogID, kList_Brws, i, col_color_idx, redIndex, greenIndex, blueIndex) vs.SetLBItemPenBackColor(dialogID, kList_Brws, i, col_color_idx, redIndex, greenIndex, blueIndex) vs.SetLBItemPenForeColor(dialogID, kList_Brws, i, col_color_idx, redIndex, greenIndex, blueIndex) What am I doing wrong? thanks Edited October 11, 2016 by Patrick Winkler Quote Link to comment
Patrick Winkler Posted October 11, 2016 Author Share Posted October 11, 2016 I got it, in case some one wants to know how: # Init Column: ... vs.SetLBItemDisplayType(dialogID, kList_Brws, i, 1) # Icon Only ... # Add a Line ... vs.SetLBColumnOwnerDrawnType(dialogID, kList_Brws, i, col_color_idx, 1 ) # Solid Rect ... vs.SetLBItemFillForeColor(dialogID, kList_Brws, i, col_color_idx, redIndex, greenIndex, blueIndex) vs.SetLBItemFillBackColor(dialogID, kList_Brws, i, col_color_idx, redIndex, greenIndex, blueIndex) ... Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.