Spell check on a protected sheet

  • Thread starter Thread starter jontait
  • Start date Start date
J

jontait

Hi there

Does anyone know how to allow the spell check function on a protecte
sheet. I.e., is it possible to provide some code that would work when
command button is pressed that would then unprotect the sheet b
automatically entering the password, do the spell check, the
re-protect the sheet again?

Or anyway to tell excel that its ok to allow the spell check functio
on the sheet even though its protected?

Many thank
 
Hi
AFAIK this is not possible. You can create a macro which unprotects
your sheet first though. Just record a macro while doing this manually
 
You must unprotect the sheet first.

Record a macro while unprotecting, running spell check then re-protecting.

Or copy/paste this code to a general module.

Sub Spell_Check()
ActiveSheet.Unprotect Password:="password"
Cells.CheckSpelling SpellLang:=1033
ActiveSheet.Protect Password:="password", DrawingObjects:=True, _
Contents:=True, Scenarios:=True
End Sub

Remember to also password-protect your VBA project so users can't see the
unprotect/protect password.

Gord Dibben Excel MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top