132,726 Archived Topics
Remove Filter ![]() | |
I am writing a program to manipulate a stack containing integers using push, pop, print, etc. The only thing I have left is to write a function called copy. Here is what I've tried so far: [CODE] void Stack::Copy(Stack otherStack) { otherStack.top = top; for (int ii = top-1; ii … Software Development c++ | |
What's the main difference between while(){ } and do{ }while() loops? From looking at it, it looks like the former evaluates before it performs the iteration and the latter does the evaluation after each iteration... is that correct? Why would I pick one over the other? Is it mainly just … Software Development c | |
Hi All, I have created a grid and want to implement the following idea: The user should be able to enter only numeric values in any of the cells in that grid. I could not get any property of the cell which can check for the entered data. Please guide … Software Development python | |
I am developing e-library for visually challenged people, in this system i kept a utility to add book from one interface. I want to store the location of the actual book in the database while adding a book. For e.x. I am storing the book at c:\books\pdfbooks\bookname.pdf this location c:\books\pdfbooks\bookname.pdf … | |
I am trying to put together a simple inventory program for my class, but I keep running into one error that I just cannot seem to correct. Here is my code: public class DVD extends Product { // channel that the show was on private String channel; // constructor public … Software Development gui java java-swing user-interface | |
I use a database connection string as below and my program work fine. Public Function initdb() Set ws = DBEngine.Workspaces(0) Set db = ws.OpenDatabase(App.Path & "\Masterfile.mdb") Set rs = db.OpenRecordset("Detail", dbOpenTable) max = rs.RecordCount Exit Function End Function *********************************** But now I lock the msaccess table ie. Masterfile.mdb with password … Software Development visual-basic | |
Hi , I'm a newbie to python. I would appreciate if someone can help me in solving this one. Say i have a string [b]str1 = "a:1,a:2,b:3,c:4"[/b] I want to get output in form of a dictionary like [b]d= {a:3 , b:3 , c:4}[/b] i.e if in the string[b] a[/b] … Software Development python | |
I need help making code that will create 4 different output files. All I know at the moment on this topic is how to fopen/fclose and the stuff in between however fopen requires the output file to be available before the program stars to run. Mabey theres an fcreate function … Software Development c | |
//I am having problem with the final portion of my program; it is for a class. //This is what I have so far, and the exact instruction I have for final part are: //Finally, modify the above program to read the numbers in from a text file (numbers.txt), write the … Software Development c++ | |
I hav two buttons & listview on the form,On First button click,i want to insert data & images into Lvw,On Second Button click,I want to just insert the data..Mine code also does that... But just there is a little probs.On button1_Click, I assogn smallimagelist to imagelist name ,on Second button … | |
I am trying to input a data file into C++ such that it will appear as 2 arrays of maximum value 100... so far, this is what I have... void readfile(double x[], double y[], double sigma[], int * entries) { /* read data into x[] and y[] fill sigma[] with … Software Development c++ | |
Hello, How would I go about being able to subscribe to the keyboard? For example, I would like my program to be alerted anytime a key on the keyboard is pressed, not just while my windows is in focus? Also, while I am asking, how do I get the windows … Software Development | |
I have this code: in my judgement it should print 1 and 2, instead it prints 0 and 1 some advice pls... Im using dev c++ [CODE=cplusplus] #include <iostream> class A { public: A() { arr = new int[2]; } ~A(){ delete [] arr; } int * arr ; }; … Software Development c++ | |
Hello ! I am developing a Desktop base not Web base application in C# by using Visual Studio 2003 I want to show images in one column of datagrid against each Product Id by using Picturebox which is coming from Database and want to raise events against the click and … Software Development c# email visual-studio | |
I am working on a C program that parses code from a high level language and generates MIPS code. I have a question about the logic to test for (in)equality in an IF statement. For example, my code generation for a statement like [CODE]IF a!=b[/CODE] I just use [CODE] else … Software Development assembly | |
I have my final due at 6 tomorrow and I need help on one tiny piece and it'll be finished. Here's what it needs to do. 1. When the program begins, it should ask the user to enter the seat prices for each row. The prices can be stored in … Software Development c++ | |
Is there any way I can change the value of a template parameter inside the templated object or are these values constant. i.e. [CODE] template<int width, height> class matrix { ............ } void matrix<width,height>::setSize(int w,int h) { width = w; height = h; } [/CODE] Software Development c++ | |
Description This program is to be utilized by basketball coaches. The coaches will be able to input a player's points scored over a span of ten games and the program will then output the player’s average. Program Design. Declare PointsScored [10] of reals Declare sum, average as real Declare B … Software Development c++ | |
Hi all... For a project I have to create a small program that adds class data using templates. I've completed the project, but the output is not expected for the last cout in main. Here is the code: [code=cplusplus] #include <iostream> #include<string> using namespace std; template <class T> T add … Software Development c++ | |
I'm having a blast coding up my little text-based python game. I'm learning a heck of a lot while doing it. Now, I want to share it with some friends. I could just have them install Python and send them the files, but I was wondering if I could somehow … Software Development python ubuntu web-server | |
I'm trying to write a script thats spawns a fortran program that needs std file input i.e. you would open it in bash with: [ICODE] ./program < input [/ICODE] How can I do this in python? I have tried the os.spawnl() and it spawns the process but the input does … Software Development python | |
i am using windows 7 and i am trying to setup a program but it is asking me to install visual c++ runtime i think i got the right one but it doesn't work can anyone help me out on this thanks | |
How would it be possible to check if a subKey exist in the Classes root in Registry Editor. My attemt is like follows but my compiler doesn´t like it. 'Microsoft::Win32::RegistryKey' : class does not have a copy-constructor no conversion from 'nullptr' to 'Microsoft::Win32::RegistryKey' [code] Microsoft::Win32::RegistryKey subKey1 = Microsoft::Win32::Registry::ClassesRoot->OpenSubKey("one\\two"); if( subKey1 … Software Development c++ | |
Hi, Im working on a project for school and Im having a little trouble with one of my functions. I need a function to find the highest test score and a function to print the highest test score and the student that has it. The students first and last names, … | |
I have a big question that keeps asking me if it is a correct or good idéa to create a subkey on a users computer in order for a software to work. The software will create and check if that subkey exists in the below directory in order for that … Software Development c++ | |
Please can some one help me with codes to check and see if a text box contains first name, space and surname Software Development vb.net | |
My code is [CODE]package diningphilosophers; class DiningPhilosophers { // Η κλάση αναπαριστά την εφαρμογή static Philosopher philosopher[]; static Forks forks; static DiningRoom diningRoom; public static void main(String[] argv) { philosopher = new Philosopher[5]; forks = new Forks(); diningRoom = new DiningRoom(); for(int i = 0; i < 5; i++) philosopher[i] … Software Development java | |
Hello, Ive just started programming in Assembly and im having a little trouble with the language itself. I wanted to make a program that takes two positive integers and adds them together, and outputs a message if theres a carry over, but i have no idea how to go about … Software Development assembly | |
Hello, i'm making a small little app that pings all ips on a network from 192.168.0.1 to 192.168.0.255 and populates the active IPs into a listbox. Then from there i want you to be able to select one to look up the machines name on the LAN. [CODE] Private Sub … | |
Hi Guys, I need some light on this. I am a beginner programmer in vb.net but used to be programming in the old days in QBasic, Cobol, Dataflex, Informix, DBase etc. Now, I am developing/creating software and have hired some online programmers to do the job. My questions are: a) … Software Development vb.net | |
Hello. I'm currently having a memory leak problem in my program (C++ with MFC, VS2005) and I don't know WHY it happens, as the code seems to be OK to me. Anyway, here's the code that causes memory leaks: [code=C++]char* va( char* FormatStr, ... ) { va_list ArgPtr; char *FinalString; … | |
Hi I really need help It is a homework for just four days later. want someone to write two programs for me: 1-A program that converts a decimal number to hexadecimal 2-A program that generates the output below using loops: Software Development visual-basic | |
Hi all, i need help on how to change a grid line((x1,y1), (x2,y2)) to another color. I have a 6 * 6 grid(black lines), made using pygame and i want to change the colour, with response to a mouse click on the coordinates. Is this possible? Below is the code … Software Development python | |
hy to all members of Daniweb im a finance student currently taking computer programming course, im kinda shy to post it here actually coz im not good in IT nor programming. im really really new in C++, im having problem with my assignment. hope that all the seniors here could … | |
I am trying to write a program to do the hill cipher technique of encryption. I am stuck trying to break the large array of numbers representing letters etc. into multiple smaller arrays with one column and two rows does anyone know how this could be done?? Here is the … Software Development encryption python | |
I'm writing part of a program that involves writing user generated information to a text file. [code]class MonsterStats: def __init__(self, name): self.__monName = name def setName(self, name): self.__monName = name def fileWrite(self): monFile = open('MonsterFile.txt', 'w') monFile.write(self.__monName) monFile.close() [/code] I wrote this to test it out: [code]import MonsterClass name = … Software Development python | |
I'm not really to sure with using python and its object oriented features as Im better with java. Im not sure whether to put the functions inside the classes as i can't really seeing this making a difference. I will apply my code and any changes or guidence would be … Software Development python | |
this is a homework task im completly lost in? we need to implement this header file below i like to think im pretty good at arrays and classes.... but the new additon of dynamic arrays has got me really confused... any help would be greatly appreciated [code] #include <iostream> using … | |
[COLOR="Green"]Hello all.. I have a problem with my program in here. I am making a chatting application and i just need a final touch. This is the code snippet i make to represent my problem. First, i'd like to tell that i want to make the sending process like the … Software Development java java-swing | |
hello all, I am attempting to write a simple programe that will imitate pressing a button on a third party application. so far i have this: [code] // astro rocks BOOL CALLBACK FindButttonPush(HWND hWnd, LPARAM lParam) { if(GetDlgCtrlID(hWnd) == 1000){ *(HWND *)lParam = hWnd; return FALSE; } return TRUE; } … Software Development c++ | |
I am creating a matrix math library which I would like to give the user access an element in the NxM 2D array, that was allocated in the constructor. I've been reading that you can't overload the [][]. How would I be able to overload this overload this operator so … Software Development c++ | |
Hi I'm having a lot of problems with this project. [URL="http://rapidshare.com/files/231273948/project_programmeren01.rar.html"]http://rapidshare.com/files/231273948/project_programmeren01.rar.html[/URL] This is the source code in rar, because it's to much to copy-paste. Are there people who can solve those errors? Software Development c++ | |
I want to write a function that displays the whole contents of a list. But im not sure how to do so. I have displayed my datatype of which i want to print...and at the bottom is the function that I want to print the list with. Thanks in advance. … Software Development | |
Please can anyone tell me why that program crashes when I enter the first matrix? [CODE]#include<iostream> #include <stdlib.h> #include <windows.h> using namespace std; void menu() { cout<<" \t\t\t\t*-*-UNIATIVE Matrix calculator-*-*\t\t\t\t "<<"\n"; cout<<" "<<(char)1<<" NNNN MMMM AAAA "<<(char)1<<" "<<"\n"; system ("color 08"); _sleep(1000); cout<<" \t\t\t *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-\t\t\t"<<"\n"; cout<<"Ahlan washlan ya user Ya … Software Development c++ matrix-multiplication | |
Hi, I have a shell script that is supposed to change the permission for my WWW folder so that Apache can access them. My current script is [CODE=shell]chown apache /var/www/* chmod 755 /var/www/*[/CODE] This works fine for /var/www/ but subdirectories of /var/www/ e.g. /var/www/html/ is still owned by samarudge (My … Software Development apache shell-scripting | |
i want to read words form a text file and remove the comars and fullstops and then put the single word to a vector. but when i try the method below i get an error can some one please help me. [CODE]char delim[100]=",.`~!@#$%^&*()_+=-{}][:';?><|"; ifstream fileOne("file.txt"); string fileWord; while ( fileOne>> … Software Development c++ | |
can anybody tell me .why it is not working .any help would be greately appreciated.Bold line is not working.Kindly find the attachment also.it becomes red i am using ms office 2003. kindly help me. here is the code what i have written. [code] Sub AddTopHeader() Selection.TypeParagraph Selection.TypeParagraph With Selection .Font.Name … Software Development visual-basic | |
hi guys im working on a project which i have almost compleated, which saves the data onto a text file (semi colon delimited ) however the second part requires me to import this file into access database by clicking a button on my projects gui, i already know how to … Software Development asp.net file-system gui vb.net | |
Reputed number problem switch case statement hai This is my code Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dim i As String i = TextBox1.Text Dim x As Object For Each x In i Dim num As Integer num = x.ToString() Select Case num Case … Software Development vb.net |
The End.