+ Reply to Thread
Results 1 to 1 of 1

Image on protected sheet.

Hybrid View

  1. #1
    Registered User
    Join Date
    09-02-2013
    Location
    Poland
    MS-Off Ver
    Excel 2010
    Posts
    1

    Image on protected sheet.

    Hi,
    I have a worksheet "details" where if "valDetailsPosition" value is changed then on worksheet "Sheet1" image "imgDetails" is visible in top, left cell defined as "labelcovercell" range.

    This work good until I set a protection in "Sheet1" sheet. It causes that the image "imgDetails" is not changing their position on "Sheet1" in range defined in "labelcovercell" (is still at the same place).

    I noticed that it works when I set a protection with

    ActiveSheet.Protect DrawingObjects:=False, Contents:=True, Scenarios:=True
    and it doesn't when protection is set as

    ActiveSheet.Protect DrawingObjects:=True, Contents:=True, Scenarios:=True
    Can someone write me how to protect that sheet so that the image change their positin and the user can not select it?

    Below whole code located in "details" sheet:

    Private Sub Worksheet_Change(ByVal Target As Range)
    
    Dim labelcovercell As String
    Dim ShName As Worksheet
    Dim Rng As Range
    
    labelcovercell = Worksheets("details").Range("valDetailsPosition").Value
    
    Set ShName = ActiveWorkbook.Worksheets("Sheet1")
    Set Rng = ShName.Range(labelcovercell)
    
    
        If Not Intersect(Target, Range("valDetailsPosition")) Is Nothing Then
    
            With Sheets("Sheet1")
            
                With .Shapes("imgDetails")
                    .Left = .Parent.Range(labelcovercell).Left
                    .Top = .Parent.Range(labelcovercell).Top
            
                End With
                
                .Shapes("imgDetails").Visible
            End With
    
        End If
        
    
    End Sub
    Last edited by pietka57; 05-09-2014 at 05:21 AM.

+ 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. [SOLVED] Linking Image to a cell value, and display the selected image in new sheet
    By siva venkata in forum Excel General
    Replies: 12
    Last Post: 03-25-2014, 02:34 AM
  2. Insert image and image name into specific place on sheet
    By ACE23 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-05-2014, 04:41 AM
  3. Delete rows in a protected sheet with protected cells
    By Maranwe in forum Excel General
    Replies: 7
    Last Post: 10-31-2011, 08:12 AM
  4. Insert signature image - password protected
    By Dusty Hoffman in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-11-2008, 10:41 PM
  5. [SOLVED] How do I insert an image into a specific cell within a protected .
    By Scott Peebles in forum Excel General
    Replies: 1
    Last Post: 01-06-2005, 10:06 PM

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