Results 1 to 7 of 7
  1. #1
    chronjy is offline Novice
    Windows 10 Access 2010 32bit
    Join Date
    Apr 2021
    Posts
    4

    me.circle object hidden behind image control


    I have an image control and i make circle on the image control. with me.circle (500,500), 100
    but i cannot show the circle. because of the circle created behind the image control.
    how can i make the circle place onto the image control?
    Click image for larger version. 

Name:	2021-04-30_015932.jpg 
Views:	15 
Size:	39.2 KB 
ID:	45114
    Last edited by chronjy; 04-29-2021 at 05:27 PM.

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,521
    can you Rt-click on circle , position, bring to front.
    or on image, send to back

  3. #3
    chronjy is offline Novice
    Windows 10 Access 2010 32bit
    Join Date
    Apr 2021
    Posts
    4
    the circles were created by vba code, so, i cannot use right click. and the image control have no method of z-order..

    The test code below...

    Me.Circle (500, 500), 500, vbRed
    Me.Circle (700, 550), 400, vbBlue
    Me.Circle (600, 750), 150, vbGreen

  4. #4
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    DoMenuItem comes to mind but I'm afraid I don't know the syntax for that operation. Am playing with it and will post back if I find a solution.

    EDIT
    OK, would be DoCmd.Runcommand 53. However, using code I believe you'd have to put the form in design view, select the object and run the command - probably not practical. Can you not just make one image invisible? If the image you want to be on top is "sample" then maybe create that using Word Art, set its transparency to be a low value such that you will be able to see what's behind it. I have done this for a watermark on a report where the controls needed to be visible behind the watermark.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  5. #5
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    The following applies to the approach of swapping views and altering z-order. Works but I don't think you can prevent the screen flicker. Not something I would use:

    Code:
    Private Sub Command12_Click()
    Dim ctl As Control
    Dim strFrm As String
    
    strFrm = Forms!form1.Name
    DoCmd.Close acForm, strFrm
    DoCmd.OpenForm strFrm, acDesign
       For Each ctl In Forms(strFrm).Controls
          ctl.InSelection = False
       Next
    Forms(strFrm).Controls("image8").InSelection = True
    DoCmd.RunCommand 53
    DoCmd.Close, "form1", acSaveNo
    DoCmd.OpenForm "form1"
    
    End Sub
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  6. #6
    chronjy is offline Novice
    Windows 10 Access 2010 32bit
    Join Date
    Apr 2021
    Posts
    4
    i find new approach from your suggestion
    it is very impressive, it is very helpful for me. thank you.

  7. #7
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    You are welcome. Would you post your solution so that it might help someone in the future?
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 6
    Last Post: 09-18-2020, 09:06 PM
  2. Replies: 5
    Last Post: 07-10-2020, 12:41 PM
  3. Replies: 10
    Last Post: 02-25-2019, 07:36 PM
  4. Replies: 2
    Last Post: 03-14-2018, 11:10 AM
  5. Replies: 4
    Last Post: 05-02-2016, 04:33 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums