+ Reply to Thread
Results 1 to 11 of 11

Stopping movement of shapes excel 2010

  1. #1
    Registered User
    Join Date
    04-24-2012
    Location
    UK
    MS-Off Ver
    Excel 2010
    Posts
    9

    Stopping movement of shapes excel 2010

    Hi
    I have previously had some experience of visual basic, but with office 2003.

    I have now begun a project to write a recipe book with excel 2010. I have a `menu` page which links to various tabs ( sheets) via VBA, which hold the recipe information. These`sheets` have various shapes which have a Macro attached to navigate back to the menu page.

    I want to lock these shapes from moving or being dragged / accidentally deleted, but still allowing text to be entered / modified in the cells.

    I would have thought this to be easy, but can`t find a way of doing it.

    Any help would be appreciated

    Thanks

    Calibra

  2. #2
    Valued Forum Contributor
    Join Date
    03-25-2004
    Location
    Boston, MA US
    Posts
    1,094

    Re: Stopping movement of shapes excel 2010

    Hi Calibra,

    Right mouse click on the image and select "Size and Properties". On the properties tab select "Don't move or size with cells" and be sure that "Locked" is checked. When you protect your sheet users will not be able to select the picture. Before protecting the sheet, select the range you want users to be able to edit, right mouse click on the selected range, go to Format Cells. On the protection tab deselect "Locked". When your all done you can protect your sheet and only those cells will be able to be edited.

    HTH
    Steve

  3. #3
    Registered User
    Join Date
    04-24-2012
    Location
    UK
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Stopping movement of shapes excel 2010

    Thanks
    Only problem is there are macros attached to the shapes.........so they need to be `clicked on` but i want to prevent them being dragged around.

    I have a feeling this isn`t going to be possible !!!!

  4. #4
    Valued Forum Contributor
    Join Date
    03-25-2004
    Location
    Boston, MA US
    Posts
    1,094

    Re: Stopping movement of shapes excel 2010

    Use an ActiveX Command button and in the properties you can add a picture to it. Then on the click event for the command button call your macro.

    HTH
    Steve

  5. #5
    Valued Forum Contributor
    Join Date
    03-25-2004
    Location
    Boston, MA US
    Posts
    1,094

    Re: Stopping movement of shapes excel 2010

    My first suggestion worked fine for me. Even after protecting and locking the picture, when I clicked on it it still ran my macro.

    Steve

  6. #6
    Registered User
    Join Date
    04-24-2012
    Location
    UK
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Stopping movement of shapes excel 2010

    Quote Originally Posted by SteveG View Post
    Hi Calibra,

    Right mouse click on the image and select "Size and Properties". On the properties tab select "Don't move or size with cells" and be sure that "Locked" is checked. When you protect your sheet users will not be able to select the picture. Before protecting the sheet, select the range you want users to be able to edit, right mouse click on the selected range, go to Format Cells. On the protection tab deselect "Locked". When your all done you can protect your sheet and only those cells will be able to be edited.

    HTH
    Steve
    Hi

    Thanks
    Is this the method you said worked for you ??? because you said "When you protect your sheet users will not be able to select the picture. " Does this mean they can`t click on it also ???

    Thanks

    Calibra

  7. #7
    Valued Forum Contributor
    Join Date
    03-25-2004
    Location
    Boston, MA US
    Posts
    1,094

    Re: Stopping movement of shapes excel 2010

    Yes. You can click on it and it will trigger the macro. When I said select I meant they couldn't move or edit the picture.

    Steve

  8. #8
    Registered User
    Join Date
    04-24-2012
    Location
    UK
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Stopping movement of shapes excel 2010

    Just tried this

    But I can still right click on images and move them

    Using `first` method

    Thanks

  9. #9
    Valued Forum Contributor
    Join Date
    03-25-2004
    Location
    Boston, MA US
    Posts
    1,094

    Re: Stopping movement of shapes excel 2010

    Hi,

    I am not having the same issue. I cannot move the pictures at all so maybe you missed a step? Can post a sample of the workbook?

    Steve

  10. #10
    Registered User
    Join Date
    10-07-2013
    Location
    Calgary,Canada
    MS-Off Ver
    Excel 2010
    Posts
    1

    Re: Stopping movement of shapes excel 2010

    Hi Steve

    The method specified by you to fix the shapes in place does not really work. After opening and closing the workbook a few times the shapes relocate by themselves. The text box got the most visible movement. The arc and other liniar shapes are OK.
    Is there a way of "fixing" the location of those text boxes?
    If you want I can send you a sample with a drawing so you can see for youself what I mean.

    Cheers
    Catalin

  11. #11
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,167

    Re: Stopping movement of shapes excel 2010

    CatalinP,

    Unfortunately you need to post your question in a new thread, it's against the forum rules to post a question in the thread of another user. If you create your own thread, any advice will be tailored to your situation so you should include a description of what you've done and are trying to do. Also, if you feel that this thread is particularly relevant to what you are trying to do, you can surely include a link to it in your new thread.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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