132,726 Archived Topics

Remove Filter
Member Avatar for
Member Avatar for HBK_100

I have a string array for example string name[5]={"A","B","B"} I am accepting an string input from a user and want to check it against that of the array. cout<<Enter letter; cin>>letter; if(toupper(letter)==name[0]) { ............ ........... } but i am getting an error

Software Development c++
Member Avatar for HBK_100
0
93
Member Avatar for dgreene1210

hey I was wondering if anyone out here can help me with C++ and also adding a loop at the end to be able to ask the user if they want to look up another part. attached is the string code i was given. #include <fstream> #include <iostream> #include <string> …

Software Development c++ ios
Member Avatar for Taywin
0
173
Member Avatar for garu525

Hello, I'm trying to create a program that reads data from outside file using functions. My goal is to get data from an outside file, and use that data for other functions that i havent created yet. this is my code so far but it wont read and giving me …

Software Development c++
Member Avatar for WaltP
0
172
Member Avatar for aznlitomik3

Write a program to compute the square root of a number. DO NOT USE any math libraries in this program. You will be using the Babylonian method (a.k.a. Heron’s method) to approximate the square root. More information is available on wikipedia: [url]http://en.wikipedia.org/wiki/Methods_of_computing_square_roots#Babylonian_method[/url] To calculate the square root of x, the …

Software Development c++
Member Avatar for aznlitomik3
0
645
Member Avatar for wowz

[CODE]/** Generates the n'th Fibonacci number */ import java.util.* ; public class FibonacciGeneratorTester { public static void main(String[] args) { System.out.println("The 1st Fibonacci number is: " + getFibonacci(1)) ; System.out.println("Expected: 1") ; System.out.println("The 3rd Fibonacci number is: " + getFibonacci(3)) ; System.out.println("Expected: 2") ; System.out.println("The 5th Fibonacci number is: " …

Software Development java
Member Avatar for kramerd
0
181
Member Avatar for totalwar235

i am trying to use my program to move north, east, south, west using the first letter of the full word. though, whenever i run my code and get to this point my coordinates do not update and i remain stuck at 4,6(or 5,6). can anyone help me with this …

Software Development c++
Member Avatar for totalwar235
0
91
Member Avatar for evertron

I am using a sample from my book for testing a car class. I get this error and I am not sure why. I am only giving one argument that I can tell. Here is my error code: Traceback (most recent call last): File "G:\Python_Stuff\car.py", line 79, in <module> myCar.getVIN('V81FDX') …

Software Development python
Member Avatar for evertron
0
92
Member Avatar for zulqarnain ali

I need some help in speech recognition project please help me which tool i use and how many steps it required meens main functionality of speech recognition if any one have code please give me for my help please.

Software Development c++
Member Avatar for bobbyspeechrec
0
156
Member Avatar for kuchick32

I have mostly the entire program done but I am having a couple issues. I need to get titles of five movies from the user and store them in the proper member variable for each instance of the five movies at the end of the program. This is what I …

Software Development c++
Member Avatar for jonsca
0
128
Member Avatar for cortez716

I have written a code that will post random numbers into a 10x10 row/col setup. I'm trying to edit the last function of code so that the user see's something like this: Input a number 5 5 was found 3 times 5 is located at row 2, col 1; row …

Software Development c++
Member Avatar for daviddoria
0
122
Member Avatar for Lando_

The problem states to use a loop display character from the ASCII codes 0 through 127 and to display 16 character per line. I am using Borland C++ 4.5 so I need the older programming way of doing it. This is what i have so far. [CODE]#include <iostream.h> int main() …

Software Development c++
Member Avatar for Lando_
0
1K
Member Avatar for sciprog1

Hello Members, I have three balls(all JPanels) bouncing in a JFrame. Following are the files: BouncingBalls.java: [CODE]import javax.swing.*; import java.awt.*; class BouncingBalls extends JFrame { public BouncingBalls() { setResizable(false); setSize(400,400); Ball ball1 = new Ball(); Ball ball2 = new Ball(); Ball ball3 = new Ball(); ball1.add(ball2); ball2.add(ball3); getContentPane().add(ball1); setVisible(true); Thread …

Software Development java java-swing
Member Avatar for sciprog1
0
2K
Member Avatar for heidik

Hello everyone Could any one please help me parsing a line having different fields separated through commas. I want to store each comma separated sub string in a struct member variable. The lines are being read from a file. [code]105:1:CME,20100601,07:34:22.796,GRC,GE,201009,FUT,XGGRC,0G4LHZ013,14ijpol1vsu7l7,Fill,0000D9DB,B,00000,99.155,2,99.155,20100601,07:27:34[/code] for example the line ID which is "105:1:CME" is one …

Software Development c++
Member Avatar for Taywin
0
4K
Member Avatar for cjmartin

I have a datagrid with textboxes on it that are bound. Displaying the data pulled from the db works. But when a user updates a textbox I am unable to extract that data. I have tried a few options I have found involving using CType. Below is part of the …

Software Development vb.net
Member Avatar for cjmartin
0
100
Member Avatar for ixmike88

hi, im getting this error: [quote]Unhandled exception at 0x00c11005 in bnetconnection.exe: 0xC0000005: Access violation reading locaiton 0x00c11005[/quote] in this particular instance, what i got from the debugger is that 0x00c11005 is my _ProcessCommands function dll: [code]#include <iostream> using namespace std; extern "C" _declspec(dllexport) void ProcessCommands( const char*, const char*, const …

Software Development c++
Member Avatar for mike_2000_17
0
706
Member Avatar for Armistice

Hi. Another newbie here looking for some insight. I have a menu drivin program with 5 functions. got first 3 down and the 4th wants me to read a plain text fil and output the length of the longest line. I know as far as getline(infile,str). where str is just …

Software Development c++
Member Avatar for Armistice
0
462
Member Avatar for svatstika

Dear friends! I have a button in form1, and now I want when clicking on it, a new form (form2) will appear. There's a text box on this form2. User will input a integer here. After user's pressing Enter, this integer will be given to a function into Form1.cs and …

Software Development c#
Member Avatar for darkagn
0
177
Member Avatar for nautolian

Hi all, I'm trying to make a program that breaks an entered sentence into seperate words, then compares the words to a predefined txt file of words. So far I have the following code, but it just doesnt work for some reason. no errors or anything. It asks for the …

Software Development algorithm c++ file-stream
Member Avatar for nautolian
0
119
Member Avatar for babbu

I am using Visual studio 2005 and Access 2007. I get the following error "System.InvalidOperationExceptin: The ITransactionLocal interface is not supported by the 'Microsoft.ACE.OLedb.12.0' provider." Is this because transactions are not supported by access? Here is my code. [CODE] using (TransactionScope TransacScope = new TransactionScope()) { //insert and update operations …

Software Development microsoft-access visual-studio
Member Avatar for Momerath
0
113
Member Avatar for convoluted

Hi all. I'm having a bit of trouble implementing the basics of a multi panel GUI. Basically I need a GUI that will act as an in-dash display for a car. The home screen will offer the user the ability to chose a selection of buttons. For example, the 'settings' …

Software Development gui python
Member Avatar for convoluted
0
287
Member Avatar for BadPointer

Hello guys, been struggling with implementing a linked list. I'm using this function AddToList to add elements. I'm clearly doing something wrong because no new element is added. Although when Im using a breakpoint inside the function i see that it seems right. [CODE] /* Main.cpp */ #include "LankadLista.h" #include …

Software Development c linked-list
Member Avatar for BadPointer
0
108
Member Avatar for MarounMaroun

Hello all, I have this struct: [CODE=c] typedef struct cell { char _name[2]; int _calcResult; int _depend[MAX_CELLS]; } Cell; [/CODE] and this is my main: [CODE=c] int main(int argc, char* argv[]) { FILE *fp; int i; fp=fopen(argv[1], "r"); Cell Cells[MAX_CELLS]; fillNames(fp,Cells); for(i=0;i<4;i++) printf("%s\n", Cells[i]->_name); } [/CODE] [CODE] static void fillNames(FILE* …

Software Development c
Member Avatar for sree_ec
0
148
Member Avatar for Memphis_212

The following def is my assignment .. the problem is the accumulator pattern gets me very lost. I don't know how to write it.. I have asked my instructor for help and he refers me to the sad sad book we have been given. I DO NOT WANT THIS QUESTION …

Software Development python
Member Avatar for TrustyTony
0
1K
Member Avatar for Kerrai

Greetings So i'm trying to figure out how regex works and already run into a roadblock. I figured out the easier ones, if a string only consists of numbers or letters. But these required a little more thought it seems. These are three random linen that i need to check …

Software Development java regex
Member Avatar for Taywin
0
132
Member Avatar for WolfShield

Hello everyone, I was wondering, if I wanted to make my code a little smaller in one file, is it possible for me to import another file I made? E.G. (Very simple e.g. just for helping understand what I mean) Let's say I made a program that the user types …

Software Development file-system python tkinter
Member Avatar for TrustyTony
0
1K
Member Avatar for mbartz

I am trying to Subclass ElementTree with an abstract method. I have read in several forums that ElementTree is actually both a module and a class. I have been unable to get the subclassing to work. [CODE]from abc import ABCMeta, abstractmethod from xml.etree.ElementTree import ElementTree, Element, tostring class A(ElementTree): __metaclass__ …

Software Development python xml
Member Avatar for Gribouillis
0
221
Member Avatar for frogboy77

hi again, i'm just full of problems. i have a vectors of ints and i am trying to find a way to check if there is a repeatting sequence within the vector and what size this sequence is. Does anyone have any suggestions on how i should go about this? …

Software Development c++
Member Avatar for frogboy77
0
97
Member Avatar for |hex

:) my project consists of me making my own two pass assembler for my systems programming class. i have finished pass 1, my code complies and everything, but, when i try to make it read an input file, it states that it is never found. i dont know what to …

Software Development c++ file-system
Member Avatar for |hex
0
145
Member Avatar for saraswathy6

Hi, I have an xml like this <agency count="133">GOV.NIH.XYZ.465.56</agency> <agency count="129">GOV.NIH.ABC.245.21</agency> <agency count="216">GOV.NIH.NCI.456.23</agency> <agency count="48">GOV.USDA.4412.345.08</agency> <agency count="46">GOV.USDA.1411.345.00</agency> <agency count="51">GOV.USDA.5512.231.05</agency> <agency count="42">GOV.USDA.1411.16.10</agency> <agency count="39">GOV.USDA.5512.16.12</agency> <agency count="32">GOV.USDA.1411.17.03</agency> <agency count="60">GOV.FDA.4412.33.56</agency> <agency count="59">GOV.FDA.4410.45.87</agency> <agency count="55">GOV.FDA.1411.56.213</agency> <agency count="60">GOV.FDA.1412.86.45</agency> <agency count="55">GOV.FDA.1431.32.45</agency> I need to sort them based on the coutn for each agency . The results …

Software Development xml
Member Avatar for iceandrews
0
120
Member Avatar for ZozOQ

Hello i am new here, i want to ask about a problem of mine. I have made a server code, so i can send commands from other program C# i made that but my problem is when i start the java program because is Loading. The Server is starting at …

Software Development client-server java
Member Avatar for kramerd
0
192
Member Avatar for aaronmk2

I am having trouble figuring out what the recursive function does in the insert sort. Wouldn't the recursive line block the rest of the code from working. I am just looking for a quick explanation. [CODE] void insertion_sort-recur(int a[], int n){ if(n<=1) return; insertion-sort_recur(a, n-1);//how does this line work temp=a[n-1]; …

Software Development c++
Member Avatar for mrnutty
0
1K
Member Avatar for jwill222

Problem that ask to write an application that fills an array with 50 random integers,loop through the array,displaying each value, and count the number of negative values;after the loop finishes display the count. Note: The Random32 procedure from the Irvine32 library generates random integers. *I honestly don't know where to …

Software Development assembly
Member Avatar for jwill222
0
1K
Member Avatar for wowz

[CODE] import java.util.* ; public class CurrencyConverterTester { public static void main(String[] args) { Scanner scanner = new Scanner(System.in) ; System.out.println("How many euros is one dollar?") ; String input = scanner.nextLine() ; double rate = Double.parseDouble(input) ; CurrencyConverter converter = new CurrencyConverter(rate); boolean done = false; while (!done) { System.out.println("Dollar …

Software Development java
Member Avatar for wowz
0
179
Member Avatar for logicmonster

Is there a way to evaluate cosecant^2 in c? As far as I know, it isn't included in the math.h library, but could there perhaps be another one that it is included in?

Software Development c
Member Avatar for WaltP
0
61
Member Avatar for Sohelp

Sinx= x- (x3/3!)+ (x5/5!)- (x7/7!)+....... I can't solve it Please help me........

Software Development c++
Member Avatar for Sohelp
0
138
Member Avatar for soccer13

Hey guys, I got such great help last time I decided to come back for more :). Hope I'm not bothering with these questions, my teacher isn't much for being nice or explaining.. Right now we are getting into methods, I know that they aren't that difficult but I for …

Software Development java
Member Avatar for peter_budo
0
79
Member Avatar for mallyonline

I have followed the article about [B]Write and read to cmd line from GUI[/B] on the post located [URL="http://www.daniweb.com/forums/thread308015.html"]here[/URL]. I have downloaded the files RedirectStandardOutput.zip posted by Diamonddrake. I found these to be exactly what i wanted to include in my own form and attempted to copy the code into …

Software Development gui
Member Avatar for Diamonddrake
0
360
Member Avatar for burcin_erek

help me below algorithm. it gives wrong output e2 was wrong. 7.38..... [CODE]#include <cstdlib> #include <iostream> #include <math.h> using namespace std; int main(int argc, char *argv[]) { float x, err, term_1,result=1.0; int i=1,burcin; float factorial; cout << "x="; cin >> x; cout <<"error tolerance="; cin >> err; term_1=err+1; while (term_1 …

Software Development algorithm c++
Member Avatar for burcin erek
0
134
Member Avatar for L.sha

I am trying to run this program, in this I have a class clocktype with its header file and implementation file. Now I am trying to inherit this class to implement a new function called timezone. The build is successful but I have 2 errors while compiling here is my …

Software Development c++
Member Avatar for L.sha
0
189
Member Avatar for digan

i have to create a program in which a user is asked for: How many values (s)he wants to enter (maximum 50); Asks for the values and stores them into an array of double. Sorts the values in descending order. Prints the sorted array to the console. this is what …

Software Development c++
Member Avatar for arkoenig
0
130
Member Avatar for Altarium

Hello! I'm working with a DataGridView that I want to format based on the condition of whether or not a date has passed. For example: If the date in a cell is past the current date, that cell and its row are formatted with the forecolor red. My current code …

Software Development vb.net
Member Avatar for Altarium
0
3K
Member Avatar for ace8957

Hello all, So I'm working on this simple program with a Queue class template that is publicly derived from the abstract base class CharQueue. The only problem is that I keep getting hit with the error "expected class name before '{' token". The reason I don't understand this is that …

Software Development c++ oop queue
Member Avatar for Fbody
0
738
Member Avatar for empyrean

Hello.. i will try to be clear.. here i am working on a datagrid. in datagrid one column is editable as i am passing DataGridTextColumn to it and holding the data when users enter data into it and writing back to database. i am saving to database using datagrid_celleditending event …

Software Development
Member Avatar for "ICode"
0
156
Member Avatar for sharifyboy7

Implement a class SortedList as defined by the following skeleton: [CODE] #define MAX_ITEMS 10 typedef float ItemType; class SortedList { private: int length; ItemType values[MAX_ITEMS]; int currentPos; public: SortedList( ); // default constructor: lenght=0, currentPos=-1 void MakeEmpty; // let length=0 void InsertItem(ItemType x); // insert x into the list void …

Software Development c c# c++ visual-studio
Member Avatar for Fbody
0
355
Member Avatar for gemp

hey guys ,, i have a register form with register button and i need the info. from that form to be stored on file (Maybe secured txt),, i know it need System.IO (StreamReader and Writter) but i forgot everything about it so plz help thanks

Software Development
Member Avatar for gemp
0
65
Member Avatar for bufospro

Hi all, I am trying to make a program but I have a problem. So I can't continue. I am using a struct like that : [CODE]typedef struct account { char fullname[40]; int id; int amount; char name[15]; } account; typedef struct parking_system { int pos; char name[15]; char description[80]; …

Software Development c
Member Avatar for dgreene1210
0
155
Member Avatar for Syrne

Hello! Well, I've been given a fairly difficult assignment (at least to me), and I can't seem to wrap my head around some parts. Here are the objectives: [I]"In this assignment you will demonstrate your ability to design a class and provide its declaration (.h) and implementation (.cpp) files. All …

Software Development c++ file-stream
Member Avatar for Syrne
0
183
Member Avatar for globberbob

Well, in this program I want it to take in a string or character array I really don't care which, for this instance I wouldn't know which is better. Afterwords, it compares those in if statements and sets a variable to a 1(female) or 2(male). Anyways, here is what I …

Software Development c++
Member Avatar for globberbob
0
181
Member Avatar for LoveMyPadres

I am trying to implement virtual LEDs on a Python window. I turn the LED "on" by drawing a green oval. I then use root.after() to schedule another call that turns the LED "off" by drawing a dark green oval. I use a 250ms delay. There are 4 active LEDs …

Software Development python
Member Avatar for LoveMyPadres
0
2K
Member Avatar for nagatron

Hello to all, I am always mad about this problem. If I type a name with two words in a textbox like "google corporation" it will be registered in the database ms access as "Google Corporation" now that is okay. What I want is, there should be no duplicate of …

Software Development microsoft microsoft-access visual-basic
Member Avatar for nagatron
0
226

The End.