473,320 Members | 1,945 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

how can i show column height in excel chart through c# code

this is the part of code i have completed
Expand|Select|Wrap|Line Numbers
  1. Excel.Range chartRange;
  2.         Excel.ChartObjects xlCharts = (Excel.ChartObjects)xlWorkSheet.ChartObjects(Type.Missing);
  3.         Excel.ChartObject myChart = (Excel.ChartObject)xlCharts.Add(10, 80, 500, 250);
  4.  
  5.         Excel.Chart chartPage = myChart.Chart;
  6.  
  7.         chartRange = xlWorkSheet.get_Range("A1", "d9");
  8.         chartPage.SetSourceData(chartRange, misValue);
  9.         chartPage.ChartType = Excel.XlChartType.xlColumnClustered;
  10.         chartPage.Export(@"C:\Documents and Settings\Visual Studio 2005\WebSites\Compare\chart.jpg", "JPG", misValue);
  11.  
  12.  
  13.         string fileName = @"E:\npt.xls";
  14.  
  15.         xlWorkBook.SaveAs(fileName, Excel.XlFileFormat.xlWorkbookNormal, misValue, misValue, misValue, misValue, Excel.XlSaveAsAccessMode.xlExclusive, misValue, misValue, misValue, misValue, misValue);
  16.         xlWorkBook.Close(true, misValue, misValue);
  17.         xlApp.Quit();
Now i want to show the height of each column in the char

Can any one help me out in this problem?
Oct 30 '09 #1
1 2336
tlhintoq
3,525 Expert 2GB
TIP: When you are writing your question, there is a button on the tool bar that wraps the [code] tags around your copy/pasted code. It helps a bunch. Its the button with a '#' on it. More on tags. They're cool. Check'em out.
Oct 30 '09 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

14
by: pmud | last post by:
Hi, I need to use an Excel Sheet in ASP.NET application so that the users can enter (copy, paste ) large number of rows in this Excel Sheet. Also, Whatever the USER ENETRS needs to go to the...
1
by: Randall Arnold | last post by:
I'm converting a vbscript program to vb.net. Witht he exception of .net idiosyncrasies, most of it is working well with the same code. My only problem is that some properties and methods are...
0
by: David Caissie | last post by:
I am trying to automate a Vb.net chart using the excel COM object. The problem occurs when trying to run the code in different systems. It is working fine under one of my computers but once i move...
6
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...
0
by: madhatter84gn | last post by:
I am trying to automate an excel spreadsheet and then create a chart. Dim chartRange As Excel.Range If rollup Then chartRange = sheet.Range("O2:Q14", Type.Missing) ...
10
by: Hendri Adriaens | last post by:
Hi, I'm trying to automate the creation of an excel file via COM. I copied my code below. I read many articles about how to release the COM objects that I create. The code below runs just fine...
0
by: jwmaiden | last post by:
Have an application that opens up a webbrowser control to display data in an Excel spreadsheet (using VB.NET in VS 2005). No problem with opening the spreadsheet or displaying the data, but I'm...
1
by: Ally | last post by:
Hi all, I’m looking to plot charts in Excel from python. After some Googling I’ve found the following code: def plot(x, y, xAxisLog=False, yAxisLog=False): # acquire application object, which...
2
by: LucasLondon | last post by:
Hi, I'm trying to use VBA to extract underlying data from charts in powerpoint to excel, i.e from the underlying powerpoint datasheet that feeds the chart. I've found the macro below on the...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.