Click here to Skip to main content
15,885,278 members
Home / Discussions / C#
   

C#

 
AnswerRe: Voip , SIP and ZRTP Pin
Christian Graus15-Oct-09 20:59
protectorChristian Graus15-Oct-09 20:59 
QuestionWhen remoting, how can the server application reference objects created by remote applications? Pin
wrecking ball15-Oct-09 13:33
wrecking ball15-Oct-09 13:33 
AnswerRe: When remoting, how can the server application reference objects created by remote applications? Pin
dataminers15-Oct-09 13:55
dataminers15-Oct-09 13:55 
Questionquery odbc schema Pin
JollyMansArt15-Oct-09 11:36
JollyMansArt15-Oct-09 11:36 
AnswerRe: query odbc schema Pin
Not Active15-Oct-09 12:32
mentorNot Active15-Oct-09 12:32 
QuestionParsing data sent via socket when you can't cast to a typedef Pin
FoxholeWilly15-Oct-09 10:16
FoxholeWilly15-Oct-09 10:16 
AnswerRe: Parsing data sent via socket when you can't cast to a typedef Pin
Luc Pattyn15-Oct-09 10:45
sitebuilderLuc Pattyn15-Oct-09 10:45 
QuestionExcel C# question Pin
antsims15-Oct-09 9:45
antsims15-Oct-09 9:45 
I am reading this excel file and searching for the word "Yellow" Everything is fine until I reach a type double. How do I handle this. My code is below.

Excel.Application xlApp ;
Excel.Workbook xlWorkBook ;
Excel.Worksheet xlWorkSheet ;



Excel.Range range ;

string str;

int rCnt = 0;
int cCnt = 0;

xlApp = new Excel.ApplicationClass();
xlWorkBook = xlApp.Workbooks.Opentest", 0, true, 5, "", "", true, Microsoft.Office.Interop.Excel.XlPlatform.xlWindows, "\t", false, false, 0, true, 1, 0);

xlWorkSheet = (Excel.Worksheet)xlWorkBook.Worksheets.get_Item(8); // Opens the 8th tab in workbook




range = xlWorkSheet.UsedRange;

for (rCnt = 1; rCnt <= range.Rows.Count; rCnt++)
{
for (cCnt = 1; cCnt <= range.Columns.Count; cCnt++)
{

System.Convert.ToString(xlWorkBook);
str = (string)(range.Cells[rCnt, cCnt] as Excel.Range).Value2 ;


if (str == "Yellow" )

MessageBox.Show(str);
}
}

xlWorkBook.Close(true, null, null);
xlApp.Quit();

releaseObject(xlWorkSheet);
releaseObject(xlWorkBook);
releaseObject(xlApp);
}



private void releaseObject(object obj)
{
try
{
System.Runtime.InteropServices.Marshal.ReleaseComObject(obj);
obj = null;
}
catch (Exception ex)
{
obj = null;
MessageBox.Show("Unable to release the Object " + ex.ToString());
}


In other words how can I convert his whole spreadsheet to type string. I am new to this thanks.
AnswerRe: Excel C# question Pin
Luc Pattyn15-Oct-09 10:00
sitebuilderLuc Pattyn15-Oct-09 10:00 
QuestionSetting focus messes up scroll position Pin
Alan Balkany15-Oct-09 8:50
Alan Balkany15-Oct-09 8:50 
AnswerRe: Setting focus messes up scroll position Pin
Saksida Bojan15-Oct-09 9:58
Saksida Bojan15-Oct-09 9:58 
AnswerRe: Setting focus messes up scroll position Pin
diffy674-May-10 6:20
diffy674-May-10 6:20 
QuestionSend CTRL-S And CTRL-X To Open Excel Doc Pin
Kevin Marois15-Oct-09 8:03
professionalKevin Marois15-Oct-09 8:03 
AnswerRe: Send CTRL-S And CTRL-X To Open Excel Doc Pin
Luc Pattyn15-Oct-09 8:18
sitebuilderLuc Pattyn15-Oct-09 8:18 
GeneralRe: Send CTRL-S And CTRL-X To Open Excel Doc Pin
Kevin Marois15-Oct-09 8:27
professionalKevin Marois15-Oct-09 8:27 
AnswerRe: Send CTRL-S And CTRL-X To Open Excel Doc Pin
Saksida Bojan15-Oct-09 8:26
Saksida Bojan15-Oct-09 8:26 
GeneralRe: Send CTRL-S And CTRL-X To Open Excel Doc Pin
Kevin Marois15-Oct-09 8:28
professionalKevin Marois15-Oct-09 8:28 
GeneralRe: Send CTRL-S And CTRL-X To Open Excel Doc Pin
Saksida Bojan15-Oct-09 8:32
Saksida Bojan15-Oct-09 8:32 
Questioncommunication between two websites in asp.net Pin
noo.dyab15-Oct-09 7:53
noo.dyab15-Oct-09 7:53 
AnswerRe: communication between two websites in asp.net Pin
Dave Kreskowiak15-Oct-09 8:05
mveDave Kreskowiak15-Oct-09 8:05 
GeneralRe: communication between two websites in asp.net Pin
noo.dyab15-Oct-09 9:31
noo.dyab15-Oct-09 9:31 
GeneralRe: communication between two websites in asp.net Pin
Dave Kreskowiak15-Oct-09 11:58
mveDave Kreskowiak15-Oct-09 11:58 
AnswerRe: communication between two websites in asp.net Pin
Richard MacCutchan15-Oct-09 9:30
mveRichard MacCutchan15-Oct-09 9:30 
Questiona table of arraylist Pin
abbd15-Oct-09 7:51
abbd15-Oct-09 7:51 
AnswerRe: a table of arraylist Pin
OriginalGriff15-Oct-09 8:02
mveOriginalGriff15-Oct-09 8:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.