Click here to Skip to main content
15,886,592 members
Home / Discussions / C#
   

C#

 
AnswerRe: Need date formate like yyyy-MM-dd with time like "2008-07-08 20:24:14" in Excel Pin
0x3c024-Jun-09 9:49
0x3c024-Jun-09 9:49 
QuestionHow To Transfer Parameters Through 2 Forms Pin
treuveni24-Jun-09 6:42
treuveni24-Jun-09 6:42 
AnswerRe: How To Transfer Parameters Through 2 Forms Pin
Manas Bhardwaj24-Jun-09 6:43
professionalManas Bhardwaj24-Jun-09 6:43 
GeneralRe: How To Transfer Parameters Through 2 Forms Pin
treuveni24-Jun-09 7:36
treuveni24-Jun-09 7:36 
AnswerRe: How To Transfer Parameters Through 2 Forms Pin
Giorgi Dalakishvili24-Jun-09 7:22
mentorGiorgi Dalakishvili24-Jun-09 7:22 
QuestionThe best way to achive this ? Pin
viralthebest24-Jun-09 6:40
viralthebest24-Jun-09 6:40 
AnswerRe: The best way to achive this ? Pin
Christian Graus24-Jun-09 10:38
protectorChristian Graus24-Jun-09 10:38 
QuestionProblems with System Tray Graph ? Pin
Rsesky00024-Jun-09 6:23
Rsesky00024-Jun-09 6:23 
Hi im building a program in C# which downloads files , Ive wrote the code to generate the download graph and it works for values 30 - 100 but anyhing below 30 and the bar flips upside down .

I basically have 14 pixals to generate a bargraph of values 0 - 100 in . i know this is vague but im sure the problem is with GDI.FillRectangle(Graph, 1, 15 - Bar, 14, Bar - 1);

Can any ofr you c# gurus help me pinpoint the problem ()
private Graphics GDI;
        private Bitmap DownloadGraphic;
        private Icon icon;
        private int value = 5;

public void DownloadGraph()
        {
            int Bar = (14 * value) / 100;
            DownloadGraphic = new Bitmap(16, 16);
            GDI = Graphics.FromImage(DownloadGraphic);
            SolidBrush BackgroundBrush = new SolidBrush(Color.Transparent);
            GDI.FillRectangle(BackgroundBrush, 0, 0, 16, 16);
            Pen LeftBorder = new Pen(Color.White, 1);
            GDI.DrawLine(LeftBorder, 15, 0, 15, 15);
            GDI.DrawLine(LeftBorder, 15, 15, 0, 15);
            Pen RightBorder = new Pen(Color.Gray, 1);
            GDI.DrawLine(RightBorder, 0, 16, 0, 0);
            GDI.DrawLine(RightBorder, 0, 0, 16, 0);
            SolidBrush Graph = new SolidBrush(Color.DarkRed);
            GDI.FillRectangle(Graph, 1, 15 - Bar, 14, Bar - 1);
            Pen DownloadHilight = new Pen(Color.OrangeRed, 1);
            GDI.DrawLine(DownloadHilight, 1, Bar, 14, Bar);
            Font PercentFont = new System.Drawing.Font("Verdana", 7, FontStyle.Italic);
            Brush Percentage = new SolidBrush(Color.White);
            GDI.DrawString(value.ToString(), PercentFont, Percentage, 0, 1);
            this.NotifyIcon.Icon = Icon.FromHandle(DownloadGraphic.GetHicon());
        }
Thanks

AnswerRe: Problems with System Tray Graph ? Pin
OriginalGriff24-Jun-09 6:57
mveOriginalGriff24-Jun-09 6:57 
QuestionBetter way to achive this ? Pin
eAero24-Jun-09 6:10
eAero24-Jun-09 6:10 
AnswerRe: Better way to achive this ? Pin
PIEBALDconsult24-Jun-09 6:42
mvePIEBALDconsult24-Jun-09 6:42 
QuestionHow to execute .jar file in c# Pin
Gresziu24-Jun-09 6:04
Gresziu24-Jun-09 6:04 
AnswerRe: How to execute .jar file in c# Pin
Ravadre24-Jun-09 7:56
Ravadre24-Jun-09 7:56 
GeneralRe: How to execute .jar file in c# Pin
Gresziu24-Jun-09 23:45
Gresziu24-Jun-09 23:45 
GeneralRe: How to execute .jar file in c# Pin
Gresziu25-Jun-09 0:33
Gresziu25-Jun-09 0:33 
AnswerRe: How to execute .jar file in c# Pin
A P Prajwal30-Nov-09 0:56
A P Prajwal30-Nov-09 0:56 
QuestionData Reader Completion Rate, label text does not change Pin
Ersan Ercek24-Jun-09 5:32
Ersan Ercek24-Jun-09 5:32 
AnswerRe: Data Reader Completion Rate, label text does not change Pin
Manas Bhardwaj24-Jun-09 5:38
professionalManas Bhardwaj24-Jun-09 5:38 
GeneralRe: Data Reader Completion Rate, label text does not change Pin
Ersan Ercek24-Jun-09 5:49
Ersan Ercek24-Jun-09 5:49 
GeneralRe: Data Reader Completion Rate, label text does not change Pin
musefan24-Jun-09 6:02
musefan24-Jun-09 6:02 
GeneralRe: Data Reader Completion Rate, label text does not change Pin
Ersan Ercek24-Jun-09 21:38
Ersan Ercek24-Jun-09 21:38 
QuestionSend Email in Arabic Pin
ASysSolvers24-Jun-09 5:14
ASysSolvers24-Jun-09 5:14 
AnswerRe: Send Email in Arabic Pin
Manas Bhardwaj24-Jun-09 5:21
professionalManas Bhardwaj24-Jun-09 5:21 
GeneralRe: Send Email in Arabic Pin
Gary Stafford24-Jun-09 5:56
Gary Stafford24-Jun-09 5:56 
QuestionWhen adding a webreference to my C# Windows Application i get:Operation is not valid due to the current state of the object. Pin
DotNetCoderJunior24-Jun-09 5:03
DotNetCoderJunior24-Jun-09 5:03 

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.