Results 1 to 1 of 1

Chart in userform

Threaded View

  1. #1
    Registered User
    Join Date
    04-24-2015
    Location
    Cardiff
    MS-Off Ver
    2007
    Posts
    7

    Question Chart in userform

    Hi,

    I got a chart in the sheet and when I select any value from dropdown list in same Sheet, it will show the chart of that value to me in.
    Now I want bring this chart to userform but only the one of the dropdown list. I want select (i.e. Car) in the box for userform image.
    so far i brought the image of the chart to userform but the problem is when i change to another in dropdown list, then my image is not the same that i wanted to show in userform. I need add code to say only select "Car" from the dropdown the list and when taking image, will be correct one; or something like this.

    i would appreciate if you help me with this. thank you . sorry i am new to vba, thanks
    Private Sub UserForm_Initialize()
    Dim a As Range
    Dim b As Range
    
    Set CurrentChart = Sheets("Ind. Charts").ChartObjects(1).Chart
     
        Fname = ThisWorkbook.Path & "\temp.gif"
        CurrentChart.Export Filename:=Fname, FilterName:="GIF"
        Image1.Picture = LoadPicture(Fname)
       
    End Sub
    Moderator's note: Please take the time to review our rules. There aren't many, and they are all important. Rule #3 requires code tags. I have added them for you this time because you are a new member. --6StringJazzer
    Last edited by mopan; 05-17-2015 at 05:58 AM.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Chart on a Userform
    By shiftyspina in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 05-31-2024, 12:15 PM
  2. combining chart userform and data transfer userform into 1 userform
    By H_Kennedy in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 01-04-2014, 07:11 AM
  3. combining chart userform and data transfer userform into 1 userform
    By H_Kennedy in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-03-2014, 12:28 PM
  4. Chart in Userform
    By BrianAll in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 07-22-2013, 01:36 PM
  5. Chart on a Userform
    By Rocky McKinley in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-12-2005, 11:05 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