+ Reply to Thread
Results 1 to 5 of 5

Worksheet.Protection userinterfaceonly:=true problem

  1. #1
    Registered User
    Join Date
    04-26-2007
    Posts
    10

    Worksheet.Protection userinterfaceonly:=true problem

    Hi there,

    Please excuse mistakes with my submission, am relatively new to posting.

    I have develeped a simple UI for an Access database with Excel, it is a workbook that contains 1 sheet. It builds an SQL query on a few selectable cell criteria and retrieves information from a central MSAccess Database.

    The user of this tool can then update this information and return it to the database. However, I have unlocked only certain range of columns and permitted editing. The remainder is for information only.

    With the Workbook Open event I have used the following to protect the sheet.
    Please Login or Register  to view this content.
    This does indeed protect the sheet but it has an undesirable effect in that the keyboard cursor movemens are restriced on the unlocked cells. Left & Right is fine. Up and Down keystrokes do not work. Very wierd.

    To resolve this I have set the worksheet property EnableSelection = 0 xlNoRestrictions.

    This will now allow full keyboard cursor use, but now has an undesired effect in allowing the non editible cells to be selected resulting in the familiar dialog box "The cell or chart you are trying to change is protected and therefore read only... etc.. etc..."

    I'd like to protect the sheet, and not allow the cells to be selected. I would have thought my original method would have accomplished this but for the undesired keyboard anomoly.

    Has anyone had similar experiences or can shed any light on the subject?

    Thank your for your time.
    Last edited by royUK; 09-17-2008 at 03:34 AM.

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,202
    You have other posts so you should know to use Code Tags in your posts, this is covered in the Rules.
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    04-26-2007
    Posts
    10

    Re: Worksheet.Protection userinterfaceonly:=true problem

    I'd appreciate any thoughts on this. I had zero luck so far in other forums also...

    http://www.vbaexpress.com/forum/show...460#post176460

  4. #4
    Valued Forum Contributor Richard Schollar's Avatar
    Join Date
    05-23-2006
    Location
    Hampshire UK
    MS-Off Ver
    Excel 2002
    Posts
    1,264

    Re: Worksheet.Protection userinterfaceonly:=true problem

    Can you post a sample workbook which exhibits this problem? Remove any confidential data first (and make sure the workbook isn't too big).

    Richard
    Richard Schollar
    Microsoft MVP - Excel

  5. #5
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,202

    Re: Worksheet.Protection userinterfaceonly:=true problem

    Are you using the direction arrows on the keyboard?

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Excel date problem
    By hermiod in forum Excel General
    Replies: 4
    Last Post: 07-16-2007, 10:22 AM
  2. Cut and Paste Problem
    By agila916 in forum Excel General
    Replies: 4
    Last Post: 07-09-2007, 05:36 PM
  3. Excel 2007/ Outlook 2007 mail Problem
    By Bostock in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-25-2007, 04:26 PM
  4. Countif funtions problem
    By mike4545 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-17-2007, 02:37 PM
  5. Cell function problem
    By itty in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-19-2007, 08:27 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1