MrExcel Publishing
Your One Stop for Excel Tips & Solutions

Problem with Interior.ColorIndex


Posted by Juan Pablo Gonzalez on September 04, 2001 9:33 AM

Hello,

I'm having a problem when trying to assign the Interior.ColorIndex property to a range. I'm getting the following error:

"Impossible to assign the ColorIndex property of the Interior class"

Any help please ?

Thanks

Juan Pablo


Posted by Chris on September 04, 2001 9:37 AM

Try this code if the range is selected:

Selection.interior.ColorIndex = 46

else try:

range("a2:b3").interior.colorindex = 46

Hope this helps

Chris

Posted by Juan Pablo on September 04, 2001 9:40 AM

I'm doing this:

Range("H77:T77,Q105:AF111").Interior.ColorIndex = -4142

Also, i tried to Activate the sheet, activate the range, select the range... i don't know what's wrong...


Posted by Chris on September 04, 2001 9:47 AM

Are the sheets protected? I'm doing this: Range("H77:T77,Q105:AF111").Interior.ColorIndex = -4142 Also, i tried to Activate the sheet, activate the range, select the range... i don't know what's wrong...

Posted by Juan Pablo on September 04, 2001 9:50 AM

I forgot to unprotect before this one, thank you. Are the sheets protected? : I'm doing this