+ Reply to Thread
Results 1 to 6 of 6

Dynamic Chart on both X and Y axis with VBA.

  1. #1
    Registered User
    Join Date
    08-17-2017
    Location
    Sofiya
    MS-Off Ver
    2016
    Posts
    44

    Dynamic Chart on both X and Y axis with VBA.

    Hello,

    Can anyone make a VBA code so the chart for this table can be dynamic. My idea is to have 2 cells where i can put a value that will determine how many columns or rows from the table the chart will show. I was given a sample of how the code should work but i dont have any VBA experience and cant make it work for this table.

    Please Login or Register  to view this content.
    I know the position of the table is weird but because i have other things in my main file i had to put it there. Here i have put just the size of the table.
    Please don't give me other solutions like pivot charts. Thanks you in advance!
    Attached Files Attached Files
    Last edited by Pinkoto; 08-26-2017 at 04:18 PM.

  2. #2
    Registered User
    Join Date
    08-17-2017
    Location
    Sofiya
    MS-Off Ver
    2016
    Posts
    44

    Re: Dynamic Chart on both X and Y axis with VBA.

    This is how the little table was made to work (not by me). But i can not implement it in the big table I uploaded.
    Attached Files Attached Files

  3. #3
    Registered User
    Join Date
    08-17-2017
    Location
    Sofiya
    MS-Off Ver
    2016
    Posts
    44

    Re: Dynamic Chart on both X and Y axis with VBA.

    anyone? :P

  4. #4
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,803

    Re: Dynamic Chart on both X and Y axis with VBA.

    This forum can be strict about rules, like putting code in code tags. That could be part of the difficulty in getting a response.

    As discussed earlier this week (https://www.excelforum.com/excel-cha...nd-y-axis.html ), a pivot table could be a good solution. IMO, if you must learn a new "programming language" along the way, it looks to me like it would be easier and maybe more profitable in the long run to learn the "language" of pivot tables for this sort of thing.

    If you really want to pursue learning VBA for this, I would ask what difficulty you had implementing CK76's code in your new example? What parts of his code (recognizing that you are new to VBA) did you not understand? What parts do you need help adapting to the new situation?

    Along the same lines, what about CK76's example pivot table? What parts of that do you understand/not understand? What parts of using a pivot table for this do you have trouble adapting to your real database?
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  5. #5
    Registered User
    Join Date
    08-17-2017
    Location
    Sofiya
    MS-Off Ver
    2016
    Posts
    44

    Re: Dynamic Chart on both X and Y axis with VBA.

    It's not about learning or not learning it. It will work perfectly if its done like the small table and chart is. Pivot chart just wont work for what I'm trying to make. I guess the VBA is too hard to be made for such a big table. If i could do it myself I would have .

    My real data base is too big for a pivot chart. I have 1000 rows on information and 21 columns of different information. With the dropdown menu i build this table that i want the chart to be based of. I can choose what countries what kind of information and of which period to be chosen. For what i see to make the pivot chart work i will have to make a lot of rows of information and again i wont have the same mobility of choice. Also the user interface is a lot a lot better with the dropdown menu. So if anyone can help me with the VBA i will be grateful because it will make the datebase look perfect

  6. #6
    Registered User
    Join Date
    08-17-2017
    Location
    Sofiya
    MS-Off Ver
    2016
    Posts
    44

    Re: Dynamic Chart on both X and Y axis with VBA.

    anyone?

+ 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. Dynamic Chart on both X and Y axis
    By Pinkoto in forum Excel Charting & Pivots
    Replies: 18
    Last Post: 08-26-2017, 04:09 PM
  2. Dynamic Axis in chart
    By musicbox1970 in forum Excel General
    Replies: 3
    Last Post: 03-03-2017, 07:02 AM
  3. [SOLVED] Dynamic x-axis chart
    By NeoFlex in forum Excel Charting & Pivots
    Replies: 8
    Last Post: 04-02-2013, 09:50 AM
  4. Legend Only Shows Used Axis on Dynamic Chart (X, Y and Y2 axis)
    By TEBrown in forum Excel Charting & Pivots
    Replies: 6
    Last Post: 06-21-2012, 10:15 AM
  5. Dynamic X Axis values of Chart
    By ronanm in forum Excel General
    Replies: 1
    Last Post: 12-09-2010, 12:35 PM
  6. Dynamic X Axis in line chart
    By craigproudfoot in forum Excel Charting & Pivots
    Replies: 8
    Last Post: 11-02-2009, 12:43 PM
  7. chart with dynamic x axis
    By name in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 05-04-2006, 10:45 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