43,549 Solved Topics
Remove Filter ![]() | |
I have a linked list of structs, with each struct having a char* and an int. When I try to print the list I get a seg fault. If I just print the int however it works. What am I doing wrong so the char* won't print? printf("%s %d\n", p->name, … Software Development c linked-list | |
Here's my code: [code]import java.awt.FlowLayout; import java.awt.event.ActionListener; import java.awt.event.ActionEvent; import javax.swing.JFrame; import javax.swing.JButton; import javax.swing.Icon; import javax.swing.ImageIcon; import javax.swing.JOptionPane; public class DisplayGUI extends JFrame { public static void main(String args[]) throws Exception { ButtonFrame buttonFrame = new ButtonFrame(); buttonFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); buttonFrame.setSize(275, 75); buttonFrame.setVisible(true); } private JButton Fibonacci; private JButton Factorial; public … Software Development java java-swing | |
I have created a Jframe and included 10labels and 10 textfields in it when i try to run the program, it does not show all the labels and textfields.. sometimes all are visible if i run again then few disappear.. at times they r visible for a few secs and … Software Development java | |
I have two checkboxes on my Form1, one is called "CheckOE" and the other "CheckCDO" I would like to have an option of sending email message using either Outlook or CDO. Both email codes work fine if placed in the button alone, but I dont' know how to skip either … | |
hey i got some c homework due Monday and I'm stuck. please help me. I'm going to mark the error lines with **** in place of a tab. build errors are at the bottom. i will be eternally grateful for any insight. [code=c] //patrick allard //program4 //prof ed ryder #include … Software Development c | |
I have edit a few items in my comboBox1 on my Form. The items in the comboBox exists of dates like this 2000/01/01 2001/01/01 So these 2 dates can be selected from the comboBox. I am doing a calculation with the selected date in the comboBox1. This works without any … Software Development c++ | |
I just started using DevC++ (ty Ancient Dragon) to learn C/C++. I am starting with the basic Hello World! The online tutorial I am following (which seems pretty good to me, but what do I know...yet) does not express how to check my work. I remember seeing a C tutorial … Software Development c++ | |
I have to do a really strange thing. I have to take a string of 2 words and then separate it and put it into two other strings eg String name = "fred blogs"; move the part of the string name which says fred to the String firstname so it … Software Development java | |
I am working to increment lists in such a way that each item in the list is incremented incrementally, it sounds confusing but its not: If the user inputs: [CODE]list = [1, 2, 3, 4] [/CODE] I want the output to be: [CODE]2, 4, 6, 8[/CODE] in essence, the first … Software Development python | |
while (firstNodeNeedsToGo(text)) { removeFirstNode(); nodeRemoved = true; } can someone rewrite this while loop into an if - then loop or any other code you have , this will help greatly toward my upcoming test Software Development java | |
does anybody knows why this function doesn´t work very well: f=lambda n: reduce(lambda x,y:x**2+y**2, map(int,str(n))) I want that this function add the square of the digits of a number an example of what i want: f(442)=4**2+4**2+2**2=36 and it's giving me f(442)=1028!!!:S However fou numbers with 2 digits the function works! Software Development python | |
boolean removedlNodes = false; what is the point setting this type boolean = false? Nodes = Nodes | NodesWithText(text); what does this " | " means here ? thanks in advance Software Development java | |
Hi ! [QUOTE] (A & 0xFF)[/QUOTE]. What does this mean? I have to optimize a program, here is the code : [QUOTE]ret += ((long) data[index + i] & 0xFF) << ((nb - 1 - i) * 8);[/QUOTE] An image is stored in the array data... whenI remove & 0xFF, It … Software Development java | |
Does anyone know how to use data to call access database ?? Software Development visual-basic | |
I am trying to use a radiobutton that I have attached to a from in VC++ .NET 2008 I have Named the RadioButton "BuyRadio". From what I know a radiobutton can have to stated, either true or false, wich meen pressed or not pressed. What I am trying to do … Software Development c++ | |
Are call by reference functions of type int or double legal when using an ifstream or ostream argument? Example: [code]int afunction(ifstream& in, int anumber) { /* Function Body */ } [/code] If this is/isn't legal please explain. Thank you for your help. -Arielle | |
can someone teach me k-maps and boolean algebra.... also give me the links to some ebooks which explain the basics of k-maps if u find any. Software Development assembly | |
How do I make it show text? I'm completely new to this, my dad's wanting me to make this customer display screen show text, which on paper should be easy.. It's a WD-202 model, pretty common customer display pole, I've called a friend for help and he told me to … | |
I have a string that loks like "u'mystring'". i'm wondering if ther is a easy way to remove the u'' part of the string? Software Development python | |
Is it possible to have a comboBox set to "Readonly" as you can have for a TextBox in VC++ 2008 .NET. I have looked at every properties for the comboBox and I cant find anything like this. Software Development c++ | |
I am fairly new to c++. What is the diffrence between ATL, CLR, or MFC and for what are they used for. Software Development c++ | |
I am programming for a microcontroller using CCS compiler (which based on C language) My code is pressing button to select a specified time then using that time to switch on and off a lamp, for e.g The value I got when press button is an int, with 0x31 stand … Software Development c | |
I wrote a class and I want to give it to someone to use, but I dont want them to have access to the source code. My class is split into 2 files a .h and a .cpp how can I block them from seeing the cpp file only the … Software Development c++ | |
Hello, I am trying to create a program that asks a user to input a integer. That integer will dispaly "*" (i.e. enter 4 diplay - ****) This is what I came up with so far to no luck! [code]#include "stdafx.h" #include <iostream> using std::cout; using std::cin; using std::endl; int … Software Development c++ | |
Hi Guys, I have a nested dictionary that i would like to be populated from a file at the start of my prog and put back into the file at the end of the prog. Could anyone direct me to somewhere where i could get info on how to do … Software Development python | |
How do I go about writing a user-defined function named Get_Inputs that when called, the function will prompt for three integers and send these numbers to its calling environment. Software Development c++ | |
can anyone suggest any website that will help me a lot on creating a simple chatbox? tnx Software Development vb.net | |
Hi, I have created a module to calculate a level when given a score. How do I send the calculated level back into my main form? Thanks in advance Software Development visual-basic | |
Hi all, I am learning VB 6 and i a just a beginner and i need to know some programs who is made it i VB 6 so that i can have a reason why i am learning. If you can send me some pictures or some kind of program … Software Development visual-basic | |
hello i would like to perform a method overloading with inheritance my code is : [CODE]public abstract class Shape { protected Point position ; public Shape(int x, int y) { position = new Point(x , y); } public void show() { position.show(); } } public class Rectangle : Shape { … Software Development | |
Hello, I would like to pose a very simple question, does anyone know how to clear the command window of text, and give it a name(Eg. Cosmos's Program) I would like to make room for different lines of text in my program, and also give it a name, for obvious … Software Development c++ | |
Hi, all! I'm trying to send a HttpWebRequest to an url that, other than %20, does not take escaped characters. But for some reason, when I do: [ICODE]_HttpWebRequest = DirectCast(System.Net.HttpWebRequest.Create(New Uri("http://web_address")), System.Net.HttpWebRequest)[/ICODE] I end up with an escaped uri string. For example, a string containing the swedish letters Ã¥, ä … Software Development vb.net | |
Hello! I m struggling with this button and/or code to work. The button with Process.Start opens any folder I want if I do not use Ifs and Elses, but I do need to open folder based on user selection of name in the combobox and one choice from two radio … Software Development visual-basic | |
![]() | Hi. I am trying to make a program that will launch restricted user-specified programs at my school. How would I make the system() function below make use of the two variables in it. I've tried && and ||, but the bugger wont work. [code] #define runasc "runas /profile /user:tsc\\staffuser" system( … Software Development c++ |
Hello all. Sorry to be a bother but I cannot figure out what is wrong with my homework program that's due before midnight. The assignment is to create a program with a two-dimensional array that generates a random walking path. I'll list the assignment as it is probably clearer. [I]Write … | |
I am trying to use ifstream to read from a file. When you use ifstream you have to specify the path like this. [code] ifstream Symb("Folder1\\Folder2\\File1.txt"); [/code] Instead of specifying like that, I will find a variable Text from a comboBox like the code below. Path has the string: "Folder1\\Folder2\\File1.txt" … Software Development c++ | |
I need help fixing this I help getting errors #include <cstdlib> using namespace std; void show_word (string); int main () { show_word ("hello"); system ("PAUSE"); return 0; } void show_word (char); { char InName; cout << "Enter your name " << endl; cin >> InName >> endl; show_word ("hello"); show_word … Software Development c++ | |
Consider the following user-defined function: [code]void Quick_Change (int x, int & y) { if (x == 0) y = 10; else if (y == 0) x = 10; } [/code] Assume the values in variable A and B are both of int type. How do I find what the values … Software Development c++ | |
Need help I wont to get a system date as integers such as(22/02/2008) rather than string cause I need this to compare two dates any ideas? Software Development c | |
no idea what to do about this error =/ [code]#include <stack> #include <string> #include <iostream> #include <fstream> using namespace std; int main () { stack<string> stack; ifstream inFile; string consoleStr = "Enter Filename>> "; string fileName; string word = ""; char c; cout << "Welcome! Enter filename or quit to … Software Development c++ | |
I wrote a class in vs2008. I am creating a new project and I need to incoporate that class into it. How do I do that. I added the .h to the header section and the .cpp to the source file. In the new program i did #include "firstclass" but … Software Development c++ | |
At this point I am trying to get data from a std::list or std::vector. I push_back the object from a pointer into the list and go on my merry way, I do this until I get to the point I want (which is working at the moment) but then when … Software Development c++ | |
Ok, I know C/C++ really well, but just started Java today and am having an issue. I have an assignment where I have to ask the user how many names he wants to enter, and then have him enter all of the names. After all of the names have been … Software Development java | |
who can help me in java? this is my code: //employee.java public class Employee { String emp_id; String emp_name; String emp_icno; char emp_gender; String emp_dob; String emp_addr; String emp_comDate; String emp_dept; String emp_pos; double emp_sal; public Employee() { emp_id = "99999"; emp_name = ""; emp_icno=""; emp_gender='m'; emp_dob=""; emp_addr=""; emp_comDate=""; emp_dept=""; … Software Development java | |
So I have taken on an extra credit assemly code challenge, and I am having a hard time getting started. What I need to do is be able to divide two 16 bit numbers and then display that answer. I can figure out how to divide a 16 bit number … Software Development assembly | |
Hello all, I have been working on a homework assignment that has to build a program for a user to enter student's grades and see the student's average as well as a class avaerage. Besides some cleaning up, organizing, and labeling I am pretty happy with it and it is … Software Development c++ | |
Hello everyone, and thank you in advance for any help you can give! I am working on a simple program with some long integers, which I have defined as type long long, with LLU after them. I am trying to use these variable names in an arithmetic expression, but when … Software Development c++ |
The End.