LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default SplitVertical + C#

Hi,

How do I get data to display in the bottom half of the split pane?

I have 2 separate database queries now and I want the results of the first
one to appear in the top half and the results of the 2nd one to appear in the
bottom half.

Here's my split code...

oWB = (Excel._Workbook)(oXL.Workbooks.Add(System.Reflect ion.Missing.Value));
oSheet = (Excel._Worksheet)oWB.ActiveSheet;
Excel.Window xlWin = oXL.ActiveWindow;
xlWin.SplitVertical = 216f;

then queryA results...

int rowIndex = 2;

foreach (DataRow row in this.myDataSet1.Tables["myTableAdapter"].Rows)
{
string ExcelAccount = row["Account"].ToString();
string ExcelType = row["Type"].ToString();
string ExcelCurrency = row["Currency"].ToString();

oSheet.Cells[rowIndex, 1] = ExcelnAccount;
oSheet.Cells[rowIndex, 2] = ExcelType;
oSheet.Cells[rowIndex, 3] = ExcelCurrency;
rowIndex++;
}

QueryA should display in the top half only.

QueryB(similar code) should then display in the bottom half only.

Following the below example...

http://support.microsoft.com/kb/302084

Thanks.

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 10:17 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"