Dears,

Please I need your support as I'm using the below VBA code to insert my charts as picture in my userform but this action not allow to update the charts so when I searched to find another way to do it I found another one but by adding temp files for this charts in the worksheet path, I have almost 40 charts for my data tables which will be also shown in my userform ...so my goal is to show each table in the userform beside Two charts One for accounts and the 2nd for amount .

briefly

My question is ... How when I select the 1st Item In my conbobox it will show chart No.1 & chart No.2 together in Image No1. & Image No.3 beside item 1 data table ..And then when select 2nd Item in combobox will show chart No.3 and chart No.4 ..... & so on .


My current vba code :-


Private Sub UserForm_Initialize()

Dim X As Integer
For X = 2 To 200

If Worksheets("Fishing Regulations").Cells(X, 2).Value = "" Then Exit For
ComboBox2.AddItem (Worksheets("Fishing Regulations").Cells(X, 2).Value)
Next X

End Sub

Private Sub ComboBox2_Change()

Dim myfish As String
Dim X As Integer
myfish = ComboBox2.Value

' The below code which I need to change to be chartobject not picture ( I mean when I select data from combobox2 will find chart number 1 & 2 and add this charts to Image 1 & Image 3)

Select Case myfish
Case "01-Sep-20"
userform2.Image1.Picture = _
Worksheets("Fishing Regulations").OLEObjects("Septaccount2020").Object.Picture
userform2.Image3.Picture = _
Worksheets("Fishing Regulations").OLEObjects("septamount2020").Object.Picture

End Select
End If
Next X

End Sub
Thanks in advance