User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the C# section within the Software Development category of DaniWeb, a massive community of 402,547 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,330 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our C# advertiser: Programming Forums
Views: 8127 | Replies: 3
Reply
Join Date: Aug 2004
Posts: 6
Reputation: payam is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
payam payam is offline Offline
Newbie Poster

Excel Help

  #1  
Aug 11th, 2004
i have an excel spreadsheet and i need to select a couple of ranges of data from a table and then to create a graph with these ranges. In excel you can use the crtl key to select discontinuous ranges and i c#
you can say

Excel.get_Range range = thisSheet.get_range("A2":"A6","c2":"c6", Type.Missing)

(Excel.get_Range range = thisSheet.get_range("A2:A6","C2:C6"); creates a range from A2 to C6 which isn't what i want).

but once i put this into the graph it all goes wrong.


Any help would be welcome

if anyone is reading this who has the same problem i do have a "hacked" solution, create a links (= celladdress) to all the required cells in a hidden continuous range and simply use this range in the chart.
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Aug 2004
Location: Baton Rouge, LA
Posts: 2
Reputation: shabosco is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
shabosco shabosco is offline Offline
Newbie Poster

Re: Excel Help

  #2  
Aug 18th, 2004
can you tell me if you are generating a report in crystal or pdf file from excel?
Reply With Quote  
Join Date: Aug 2004
Posts: 6
Reputation: payam is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
payam payam is offline Offline
Newbie Poster

Re: Excel Help

  #3  
Aug 23rd, 2004
hi shabosco
i am reading data from a XML file, and then display the information in Excel. i always have to create a table and in some cases a chart as well. My aim is to link the chart to the table so any changes in the table will be shown in the chart.
Reply With Quote  
Join Date: Aug 2004
Posts: 6
Reputation: payam is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
payam payam is offline Offline
Newbie Poster

Re: Excel Help

  #4  
Aug 24th, 2004
His is a sample of my code,

range = thisSheet.get_Range("A9:A12"+ otherRange.get_Address(true,true, Excel.XlReferenceStyle.xlA1,true,Missing.Value),Type.Missing);
range.Value2 = 123; //test the created range
newSeries.Values = range;

the values in the cells change but the chart doesn't accept the range. I am using excel 2000 is this the problem?
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

DaniWeb C# Marketplace
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes

Similar Threads
Other Threads in the C# Forum

All times are GMT -4. The time now is 8:43 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC