4,439 Posted Topics
Re: Because the OpenFileDialog class is sealed, you cannot inherit it and so you cannot override its methods. | |
Re: Also leave out line 10, you are doing that already in the for loop. By the way:Your integer type will overflow. Write your for statement like this: for (even = 2; even <= 30; even = even + 2) { prod = prod * even; } | |
Re: Google for databinding. Here is an [example](http://www.codeproject.com/Articles/3665/Data-binding-concepts-in-NET-windows-forms) | |
Re: Whenever I need variables like x1,x2,x3,x4...... I think of a collection like [List](http://msdn.microsoft.com/en-us/library/6sh2ey19.aspx) or [Array](http://msdn.microsoft.com/en-us/library/system.array.aspx) | |
Re: initialHold seems not to come from a Numeric updown and hence is not of type decimal if I'm correct. This works when I tried it : decimal totalRunTime = (10m - 5m) / 7m + 1m + (45m - 42m) / 1.5m + 1m; | |
Yes, I know Fibonacci(=sun of a good man) again. Most famous for his series, but who among you all, know that he was the man who introduced to the Western world, the Arabic numeral system(including zero) in 1202 A.D.? The Italian merchands of those days adored it. It was far … | |
The luxuries we now have in the amount of pixels on a screen to draw some amazing graphs with, were lacking in the early days of computing. Most of the time you had to resort to rude printed output. It wasn’t that bad always. Sometimes it was and still is … | |
| |
I wanted to draw a 5 pointed star in C# and here is how I finally did it. I leave it as an exercise (some hints are given in the code) to work out how I did this. It was fun to do (but a bit hard, my trig is … | |
Re: Never coded in COBOL. Saw some code long time ago. Looks very tedious and "administrative". | |
| |
Re: Perhaps it helps a bit if you have a look at [this](http://www.daniweb.com/software-development/csharp/code/227743/animation-rotate-a-string-with-a-timer) | |
Re: Perhaps [this](http://stackoverflow.com/questions/11993211/how-to-fill-datatable-with-sql-table) and [this](http://www.dotnetperls.com/datatable) can get you on the way. | |
Re: What language you code in? | |
Re: Line 9 is correct. Line 16 don't use Lenght-1, use Lenght. rand.Next will automatically have a range from 0 to Lenght-1 | |
Re: The reverse happened to me! Thought it was a free day(we had a complicated holyday scheme). Thought let's take a relaxing bath... Then the telefone rang! The boss!!! Two hours later than normal I was back at work... | |
| |
Re: If you can calculate an average on a piece of paper, you are half on your way. | |
![]() | Re: I'm also a Python-starter. Question to the OP: What is the purpose of following function? def calculate_gpa(numbercourses): coursenumber = 1 It returns nothing; **None** I guess. It does nothing with the parameter **numbercourses**. It sets a variable(global?) **coursenumber** to 1. |
Re: Also read [this article](http://www.cowirrie.com/blog/2012/07/what-is-the-difference-between-a-checkbox-and-a-radio-button/) | |
Re: Hi, voicephone, welcome at DaniWeb. How about [this](http://www.daniweb.com/software-development/csharp/threads/437362/getting-started-with-c-the-list)? | |
Re: I would change Dim fnum As Variant Dim FileName As Variant into Dim fnum As Integer Dim FileName As String | |
| |
Re: Perhaps the [TimeSpan structure](http://msdn.microsoft.com/en-us/library/system.timespan.aspx) might help | |
Re: It is your job to do it yourself. Why else did you start college? Why in the world would I want to be a train driver and follow lessons for it and come to the conclusion that I don't like to drive a train? | |
Re: The [DateTime structure](http://msdn.microsoft.com/en-us/library/system.datetime.aspx) should provide you with all the methods you need to accomplish this task. | |
Re: Are you coming from a Pascal like language? Line 18 of your code should read return (TargetValue/B-1)/IR; Because your function returns an integer, your calculation should be rounded. | |
Re: Well, why not play around with [this](http://www.daniweb.com/software-development/csharp/code/451281/simple-line-graph-charting) and improve your C# charting skills. | |
Re: Hi Bakondaonline, welcome at DaniWeb! Could you please provide some more info about your problem? | |
Re: Use the string Split method. [Here](http://www.dotnetperls.com/split-vbnet) is some explanation to help you on the way. Success! | |
Re: You have to declare a counter variable at world level as you call it and augment it every time you click the play button until 3 times an reset it if needed. | |
Re: Any reason why you are posting VB code in a C# thread? | |
Re: Hint: use a [modulo operator](http://en.wikipedia.org/wiki/Modulo_operation) | |
Re: Please post your vb code and your question in the VB.NET section. | |
Re: Did you try the string Trim method? Sometimes some whitespace is not removed. | |
Re: There is also Mono for Mac, but I like to see a VS and .NET for Mac, before we can speek a bit more about cross platform. | |
Re: Did you look up what error code 255 means? | |
Re: The output of your function will always be zero. Try to figure that out! Write a single line in your function: `return x*x + y*y;` | |
Re: Did you know that an automatically implemented property syntax exists? private ArrowColor _CustomForeColor; [Browsable(true), Category("Appearance")] public ArrowColor CustomForeColor{ get { return _CustomForeColor; } set { _CustomForeColor = value; } } // Can be written as(just 2 lines) [Browsable(true), Category("Appearance")] public ArrowColor CustomForeColor{ get; set; } See also example 6 on … | |
Re: What is wrong with storing those values into [resources](http://msdn.microsoft.com/en-us/library/7k989cfy(v=vs.90).aspx) or in [settings](http://msdn.microsoft.com/en-us/library/aa730869(v=vs.80).aspx)? That way these values always are part of the app itself. | |
Re: Looks very interesting, but in 12 weeks? Also have a look [here](http://www.daniweb.com/community-center/geeks-lounge/threads/463801/teach-yourself-programming-in-only-10-years#post2019286) | |
Re: Where is it, you are getting stuck with it in your code? | |
Re: Hi bellalucia welcome at DaniWeb! Could you please be a little more specific with your question? What is "Medging"? And please post your C# question in the C# section. | |
Re: Only degrees, or minutes and seconds also? | |
Re: Read the first two threads of the C# disscussion community here at Daniweb. | |
Re: A FileInfo class has an Extention property, which might come in handy. [Click Here](http://msdn.microsoft.com/en-us/library/system.io.fileinfo.aspx) | |
Re: In my code snippets I have 3 parts, who together form a small expression console calculator. But it is in C# rather then Java. But as C# took many things from Java, translation is perhaps not that big of a problem.[Click Here](http://www.daniweb.com/software-development/csharp/code/217185/console-calculator-part-1-the-scanner) for the scanner(lexer). Hope it helps a bit. | |
Re: Try this: private void pictureBox1_Click(object sender, EventArgs e) { Point PictPoint = new Point(); PictPoint = PointToClient(Cursor.Position); label1.Text = PictPoint.X.ToString(); label2.Text = PictPoint.Y.ToString(); } If the upper left corner of your picture has to be 0,0, substract the picture location also. |
The End.