43,549 Solved Topics
Remove Filter ![]() | |
I am in a class and am trying to get this project done. I get the code to compile but it is giving me a out of bounds error. Here is the assignment. Write the program in Java (without a graphical user interface) and have it calculate the payment amount … Software Development java user-interface | |
Hello I'm writing a python program and need some help. Firstly, is there anyway to include variables in an input prompt? For eg. [variable1 = 4 variable 2= 3 variable= raw_input("Please enter a number between", variable 1, "and", variable2) ] Also, if data is being appended to the end of … Software Development python | |
Okay, i have 2 objects in my form: a label with a picture and a picturebox with a picture. The background of my form has another picture. What i want to happen: 1.I press the label,the picture of the label is on top with the bakground of the picture in … Software Development | |
I need to write a program that will output a list of all even numbers between 1-100. It needs to use a while loop then use a for loop. Any one got any help on how to do that? Software Development java | |
Please tell me why this doesn't work: [code] #include<iostream> using namespace std; int main() { char felix[3] = "ho"; if(felix == "ho") cout << felix; } [/code] Software Development c++ | |
I understand, vaguely, what a reduce/reduce conflict is, but I don't understand why I'm getting one in my Yacc Parser. Can anyone help me out? [code=yacc]Prog : START StmtSeq END { }; StmtSeq : Stmt StmtSeq { }; StmtSeq : { }; Stmt : Id ASSIGNOP Expr SEMICOLON { *$1 … Software Development c | |
Hi, I have a quick question...so I have this program that asks user to enter an integer and then it analyzes that integer..it outputs factors of that number, and tells whether its composite or prime, abundant or deficient, and so on...and then after telling few things about that number..it asks … Software Development c++ | |
Hi guys, I am doing a TCP/IP time server/client. I already wrote the two programs but when I run them I don't get any output. Simply, the idea is the client asks the server for Time or Date and the server has to respond and terminate after the second request. … Software Development c client-server | |
Good day, Hi, I'm trying to develop mapping feature for a tool. It has a wx.ScrolledWindow that contains wx.lib.buttons.GenBitmapTextButton as map nodes. When the number of map nodes reached around 50+ the scrolling becomes too slow. Any ideas on how to improve the performance of the scrolling when there are … Software Development python | |
i have sucessfully coded my form so that when a user enters data into the texxt box and searches any matching data is displayed on another form my problem is when no data matches the search criteria the form that would display the result still opens but is blank how … Software Development vb.net | |
:?: How do you make an object, say a rectangle, move in turbo c++, using right and left arrow keys? I want the object to move when a user presses right or left arrow keys. Please reply ASAP either here or at my email [I]<<email address snipped>>[/I] | |
I'm now trying out for loops with different sized iterations (is that the right word?) This loop [code] for (int i = 0; i < 5; ++i) { for (int j = 0; j < 3; ++j) { Console.WriteLine("i = {0} j = {1}", i, j); } } [/code] outputs … Software Development | |
[CODE]//SELECT ID van ingelogde gebruiker MySqlConnection cn = cn = new MySqlConnection("server=localhost; user id=bla; password=bla; database=project; Allow User Variables=True;"); cn.Open(); string selID = "SELECT LidID FROM gebruikers WHERE Gebruikersnaam=?Gebruikersnaam;"; MySqlCommand cmd = new MySqlCommand(selID, cn); MySqlDataReader dr = default(MySqlDataReader); //Add parameters to get the username and password cmd.Parameters.Add("?Gebruikersnaam", MySqlDbType.VarChar); cmd.Parameters["?Gebruikersnaam"].Value … Software Development dataset | |
I have 3 functions working together, but I only have abundant returned every single time, I don't know what is wrong [CODE]def sumDivisors(n): total = 0 for counter in range(1, n): if (isDivisor(n, counter)): total += counter return total def checkForPerfect(n): total = sumDivisors if (total == n): return 'Perfect' … Software Development python | |
[code] Private Sub PopulateProductList() Dim con As OleDbConnection Dim cmd As OleDbCommand Dim dr As OleDbDataReader Dim strSQL As String Dim objListItem As ListItem Try strSQL = "SELECT [Sr No], [First Name] FROM [Lani]" con = New OleDbConnection(connectionString) con.Open() cmd = New OleDbCommand(strSQL, con) dr = cmd.ExecuteReader() lblani.Items.Clear() Do While … Software Development vb.net visual-basic | |
Thanks in advance for your help. I am writing a program that is supposed to display a menu and ask the user to enter a list of his/her favorite games, then display the games if they choose to. The problem is that when it comes to entering the names of … Software Development c++ | |
Hi all, I have the following task; Extend an ArrayList of Integer by adding a method called 'sum', that returns the total sum of the elements of the list of integers. Such that each time the method is called sum up all the integers. So I started by making the … Software Development java | |
I would like to know how can I transfter a string value (a name or something) from Login class over static class to Form1? This code I have: 1. In program class: [CODE] static class Program { /// <summary> /// The main entry point for the application. /// </summary> [STAThread] … Software Development | |
Ok, here goes, I've got a staticwindow where I am putting the information from keyboard presses and onscreen button presses. When I run the program, I can press the keys and they show up just fine. I then press the button on the screen with my mouse which also works. … Software Development c++ | |
I am trying to copy a string into an array then write bits out to a file accordingly. (compression assignment). here is the code [code=c] // strnewdup(const char* s) returns a copy of a // null-terminated string, with the copy stored // in the heap char* strnewdup(const char* s) { … Software Development c++ | |
Hey, I have one question though, how do you write on a txt file??? Software Development python | |
java.io.FilePermission this exception always thrown when I am trying to run my code using tahiti server that i am developing java mobile agent Software Development java | |
the following code I want to press done buttone to close JFrame without exit the application ---------------------------------------------------------------------------------- [CODE] package examples.SecretaryAgent; import java.awt.*; import java.awt.event.*; import javax.swing.*; public class Display extends JFrame { private JCheckBox _first_Interval; private JCheckBox _second_Interval; private JButton _done_Button; public Display() { setLayout(new FlowLayout()); _first_Interval=new JCheckBox("First Interval"); _second_Interval=new … Software Development java java-swing | |
fscanf is a C function designed to read character by character from a file to the system how we can use scanf programmatically to read till first white space ???? :) :) Software Development c | |
I am developing C#-based mobile application and the exception always thrown and catched by my try catch block Exceptin thrown : The database file cannot be found.Check the path to the database [File name = .\MyMobileDB.sdf] the snippet code is [CODE] namespace DeviceApplication4 { public partial class Form1 : Form … Software Development open-source | |
When I am trying to debug my mobile application , that used C# as programming language a notification beside the open the connection appeares and display that the module of it not loaded and thank you Software Development | |
Hi. I am new to this forum, but i have been playing with Visual Basic since 4.0. Anyway here is my problem. I am getting error and can't figure out why. [CODE] Dim connectionString As String Dim cnn As OleDbConnection connectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\Database\tmprcStavka.mdb;" cnn = New OleDbConnection(connectionString) Try cnn.Open() … Software Development dataset open-source vb.net visual-basic | |
I'm a complete and utter noob to VB so I sorta bit off more than I could chew with this little project. I'm not so sure how to create a calendar. But I have sort of designed it already. I'm planning on making the layout with labels and maybe tooltip … Software Development visual-basic | |
Hi people. I'd like to use MySQL in my application - would be an easy way for me to store users. But then I'd have MySQL credentials in my app, visible for everyone with a HEX editor, I'd suppose? And even though that MySQL user will have low privileges, then … | |
I want the remainder of all the numbers inside the loop except the number which i assigned for variable [B]a[/B] for example , if i entered number [B]5[/B] for [B]a[/B], the loop is 5 4 3 2 1. i want my program to take remainder of all these values except … Software Development c | |
![]() | Hi everyone, I just started learning Python 3.1 (never done programming before). I just wrote this useless little program. It seems to work but I would just like a little bit of feedback as to how well I executed the idea. Basically I want to know if I am making … Software Development python ![]() |
I am working on a guessing game in Python and would like some feedback on how the code looks. I am struggling a bit with it, particularly with the menu options and getting it to loop back to the menu again after it has written to a high scores txt … Software Development python | |
So I have this code: [CODE]String^ main = "http://www.lockerz.com/"; if(main == web->Url->ToString()){ MessageBox::Show("Hello", "WIN"); }[/CODE] and it's attached to a timer that ticks every 100 milliseconds. Oh yeah, and web is the web browser in VC++. But when I run, I get this error: [CODE]An unhandled exception of type 'System.NullReferenceException' … Software Development c++ web-browser | |
hi i have a program here the 15 puzzle my problem is that im having a hard time makeing a random function the right way and also thinking of a way to make so that the program will not go out of the bounderies here my code [CODE]#include <stdio.h> void … | |
In this programming assignment I need to implement a number of useful functions using a header file and an implementation file. I will place the prototypes for my function in a .h file, and implement these functions in a .cpp file. I will also need to write a driver (a … Software Development c++ | |
This issue is probably caused by me being an idiot a while back. I installed Office 2010 beta on my dev box. It did NOT affect my project that uses Microsoft.Office.Tools.Excel However when I decided to uninstall 2010 and go back to 2007 only to maintain some compatibility with customers … Software Development assembly microsoft-office | |
To accept 3 number and find max among three number(using && for checking multiple experssion) [COLOR="Red"]Please help me, I am a beginner in this discipline, and I hope I explain the problem[/COLOR] Software Development java | |
Hi, im trying to use an actionlistener attached to a button to add a component to a frame I have created. The actual button should add to the frame a circle with some text placed in it which I have already created, it works fine so there's no problems there. … | |
Hello, I have writted a prog that generates the values & triangleOf Pascale. But the thing i cannot seem to find, is[B] how to get rid of the Console.Writlines in the middle of my code[/B] (where the values get calculated). I am using a 1 dimensional array for this insteed … Software Development mathematics | |
Hello, I want to make a linked list program consisting of one main link, and each main links have sub link. [CODE]Main 1 -> Main 2 -> Main 3 -> ... -> Main N -> NULL | | | | Sub 1-1 Sub 2-1 ... ... | | Sub 1-2 … Software Development c++ linked-list | |
hi, i have a very simple problem with my program and just need a push in the right direction and will be much appreciative of your help. i have a bucket sort program which works fine. well i say fine, its fine when it is sorting the numbers initialised at … Software Development c | |
Hi, all. I'm trying to write a function that checks the status of a Tic Tac Toe game. If there's a winner, it'll return the character for the winner ('X' or 'O'). If there's a draw, it returns 'D'. I'm having trouble getting it to check whether the game is … Software Development c++ | |
Hello everybody, I'm new to Python wx and I'm trying to make an application which requires the use of database content. I've already made the input data frame. I need to make a frame where to list the database content. I need to create a label for each row like … Software Development python | |
I have created a function to determine the lowest out of 5 scores, I'm not too sure as to whether or not it can be simplified... the function is as follows: [code=C++] void findLowest (int & minScoreP, int score1P, int score2P, int score3P, int score4P, int score5P) { minScoreP = … Software Development c++ | |
Each time I create a new GUI, the bit that I always hate, is the bit where the buttons and entries look like I am working on a Windows 98 machine, isn't there a way to make my buttons and entries look like Qt would look like? They're well squary … | |
[CODE] #include <stdio.h> #include <stdlib.h> int det(int); int minor(int); int main() { int mat[10][10],dim,a,b; printf("Please enter an integer for matrix dimensions(1-10):"); scanf("%d",&dim); for (a=0;a<=dim-1;a++) { for (b=0;b<=dim-1;b++) { mat[a][b]=rand()%10+1; printf(" %d",mat[a][b]); } printf("\n\n"); } printf("Determinant for the matrix is: %d",det(mat)); return 0; } int det(int mat[10][10]) { int a,b,temp,length; length=0; … Software Development c | |
I'm using the rsa module (easy_install rsa), and if I use it from command line: [code=python]import rsa public,private = rsa.gen_pubpriv_keys(3) cipher=rsa.encrypt("test",public) rsa.decrypt("cipher",private)[/code] this will return test again. (like expected) but in my code it gives a zlib error -3 incorrect headers [code=python]def RSA(txt): global crypt if crypt=="en": key=raw_input("Public key:") ciphertext=rsa.encrypt(txt,eval(key)) … Software Development encryption python | |
Hello, I'm trying to write a method that resets a string to a default value (previously defined in a class) if the value inputted is not a valid. Because I know the format or structure of a valid input, I should easily be able to do this. The string is … Software Development java | |
The code below is the file for the constructor method and the get methods [code] //Date: 3/18/2010 public class Taxpayer { private int socSec; private double yearlyGross; public Taxpayer(int taxPayer, double income) { socSec = taxPayer; yearlyGross = income; } public int getSocSec() { return socSec; } public double getYearlyGross() … Software Development java oop programming-construct | |
Hi, New to this forum, but been browsing a few threads and seems like the best place to seek help. I have an assignment to complete. What I need to do is read in values from a .txt file and place these values into a matrix. I have the values … Software Development c++ |
The End.