Click here to Skip to main content
15,897,273 members
Home / Discussions / C#
   

C#

 
GeneralRe: Exporting Cystal Report to Excel Pin
jimish19-Apr-09 0:13
jimish19-Apr-09 0:13 
GeneralRe: Exporting Cystal Report to Excel Pin
prajeesh12-Apr-09 20:28
prajeesh12-Apr-09 20:28 
AnswerRe: Exporting Cystal Report to Excel Pin
jimish112-Apr-09 23:21
jimish112-Apr-09 23:21 
GeneralRe: Exporting Cystal Report to Excel Pin
prajeesh13-Apr-09 0:52
prajeesh13-Apr-09 0:52 
AnswerRe: Exporting Cystal Report to Excel Pin
jimish113-Apr-09 19:53
jimish113-Apr-09 19:53 
GeneralRe: Exporting Cystal Report to Excel [modified] Pin
prajeesh14-Apr-09 19:23
prajeesh14-Apr-09 19:23 
GeneralRe: Exporting Cystal Report to Excel Pin
jimish114-Apr-09 21:48
jimish114-Apr-09 21:48 
QuestionHow save image from memory stream to excel file Pin
Isengrin_Czech7-Apr-09 22:17
Isengrin_Czech7-Apr-09 22:17 
Hallo

I need help with my code ...
I read image from my picturebox to memorystream and next i want save this
image from memorystream to my xls file.

I dont now how,... i have forever same problem,xls file then show only
System.Drawing.Bitmap but image isnt show.

Here is my code..

Excel.Application oXL;
Excel._Workbook oWB;
Excel._Worksheet oSheet;


try
{

    oXL = new Excel.Application();


    oWB = oXL.Workbooks.Open("C:\\tmp\\plan_udrzby.xlt", 1, false, 5,
     "", "", true, Excel.XlPlatform.xlWindows,
     "\t", false, false, 0, true, 1, 0);

    oSheet = (Excel._Worksheet)oWB.ActiveSheet;
    DataRowView vypis = (DataRowView)machine_OverviewBindingSource.Current;


    MemoryStream ms = new MemoryStream();

    myPictureBox.Image.Save(ms, ImageFormat.Jpeg);
    ms.Seek(0, SeekOrigin.Begin);

    Image img = Image.FromStream(ms);

    System.Windows.Forms.Clipboard.SetDataObject(img);


    //Car
    oSheet.Cells[3, 2] = vypis["Car"];
    //Foto
    oSheet.Cells[6, 2] = ; //Here i dont now 
  }
catch (Exception theException)
{
    String errorMessage;
    errorMessage = "Chyba: ";
    errorMessage = String.Concat(errorMessage, theException.Message);
    errorMessage = String.Concat(errorMessage, " Řádek: ");
    errorMessage = String.Concat(errorMessage, theException.Source);

    MessageBox.Show(errorMessage, "Chyba");
}


Can someone help my please
QuestionEstablish a P2P Connection to another Client Pin
softwarejaeger7-Apr-09 22:08
softwarejaeger7-Apr-09 22:08 
AnswerRe: Establish a P2P Connection to another Client Pin
Mirko19807-Apr-09 22:57
Mirko19807-Apr-09 22:57 
GeneralRe: Establish a P2P Connection to another Client [modified] Pin
softwarejaeger8-Apr-09 1:57
softwarejaeger8-Apr-09 1:57 
GeneralRe: Establish a P2P Connection to another Client Pin
softwarejaeger8-Apr-09 22:47
softwarejaeger8-Apr-09 22:47 
QuestionDesigning a calculator in C# AND VB.NET Pin
Member 46276717-Apr-09 21:54
Member 46276717-Apr-09 21:54 
AnswerRe: Designing a calculator in C# AND VB.NET Pin
Eddy Vluggen7-Apr-09 22:01
professionalEddy Vluggen7-Apr-09 22:01 
QuestionIntegration of MS Project with .net Pin
mahesvs7-Apr-09 21:38
mahesvs7-Apr-09 21:38 
Questionread xml file and convert it to byte Pin
novhard7-Apr-09 21:38
novhard7-Apr-09 21:38 
AnswerRe: read xml file and convert it to byte Pin
Mirko19807-Apr-09 22:49
Mirko19807-Apr-09 22:49 
GeneralRe: read xml file and convert it to byte Pin
novhard10-Apr-09 22:02
novhard10-Apr-09 22:02 
QuestionOpen Source in C# Pin
heroicepic7-Apr-09 21:27
heroicepic7-Apr-09 21:27 
Questiondiscussion board problem Pin
riteshg787-Apr-09 21:03
riteshg787-Apr-09 21:03 
AnswerRe: discussion board problem Pin
riteshg787-Apr-09 21:04
riteshg787-Apr-09 21:04 
QuestionWindows to Console.....Please help! Pin
Rajdeep.NET is BACK7-Apr-09 20:56
Rajdeep.NET is BACK7-Apr-09 20:56 
AnswerRe: Windows to Console.....Please help! Pin
Eddy Vluggen7-Apr-09 21:43
professionalEddy Vluggen7-Apr-09 21:43 
QuestionAUTOCPMPLETE COMBOBOX Pin
saeed sabeti7-Apr-09 20:52
saeed sabeti7-Apr-09 20:52 
AnswerRe: AUTOCPMPLETE COMBOBOX Pin
Dino Mulahusic7-Apr-09 21:31
professionalDino Mulahusic7-Apr-09 21:31 

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.