- Strength to Increase Rep
- +0
- Strength to Decrease Rep
- -0
- Upvotes Received
- 12
- Posts with Upvotes
- 12
- Upvoting Members
- 11
- Downvotes Received
- 2
- Posts with Downvotes
- 1
- Downvoting Members
- 2
100 Posted Topics
Re: I dissagree that violent videogames "desensitize" people to violence, I have played violent games all through my life (and watched films etc) but when a program on TV showed some surgery last night I felt ill and couldn't watch! Yet no doubt tonight I will blast some aliens limbs off... … | |
I need to bind a property to a ToolStripMenuItem. I've searched around and found it imposible, the best workaround seems to be creating a BindableToolStripMenuItem class and implement it yourself. So I've taken some reasonabyl well established code from the internet: public partial class BindableToolStripMenuItem : ToolStripMenuItem,IBindableComponent { private BindingContext … | |
A warning: I'm very new to databases! Hopefully this will be a pretty simple question. To simplfy my problem, I have a tree of 'meters' that collect data (Let's say electricity meters). I'd normally structure this with objects in a tree, each with a list or some kind of array … | |
Re: take a look [URL="http://www.cplusplus.com/reference/clibrary/cstring/strcat/"]here[/URL] you will need to loop through the array with a for loop | |
Hi, I need to be able to automatically process emails sent to an outlook account. I would use outlook, but we can't run a user logged in 24/7 on our server so I need to manage them as a service. Is this something that I could do in C#? So … | |
Hi, I'm trying and failing to get this CSV reading library to work. I started making a question on accessing the data in CsvReader, which I could see in the debugger but couldn't work out how to access via code. However, I'm getting annother problem now which I wasn't before, … | |
Hi, I'm trying to get a bunch of files off an ftp server. I connect fine: batch script: ftp -v -s:"C:\Documents and Settings\xxxx\Desktop\download.txt" xx.xx.xx.xx and download.txt: xxxx xxxx lcd "D:\Data\FileDump" cd "backup" mget *.* It runs fine until it gets to the mget *.* and then it just outputs all … | |
Hi, I am trying to get a rounded-rectangle Label, this method has worked fine for my TextBox, and seems to work for my Label except the Content doesn't appear (ie, there is no text). When I remove the <Setter Property="Template"> section, the label goes square but the text is visible. … | |
Hi, I'm not sure if this is the right place for a WPF question... but you might be able to help me! I am using Visual Studio Express 2010 (Which I didn't know had an evaluation time, going to have to change to 2008!) and I'm developing a WPF application. … | |
Hi, I am trying to use some C# code I have written in C++ - its worked fine in the past (without inheritance) so I'm totally stumped by this problem I'm getting. I have made a really simple version, which demonstrates the problem, specifically when it goes into any COM … | |
I have two projects in Microsoft Visual Studio 2008, but I can't access the objects/namespace from one with the other. here is an example from my GCController project: [CODE]using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Runtime.InteropServices; namespace GCController { [Guid("9949f4f1-92e6-4709-85a8-12c816b6ceb4")] public interface IGCController { // ... // } … | |
At the moment I am parsing strings to enumerations using this code: [CODE] if (Enum.IsDefined(typeof(Color), input)) { colour = (Color)Enum.Parse(typeof(Color), input); } [/CODE] which has worked fine so-far, but I would like to parse lower case/mixed case, for example someone might input Red, but the enumeration is red or RED … | |
Re: I got confused at this, the question is the tricky part, I though it was asking which was true for A = false, B = false and C = false, in which case they are all true (I didn't notice this or I would have got more suspicious). However, its … | |
Re: As the above poster said, most of us are sneaking onto this forum at work so we don't have time to work out what your problem is when you can just tell us. [CODE]Also, try to format your code in a consistent manner it would be silly if I wrote … | |
Re: please use code tags so we can read your code. Also, please delete your double post (if you can, or edit one so its says "admin please delete, double post" if there is no delete option! [CODE]if(in.v.length!=in2.v.length)[/CODE] this is the line in question. There are four things which could throw … | |
Re: You really should try to keep your logic and your painting as separate as possible... | |
Re: [QUOTE=xanawa;1514363]it saved but it saved as File not as an image.[/QUOTE] What do you mean? Did it save but when you double click on the file in window it comes up with "Choose the program you wish to open this file with" dialog? If that is the case make sure … | |
Hello everyone. I'm a bit new to c++. I'm trying to write a game loop (see the code below) and I'm getting some weird behavior with the GetSystemTime(). I ran through it with the debugger and I get things like this: startTime = 452 endTime = 210 And nothing seems … | |
Re: Java is pretty good for desktop applications, I would consider C# or Java for anything that has a substantial user interface. Unless you are doing some serious processing, I wouldn't consider the performance to be an issue, so c++ would (in my opinion) just be making extra work for yourself. | |
Hi, I'm wondering what which IDEs people use to develop C++ with. I am learning c++ from a background in Java, I am used to eclipse and recently installed Visual Studio. Now, eclipse comes with loads of auto-complete stuff. For example If i write a function and it doesn't exist … | |
I have made a small example to illustrate my problem. I have overwritten the createToolTip method for a custom JComponent (eventually it will depend on where abouts the mouse is in the component as to what text to bring up) At first I thought it wasn't being called, but i … | |
Re: "The system cannot find the file specified" - this means the system cannot fint the file specified Place this line to help you spot problems: [CODE]//this checks the user has given you a filename if (args.length > 0) { filename = args[0]; System.out.println("Filename: " + filename): //you should surround this … | |
Re: [QUOTE]In which package is Grid(in-built) class is there? I guess util. But Grid creation using create() shows error. We have to use 2d array to create a grid. If anybody knows anyother simple way to design a thread tell me.[/QUOTE] There is no "Grid" class in the java api as … | |
I have a bit of a puzzle, My default buttons (for when they are only an image) have this "highlight" listener, when the mouse enters/exits it draws a border to give the user some feedback. Its worked fine untill now, where I have a "close" button that, when clicked, removes … | |
I am writing a video program, everything works fine except I am often (ie most times, but not [I]every [/I]time) getting the following error: Unhandled exception at 0x6076fde0 (msvcr90d.dll) in javaw.exe: 0xC0000005: Access violation reading location 0x0a450020. I have tracked it down to this function: [CODE]//fill the buffer from data … | |
Re: I'm confused about what you are actually asking, but why are you opening the file, looping through all the elements to get the line number: [CODE]while (ln.readLine() != null) { count++; }[/CODE] closing the file, then opening it and then looping thorugh every line again (missing the first one): [CODE]for … | |
Re: [QUOTE=Eric Cute;1448203]eman 22 was right, first determine where your weak points are. is it in grasping the concepts?? is it in programming?? In any case, my suggestion is read, read, read.[/QUOTE] My suggestion is to write, write, write! I learned loads form writing stupid little games, I started without much … | |
Re: I have never played a tower defence game, but why dont you just make it like you would make any game? You would learn alot more from following a tutorial that covers the basics of a game loop and drawing etc etc but actually making a different game, makes you … | |
Re: You may get more help if you mark your old questions as answered, or at least give some feedback as to whether the time people have put into helping you resulted in a solution. A "thank you" wouldn't go amiss either. [url]http://www.daniweb.com/forums/thread340200.html[/url] [url]http://www.daniweb.com/forums/thread336148.html[/url] Edit - We dont have a load … | |
Re: Forgive me for not going through all 454 lines of code. I assume you are not using any standard "button" object, such as JButton. I also notice that you dont have anything (relevent) in the mouseClicked or mousePressed methods, unless of course "p = 0" is you turning off your … | |
Re: What do you mean by "Random figures please explian"? If you dont know how a for loop works there are plenty of examples, have a read through some ([url]http://download.oracle.com/javase/tutorial/java/nutsandbolts/for.html[/url]) as for the drawline function, the simplest and best explination is in the java documentation: drawLine(int x1, int y1, int x2, … | |
Re: When you put System.out.println() do you actually to read input? notice the "out" and the "println", this is for printing a line to the console. To read a line from the console, type "java reading console" into google, the first link explains it pretty well. [url]http://www.java-tips.org/java-se-tips/java.util/how-to-read-input-from-console.html[/url] | |
I am trying to refer to the class a nested class is 'in'... The 'this' keyword refers to the nested class, so I need something like super.this (except not at all like that) :/ I think the code below describes what I am trying to do: [CODE]public class Nest { … | |
Re: You really need to look at layout managers rather than setting the sizes of the objects directly! I made a small test using setBounds but couldnt get it to reproduce what you are seeing: [CODE]public class Test { public static void main(String[] args) { JFrame f = new JFrame(); Container … | |
Re: by "frequency of the colour" do you mean count how many pixels are, for example red (255,0,0) or some other specified color (230,126,72 for example)? What do you mean when you say "to be placed in an array"? (an array of every colour and their frequencies would be 256^3 (i … | |
Re: if(beginHour + durationMinute >= 60) shouldnt beginHour be beginMinute? I assume the aim of this check is to see if adding on durationMinute to the time would take it past 60 min, ie need to increase the hour [B]edit: [/B]looking at the date I realise that you have probably worked … | |
Re: salesPersonName.matches("^[^a-z,^A-Z,\\s]$") failes for everything (eg "John"), I dont know much about regex though. | |
Re: You are a bit late at doing this assignment arn't you! The other person asked about this homework 26 days ago, at least he attempted to write it first. | |
Re: what you are doing is printing out a single line, depending on what the last mark the user input is, you will have to store all the marks the user has input (maybe into an array?) and then loop through to find out how many are <29 etc etc printing … | |
Re: [QUOTE]multiple files in this single program?[/QUOTE] [CODE]import java.awt.*;[/CODE] an example of using annother "file" (what you seem to be calling classes) in a different program [QUOTE]I don't understand how to write each file to use the others[/QUOTE] [CODE]public Class1 extends Class2[/CODE] That is the syntax, if you are indeed studying … | |
| |
Re: I suggest you start by writing a hello world console application rather than modifying some code you don't understand | |
Re: could you please use [ code ] tags? Also, where is the problem, which if statement? | |
Re: this post died a year ago, and 5 years before that. I started reading posts from Jul 28th, 2005. After putting some thought into things I am now annoyed that it was all pointless because I forgot to look at the dates. Thanks | |
Re: For some reason I thought your question was [QUOTE]I have to create a method signature but don't know how [I]to Type[/I]?[/QUOTE] and was a joke... how silly of me Method signatures, I assume your assignment is to "plan" what methods should be in a ResizableArrayList. Open notepad or get a … | |
Re: It would really help if you could tell us which line the error occurs on, null pointers are quite simple to debug though, it means you are trying to use a variable that is "null", what fields are before you set it a value. If you forget to call init(), … | |
Re: I'm confused as to what you need multi threading for, swing has a filechooser class, (JFileChooser) that supports choosing more than one file, and returns those files in an array. You don't need to make a new thread, just open the file chooser and let it do it stuff | |
Re: I suggest you take a book (or look at some tutorials online) and write your Login class yourself, rather than copying and pasting it off the internet, judging from where you pasted the code you clearly have no idea how your program works. [url]http://download.oracle.com/javase/tutorial/getStarted/[/url] can you write a hello world … | |
Ok, im gonna go ahead and just paste most of the stack trace in, (its massive) : java.io.NotSerializableException: com.sun.java.swing.plaf.windows.XPStyle at java.io.ObjectOutputStream.writeObject0(Unknown Source) at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source) at java.io.ObjectOutputStream.writeSerialData(Unknown Source) at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source) at java.io.ObjectOutputStream.writeObject0(Unknown Source) at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source) at java.io.ObjectOutputStream.defaultWriteObject(Unknown Source) at javax.swing.JComponent.writeObject(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at … | |
Re: What on earth are you asking? Your question makes no sence whatsoever. Have a think about what you are trying to ask and write it down. Then read it, check its understandable and repost it. |
The End.