I am looking to chart some suspiciously simple data.
Project StartDate EndDate StartPoint EndPoint
No 1 7/4/2007 7/8/2007 5 12
No 2 9/12/2007 9/14/2007 9 14
etc..
I would like to use the start dates and end dates as Y axis points and start and end points as X axis points and label each resulting rectangle with the Project Number. The resulting chart would overlap rectangles from 9 to 12 on the x axis. I have seen the microsoft post on removing the summary but none of the charting objects seem to allow a range to represent each record on each of the two typical axis. Further: I have yet to find an object that will allow this definition at all.
Thank You for any links or tips.
11 4745
Hi
When I wanted a 'simple' chart I ended up drawing rectangles, setting Height in cms to pixels by multiplying by 567.
I only wanted to show 12 values, so I had Box0 thro Box11 'pre-drawn' and just changed their height in a loop. It would be possible to change their 'Left' and 'width' with code.
It was a bit tedious working out the scaling and a few other things but it gave me exactly what I wanted.
If you are interested in this apprtoach I can give more details but I admit that towards the end I felt I had re-invented the wheel!
S7
I have no other leads at this point so if you have a moment, I could use the details you spoke of.
Thanks
Hi
When I wanted a 'simple' chart I ended up drawing rectangles, setting Height in cms to pixels by multiplying by 567.
I only wanted to show 12 values, so I had Box0 thro Box11 'pre-drawn' and just changed their height in a loop. It would be possible to change their 'Left' and 'width' with code.
It was a bit tedious working out the scaling and a few other things but it gave me exactly what I wanted.
If you are interested in this apprtoach I can give more details but I admit that towards the end I felt I had re-invented the wheel!
S7
I have no other leads at this point so if you have a moment, I could use the details you spoke of.
Thanks
Before we start off down a wrong road, how many 'projects' are you hoping to include in the chart? Becaues of the repetative nature of the code, a nice number would be about 10, although code can probably be improved with loops if you put the time in. But too many overlaid rectangles could be confusing as well.
My chart was for a screen display although I imagine the code could be copied into a Report.
Can you supply a bit more data? or shall I try something with what you have posted . One problem is to determine the 'scale' so at some point you must determine the 'range' of the data values and two sets may not be a fair test.
I'm try to beat the Tax Deadline right now but I'll see if I can find time tomorrow.
S7
Short answer: 10 sounds good.
Since the data is coming from a user input on a filter page I was going to limit the range based on their selections. Having said that, the number of rectangles will flux but not beyond what is legible. Once I begin layout I will be able to better determine those limits.
Before we start off down a wrong road, how many 'projects' are you hoping to include in the chart? Becaues of the repetative nature of the code, a nice number would be about 10, although code can probably be improved with loops if you put the time in. But too many overlaid rectangles could be confusing as well.
My chart was for a screen display although I imagine the code could be copied into a Report.
Can you supply a bit more data? or shall I try something with what you have posted . One problem is to determine the 'scale' so at some point you must determine the 'range' of the data values and two sets may not be a fair test.
I'm try to beat the Tax Deadline right now but I'll see if I can find time tomorrow.
S7
Short answer: 10 sounds good.
Since the data is coming from a user input on a filter page I was going to limit the range based on their selections. Having said that, the number of rectangles will flux but not beyond what is legible. Once I begin layout I will be able to better determine those limits.
I'm attaching db3 which should open and show a chart along the lines of what I understand you would like.
The Y-axis is set to '2007' and X-axis set to 0-25 Startpoints, whatever they are. There is no error handling or data verification
Some of your projects only have 2 days between start and finish date so they appear as very slim boxes at this scaling but the purpose of this is a testbed for ideas. You can add additional data rows manually through the subform on the chart. The exact locations of the 'boxes' need adjusting by a line width or so but this is not a final solution.
By making the 'boxes' on the chart TextBoxes they can receive focus so you could click on them to initiate other actions. If the box is too slim to read the text inside the box then you can use the Shift+F2 Zoom function. There is another form purely to manually add "Project Titles"
The chart is based on a local table from which you would have to delete data prior to re-populating with your real data. You would then have to run a loop to number the rows 1 thro 10, unless you handled this in append query.
Please let me know if this has been of any use.
S7
Here's a sample of how I referenced a Chart with code. I have a form with 2 charts on it (Graph1 and Graph2) -
Private Sub Form_Current()
-
-
With Me.Graph1.Axes(xlValue)
-
Select Case Me.cboGrp
-
Case "BCI"
-
.MaximumScale = 2500
-
.MinimumScale = -1000
-
.MajorUnit = 500
-
Case "BCL"
-
.MaximumScale = 300
-
.MinimumScale = -300
-
.MajorUnit = 100
-
End Select
-
End With
-
-
With Me.Graph2.Axes(xlValue)
-
Select Case Me.cboGrp
-
Case "BCI"
-
.MaximumScale = 2500
-
.MinimumScale = -1000
-
.MajorUnit = 500
-
Case "BCL"
-
.MaximumScale = 300
-
.MinimumScale = -300
-
.MajorUnit = 100
-
End Select
-
End With
-
-
End Sub
-
My database db3 did not seem to attach properly so I am posting it again
Reinvention of the rectangle. Thank you for the post! I'll be looking at this a little later today. If I alter/use your solution, I will repost.
My database db3 did not seem to attach properly so I am posting it again
Here's a sample of how I referenced a Chart with code. I have a form with 2 charts on it (Graph1 and Graph2)
Hi Jax
It's interesting that you can reference a Graph like that. I usually just leave the scaling to the graph object to do automatically, although sometimes wish I had more control.
Mr Sconard's problem seemed to be that he could not find a suitable type of graph within MSGraph, hence the "Revenge of the Rectangles!"
I only started doing this because I am developing a CRM interface for one of my clients and wanted to include a minature display of the last 12 mths Sales history in a 1.5" x 2.0" window, and could not be bothered to struggle with MSGraph. It may not have been the right decision . . .
S7
Hi Jax
It's interesting that you can reference a Graph like that. I usually just leave the scaling to the graph object to do automatically, although sometimes wish I had more control.
Mr Sconard's problem seemed to be that he could not find a suitable type of graph within MSGraph, hence the "Revenge of the Rectangles!"
I only started doing this because I am developing a CRM interface for one of my clients and wanted to include a minature display of the last 12 mths Sales history in a 1.5" x 2.0" window, and could not be bothered to struggle with MSGraph. It may not have been the right decision . . .
S7
That size is slightly larger than "thumbnail" and would not of much value other than "somerthing pretty" on the form or report.
You can reference and dynamically control the graph object and its pieces. One group within the company done far less business than the other so I had to dynamically set the scale so the values would properly register on the chart.
I learned how to do that piece 6 yrs ago - just thought it would give ya some ideas.
Hope it helps.
That size is slightly larger than "thumbnail" and would not of much value other than "somerthing pretty" on the form or report.
It's a bit more than eye-candy Jax! The alternative would be a single number to show last years turn-over (they have that too). "A picture says a thousand words"
This interface is for Salemen negotiating prices on the telephone. There is a stack more info on the screen. The 'chart' shows a profile of when previous sales occured but more importantly, "Have they been paid ?" We interface with Sage and spread the customer's Current Balance over their Sales profile, so unpaid sales show-up red. A company can be below its Credit Limit but be owing you money for months.
Another advantage of drawing the chart 'manually' (rather than using MSGraph) is that the columns in the display are TextBoxes, so can recieve focus, so can be 'clicked' to open up the actual Sales Orders for that month, or whatever.
Anyway, this not withstanding, I do use MSGraph in reports and it's useful to know that it can be controlled programmatically. Thanks
S7
Sign in to post your reply or Sign up for a free account.
Similar topics
by: NickJ |
last post by:
Dear all,
I've encountered an unusual problem having just recently upgraded an Access
97 database to Access 2000 format and was hoping somebody could point me in
the direction of a solution.
...
|
by: StBond |
last post by:
Hi everyone,
I am new to Access and Visual Basic so things my be getting across a
bit cloudy. I only started using VB for one week.
I am having a little problem with the database that I am...
|
by: spm_no |
last post by:
Hi,
I am using Access 2002 and am creating a scatter-chart on a form in
which the X-axis is a date. I can format and display the x-axis
properly as a date. However, when I close and reopen...
|
by: digitalego |
last post by:
Sorry if the title is a little confusing... Here is the problem.
I am working with a "default.aspx" page that uses a user control I
made:
------------------------------
| default.aspx ...
|
by: Thelma Lubkin |
last post by:
I am trying to modify an Access form that allows a user to specify
the information s/he needs from a census-type database.
The form's code builds a SQL statement from the user's request, and...
|
by: Wayne |
last post by:
How does Access determine how many data points it will use in a chart
and is there any way of forcing it to use more data points? My Access
chart is only showing 7 data points of the 100+ that are...
|
by: hayuti |
last post by:
Hi there
This Question was posted on a wrong site.
Just as introduction I am working in Access VBA where I coded a routine to retrive data from Access Database, exporting it on to Excel file...
|
by: AlexNunley |
last post by:
I am trying to dump data from an access query into excel so I can pretify it. I found sample code from an old access 97 book (The version of access in use)and tinkered it into working.
Well sort...
|
by: Wedgewood |
last post by:
Group,
I am trying to build a gantt chart in a MS Access for but I can't seem to get it to pick up the second data series.
In excel, you create a stacked bar chart using fields "Key Date" and...
|
by: TGG61 |
last post by:
I have an Access 2000 query that asks the user for the start date & end date for a report or chart. In the Access report, I can display the start & end dates entered in the query in the header of the...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
| |