Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Disabling "group edit" mode in Excel

137 views
Skip to first unread message

sundarvenkata

unread,
Mar 18, 2009, 9:48:26 AM3/18/09
to
Hi All,

Is there a way to disable the "group edit" mode in Excel completely?

Or is it atleast possible to program an add-in that will prevent the
user from editing data into any cell while in "group edit" mode?

Thanks,
Sundar

@consumerdotorg Bernie Deitrick

unread,
Mar 18, 2009, 12:41:38 PM3/18/09
to
Sundar,

Put this into the codemodule of the Thisworkbook object:

Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)
If ActiveWindow.SelectedSheets.Count > 1 Then
With Application
.EnableEvents = False
.Undo
MsgBox "Oh, please don't group the sheets..."
ActiveWindow.SelectedSheets(1).Select 'Ungroups
.EnableEvents = True
End With
End If
End Sub


--
HTH,
Bernie
MS Excel MVP


"sundarvenkata" <sundar...@gmail.com> wrote in message
news:b92c23b7-7c34-4a45...@c11g2000yqj.googlegroups.com...

sundarvenkata

unread,
Mar 18, 2009, 1:11:05 PM3/18/09
to
Hi Bernie,

Thanks for the help!

I was wondering if there is a way I could make this work for any excel
file I open instead of just the current "excel" file.

Thanks,
Sundar

@consumerdotorg Bernie Deitrick

unread,
Mar 18, 2009, 2:04:30 PM3/18/09
to
Sundar,

You can use application events:

http://www.cpearson.com/excel/AppEvent.aspx

HTH,
Bernie
MS Excel MVP


"sundarvenkata" <sundar...@gmail.com> wrote in message

news:7fd881a0-e98e-4dae...@g38g2000yqd.googlegroups.com...

sundarvenkata

unread,
Mar 18, 2009, 3:50:11 PM3/18/09
to
Hi Bernie,

I cannot thank you enough for your help!

Thanks,
Sundar

0 new messages