Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 04-11-2013, 02:42 PM
beginner beginner is offline How to prohibit the using of SHIFT key using VBA Windows 7 32bit How to prohibit the using of SHIFT key using VBA Office 2007
Advanced Beginner
How to prohibit the using of SHIFT key using VBA
 
Join Date: Sep 2011
Location: Europe
Posts: 45
beginner will become famous soon enough
Question SOLVED: How to prohibit the using of SHIFT key using VBA


Does anyone have VBA code
How to prohibit the use of SHIFT key using VBA when opening excel file
VBA code I want put in Workbook_Open()

Last edited by beginner; 04-12-2013 at 11:34 PM. Reason: Solved
Reply With Quote
  #2  
Old 04-12-2013, 07:42 PM
macropod's Avatar
macropod macropod is offline How to prohibit the using of SHIFT key using VBA Windows 7 64bit How to prohibit the using of SHIFT key using VBA Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,956
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

You cannot do that. If it was possible, virus writers could destroy your files. People can prevent you macro from running in other ways too (eg via their macro security settings or by starting Excel in safe mode). You cannot stop the users doing any of these things.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #3  
Old 04-12-2013, 11:33 PM
beginner beginner is offline How to prohibit the using of SHIFT key using VBA Windows 7 32bit How to prohibit the using of SHIFT key using VBA Office 2007
Advanced Beginner
How to prohibit the using of SHIFT key using VBA
 
Join Date: Sep 2011
Location: Europe
Posts: 45
beginner will become famous soon enough
Default SOLVED: How to prohibit the using of SHIFT key using VBA

Quote:
Originally Posted by macropod View Post
You cannot do that. If it was possible, virus writers could destroy your files. People can prevent you macro from running in other ways too
Thank you for answering
Reply With Quote
  #4  
Old 04-14-2013, 04:38 AM
niton niton is offline How to prohibit the using of SHIFT key using VBA Windows 7 64bit How to prohibit the using of SHIFT key using VBA Office 2010 64bit
Competent Performer
 
Join Date: Jul 2012
Posts: 102
niton is on a distinguished road
Default

Quote:
Originally Posted by beginner View Post
Does anyone have VBA code
How to prohibit the use of SHIFT key using VBA when opening excel file
VBA code I want put in Workbook_Open()
You can try forcing users to enable macros.

Hide all sheets on closing. Except for a prompt sheet telling them to enable macros.

Code:
For Each Sheet In Sheets 
    If Not Sheet.Name = "Prompt" Then 
        Sheet.Visible = xlSheetVeryHidden 
    End If 
Next
Unhide on opening, if macros are enabled.

Code:
For Each Sheet In Sheets 
    If Not Sheet.Name = "Prompt" Then 
        Sheet.Visible = xlSheetVisible 
    End If 
Next 

Sheets("Prompt").Visible = xlSheetVeryHidden
http://www.vbaexpress.com/kb/getarticle.php?kb_id=578



*******************
Consider rating the thread by going to the "Rate Thread" dropdown.
Reply With Quote
  #5  
Old 04-14-2013, 07:42 AM
macropod's Avatar
macropod macropod is offline How to prohibit the using of SHIFT key using VBA Windows 7 64bit How to prohibit the using of SHIFT key using VBA Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,956
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

I have already provided the OP with code to apply that kind of control (and more) in an earlier thread: https://www.msofficeforums.com/excel...t-working.html
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #6  
Old 04-17-2013, 10:48 AM
beginner beginner is offline How to prohibit the using of SHIFT key using VBA Windows 7 32bit How to prohibit the using of SHIFT key using VBA Office 2007
Advanced Beginner
How to prohibit the using of SHIFT key using VBA
 
Join Date: Sep 2011
Location: Europe
Posts: 45
beginner will become famous soon enough
Default

@niton: Thanks for the advice
@macropod: Thank you for your response and the link, I saw it and now I study
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to prohibit the using of SHIFT key using VBA Noob here - I need a shift calendar by days with count of shift. freeman Excel 8 09-12-2012 08:45 AM
How to prohibit the using of SHIFT key using VBA Shift cell right gsrikanth Excel Programming 2 01-17-2012 11:29 PM
All text shift to the left??? ewallet Word 1 06-21-2011 08:41 AM
How to prohibit the using of SHIFT key using VBA Shift key erratic Razz Outlook 2 05-04-2011 05:35 PM
Word 2003 Shift F3 FLMT Word 0 02-22-2009 08:11 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 03:27 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft