43,549 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for gedas

hey everyone, well i have made a method that would return array of string. the strings would be obtained from the file(employee.txt) every 4th line in the file contains employees loginID i need to store those ids in to one array and then return it. here is the code of …

Software Development java
Member Avatar for gedas
0
133
Member Avatar for Netcode

How can one search for multiple items at once and display the result in a datagrid? for example, i want to search for multiple mobile numbers (in sql server database)at once and display the found numbers and their corresponding names.

Software Development vb.net
Member Avatar for zx1
-1
1K
Member Avatar for therobot

I'm pretty sure there's just a small bug I'm missing, but I can't seem to find it. Error: g++ -Wall Proj3.cpp -o proj3 -pthread Proj3.cpp: In function âvoid initLockVar()â: Proj3.cpp:52: error: expected primary-expression before â{â token Proj3.cpp:52: error: expected `;' before â{â token Proj3.cpp:256: error: expected `}' at end of …

Software Development c++ queue
Member Avatar for therobot
0
2K
Member Avatar for urbangeek

hi guys, i'm just starting out c++. Now the problem is, no matter whatever program i write, i'm getting this warning. [QUOTE]#warning This file includes at least one deprecated or antiquated header. \ Please consider using one of the 32 headers found in section 17.4.1.2 of the \ C++ standard. …

Software Development c++
Member Avatar for urbangeek
0
302
Member Avatar for jems5

I would like to compare user input against and entire file and print out message when item is found or item not found. My program below appears to do that but it is doings so one line at a time. Please help. Jems [CODE] import java.util.*; import java.text.*; import java.io.*; …

Software Development java
Member Avatar for jems5
0
2K
Member Avatar for jems5

In my program I need to have the user get two chances before ending the program. Currently if the condition is not satisfied then they only get one try. I would like some help in getting a second try. [CODE] // Takes user entry Scanner user = new Scanner(System.in); System.out.println("Please …

Software Development java
Member Avatar for jems5
0
81
Member Avatar for DerLars

Hello everybody, I have spend the last 6 hours on trying to access a char * type within a static struct without success. I guess I use the pointers wrong but after trying "everything" I am pretty lost right now. So hopefuly someone of you can help me. I have …

Software Development c queue
Member Avatar for gerard4143
0
142
Member Avatar for chris evans

Hey guys! Im working on a login form that connects to an SQL 2008 database. i have created records in the table for users who can login. i however want a code snippet that matches the username and password entered with the records in the database. i have a rough …

Software Development sql vb.net
Member Avatar for Netcode
1
8K
Member Avatar for Violet_82

Hi there, I have a question about a really simple program. The code below doesn't work, the compiler comes back with "fatal error C1083: Cannot open include file: 'ofstream': No such file or directory": [CODE]#include <iostream> #include <ofstream> using namespace std ; int main( ) { ofstream myfile("newfile.txt") ; myfile …

Software Development c++
Member Avatar for Violet_82
0
199
Member Avatar for gedas

hey everyone, well i got a little problem im trying to write input from the JTextField into the file (file4.txt) but the problem is it keeps overwriting the text file each time i make input and any data ther was is changed in to new data.all i need is that …

Software Development java
Member Avatar for gedas
0
88
Member Avatar for Goshutu

my program is made to enter a matix,in which it finds all of the column`s minimum numbers which are[COLOR="Red"] >0[/COLOR] and then put them under the last row.i have sucseded entering the array and puting it out,but i think my IF is wrong somehow.I have tried initialising the last row …

Software Development c matrix-multiplication
Member Avatar for Goshutu
0
204
Member Avatar for rje7

[code] public class Animal { public void eat() { System.out.println("I eat like a generic Animal."); } public static void main(String[] args) { } } class Fish extends Animal { @Override public void eat() { System.out.println("I eat like a fish!"); } } class Goldfish extends Fish { @Override public void eat() …

Software Development java
Member Avatar for javaAddict
0
170
Member Avatar for zulhimi89

Hi experts, I'm using vba to do my coding. I have to check whether the data exists in the db or not. so I'd done this to check it. [code] Set rs = New ADODB.Recordset With rs .Open "pr_q", cn, adOpenKeyset, adLockOptimistic, adCmdTableDirect curr_year = Year(Date) q = 4 .MoveLast …

Software Development vb.net
Member Avatar for AndreRet
0
87
Member Avatar for jmcorpse

I want to say thank you to everyone in advanced for all the help that has been provided. I am currently stuck on two more items on this program. Currently I am completely stumped on how to create a bar graph using the information gathered by the program. Some reason …

Software Development c++
Member Avatar for jonsca
0
99
Member Avatar for johntech2001

I am working through the book Beginning Visual Basic 6 Database Programming by John Connell. I have finished the section on Building a Data Control Class Module and have created a nice Book List program for my wife. I am using the DAO database control as shown in the book. …

Software Development visual-basic
Member Avatar for AndreRet
0
608
Member Avatar for adaniel058

[ATTACH]17854[/ATTACH] [ATTACH]17855[/ATTACH] [ATTACH]17856[/ATTACH] Guys I am trying to help a friend of mine with this project they have due in a few days and because I program in Java mainly I am a bit rusty with this. I can not figure out why my getInput function shows up under the …

Software Development c++
Member Avatar for adaniel058
0
140
Member Avatar for littleCuteMaria

I am working on a control break algorithm in C, and part of this algorithm is to have while loop check for the end of file and whether two strings equal each other. the first string is a part of a typedef struct structure called 'record' [I]rec.state[/I], and the second …

Software Development algorithm c
Member Avatar for Ancient Dragon
0
123
Member Avatar for emko

Hi, I need to make a simple calculator that just does addition and subtraction. But the program should keep a running total of the calculations entered like this: sum = 0 12 + 3 sum = 15 5-2 sum = 12 1+1 sum = 13 But it also needs to …

Software Development c++
Member Avatar for emko
0
398
Member Avatar for HoneyBadger

I am trying to add two hexadecimal numbers. [CODE]def addbinary(n1,n2): s = "" carry = '0' for i in range(3,-1,-1): if (n1[i] == '1' and n2[i] == '1' and carry == '0'): s = '0' + s carry = '1' elif (n1[i] == '1' and n2[i] == '1' and carry …

Software Development python
Member Avatar for HoneyBadger
0
458
Member Avatar for zwench

What does this mean and how can I fix it? An unhandled exception of type 'System.ArgumentOutOfRangeException' occurred in mscorlib.dll Additional information: Index was out of range. Must be non-negative and less than the size of the collection. [CODE]dgtsCustomers.GridColumnStyles(0).HeaderText = "Factory ID" dgtsCustomers.GridColumnStyles(0).Alignment = _ HorizontalAlignment.Left[/CODE]

Software Development vb.net
Member Avatar for samina228
0
161
Member Avatar for bio-grad

I received the following error, but I don't understand how to fix it. Help? "readline() on closed filehandle IN at transcribe.pl line 21." [CODE]#!/usr/bin/perl #transcribe.pl #convert DNA to RNA (T to U) use strict; use warnings; #TASK: Read DNA sequences from ‘DNAseq’ input file – #there is one sequence per …

Software Development perl
Member Avatar for bio-grad
0
3K
Member Avatar for arithehun

I have joined our local high school's FIRST robotics club, but their programmer graduated last year, so who got selected? The wimpy freshman: me! I am an intermediate programmer (PLEASE don't look at my previous posts, I now know two languages, and am better). So I downloaded an instruction booklet. …

Software Development c++ objective-c robotics
Member Avatar for arithehun
0
1K
Member Avatar for Bladtman242

This is probably really more of a math problem. I hope I want have to go into too much (for you, boring) detail about the code, as the problem resides in this loops. Please let me know if I provided too little detail :) Now for the problem: I would …

Software Development java
Member Avatar for Bladtman242
0
269
Member Avatar for Asset

def getAverage(numList): total = 0 for i in range(0, len(numList)): total = float(numList[i]) total = total + numList[i] average = total/len(numList) return average Hi, I'm really, really new to python, I'm having error on this function and I can't solve it yet, so can someone help? Thank-you :)

Software Development python
Member Avatar for Asset
0
713
Member Avatar for Nassarofficial

The first one is: A program that searches within a file and by user input for a word, and counts how many of this word in the file, and if its in the file or not. Thats what i reached so far: sword, line= 0, 0 filename= raw_input("please input file …

Software Development python
Member Avatar for griswolf
0
96
Member Avatar for hurkagurk

Thank you very much for reading this. I've been programming for 15 years (VB, a lot of PHP, etc), but I've never considered myself a 'real' programmer. Mainly I'll build things that I need that are too specialized to be made by anyone else - simple programs and scripts to …

Software Development machine-learning
Member Avatar for Kimpl
0
201
Member Avatar for j855

I have a question. I have a list of numbers like: Bobby 9 9 8 4 8 5 6 7 3 8 6 5 5 7 6 9 6 4 6 4 3 4 7 6 6 I have already written a code to take the numbers in range (1,15) …

Software Development python
Member Avatar for TrustyTony
0
113
Member Avatar for phfilly

Hi. I would like help on undoing and redoing using the memento design pattern. I want to save a state that a board is in. Like a chessboard. If the user uses the undo option a previous board should be loaded and all of the states that the pieces was …

Software Development c++
Member Avatar for phfilly
0
597
Member Avatar for Chalandria

Need help please. This program is supposed to be a do while loop and convert fahrenheit to celcius and vise versa using user defined methods but as of right now it just doesn't work. I need to make a do while loop in main method too, but was just trying …

Software Development java
Member Avatar for Taywin
0
137
Member Avatar for eladreznik

i am trying to create a nextrow button to work with a bound datagridview the problems i have: 1. the row moves down, but the first row is the one who has the focus (the little black triangle is staying to it's left. 2. i am trying to set a …

Software Development vb.net
Member Avatar for eladreznik
0
95
Member Avatar for creeps

This one is pretty strange (or at least I can't figure out what triggers it). I have the piece of code below, but there seems to be a bug with the second call of [icode]scanf[/icode]. It simply gets skipped. So the input should be something like [code] 10 3 fbfbfbfbfb …

Software Development c
Member Avatar for creeps
0
104
Member Avatar for getack

We have this massive project due tomorrow - a chess game that enables two or more players to play against each other. We have a board class, that contains a 2D array of Piece object pointers representing the lay area of the board. In the board constructor, the Piece array …

Software Development c++
Member Avatar for getack
0
259
Member Avatar for ceyesuma

Hello I am trying to get to a Component On a JInternalFrame. I have a reference to the frame on the frame there is a panel. on the panel there is a JTabbedPane. to add a tab to the JTabbedPane I need to reference the Pane. Is there a way …

Software Development java java-swing
Member Avatar for ceyesuma
0
169
Member Avatar for Robban

Hi, I have a javaproblem that I just can't solve. "Write a [B]recursive[/B] method who returns the largest value in an array with the signature: [CODE]public int max(int[] v)[/CODE] (Hint: If you need to, use a private help-method) It would be easy if it was allowed to change the signature …

Software Development java
Member Avatar for JamesCherrill
0
190
Member Avatar for saraswathy6

Hi, I need to call a public static method that returns in xslt. I'm using jstl to do the transformation and hence using the jaxp parser which would use XSLTC or Xalan internally. The way I have the namespacee declaration for my xslt is <xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:autn="http://schemas.autonomy.com/aci/" xmlns:myUtil="http://xml.apache.org/xalan/java/com.csa.porter.scat.CategoryUtils" xmlns:java="http://xml.apache.org/xalan/java" …

Software Development apache xml
Member Avatar for saraswathy6
0
617
Member Avatar for jmcorpse

I just need a little advice. This code I have written works well. The only problem I am having is that the output is not lining up and I don't know what to do. If everything was entered line by line I could get it to line up. Since it …

Software Development c++
Member Avatar for Ancient Dragon
0
73
Member Avatar for KrazyKitsune

I'm working on a self-project called 'Project Calculus' (Not that you care about the name). It's a huge calculator that works cross-platform and only uses 'already implemented' modules (So no SymPy, no NumPy, no SciPy, et cetera.) in it. I need help (If you even bother to cooperate with a …

Software Development python
Member Avatar for KrazyKitsune
0
126
Member Avatar for Masas

So I got this assignment to combine two arrays without using strcat(). The two arrays must be passed to function as parameters. The arrays need to be merged into one array in the function with dynamic memory allocation and then the new string needs to be returned back to main. …

Software Development c
Member Avatar for savdapu krishna
0
288
Member Avatar for masumar

Hi, How do I sum all occurrences of a number in a file? I have a file with a bunch of numbers, each on it's own line: 5 3 11 3 7 3 5 5 11 7 7 ... How do i sum them up so that the output will …

Software Development python
Member Avatar for TrustyTony
0
429
Member Avatar for polygon

I have a script called setuptex that is run on a terminal as [CODE]. ~/context/tex/setuptex[/CODE] I wanted to execute it from a bash script file instead of typing it each time on an interactive terminal. Since the dot operator and the source builtin command are similar, and I wanted a …

Software Development shell-scripting
Member Avatar for vaibhav1983
0
513
Member Avatar for VB2008beginner

I add connections in server explorors. Then, I use AdventureWorks Person.Contact to set up a query by searching peter and mary ,but how to add it on form 1 ? and I type part of their names and by the way how to link a "VB label of text" or …

Software Development client-server sql vb.net visual-basic
Member Avatar for lolafuertes
0
210
Member Avatar for henryford

Hey guys and gals I am really struggling with this program. I have been working on it for about a week now and every time I think I am getting somewhere it seems like it flops and I get frustrated and start over. I would appreciate it if anyone could …

Software Development python
Member Avatar for griswolf
0
174
Member Avatar for Mona..

Hi.. first of all, I want an answer in details if u dont mind.. When we use a class with Pointer data members,why do we need to: 1. include a destructor and a copy constructor in the class 1. overload an assignment operator which return pointer this for example: // …

Software Development algorithm c++
Member Avatar for group256
-2
696
Member Avatar for Shift-Stop

[code=c] // ----------------------------------------------- mySquare( y1) // rcv'ing dbl = 4 { double x1=1 ;// valid, but impossible to reach. printf("\n SQRD incoming Y1: %d",y1); // shows 4 printf("\n SQRD return y1*y1: %d",y1*y1); //shows 16 x1 = (y1*y1); // ??? printf("\n SQRD return X1: %d",x1); //shows 0 ! return x1; // …

Software Development c
Member Avatar for Shift-Stop
0
86
Member Avatar for ixmike88

hi i am trying to explicitly link a dll to my console application however LoadLibrary() keeps returning with error 126: the specified module could not be found the file is in the same folder as the exe, and i've tried moving it to system32 and it's the same error, so …

Software Development c++
Member Avatar for ixmike88
0
3K
Member Avatar for bambi231991

I need to know if i can take a user inputed string such as [code=python]name = raw_input("Enter Name:")[/code] and take the word inputed and break the string apart by letters for example: If the user enters "joe" i will get "j", "o", "e" is this possible? also i need to …

Software Development python
Member Avatar for TrustyTony
0
127
Member Avatar for confounded

I hope I'm doing this right since it's my first post. I have a hash table (HList, vector) of lists and I want to use bubble sort to sort my list of entries (HashEntry,class). It compiles fine and temp is a valid list, but my temp.end() is a bad pointer. …

Software Development c++
Member Avatar for confounded
0
189
Member Avatar for Newskin01

Hello, Is it possible for anyone to explain to me what "Initialize the 3 parallel arrays" means? Here is the problem. A file called seats.txt contains a description of an airline seating arrangement and a list of individual seat assignments. An example is shown here: rows 7 leftSeats 1 rightSeats …

Software Development java
Member Avatar for Taywin
0
803
Member Avatar for phfilly

Hey everyone, I'm having abit of trouble with a seg fault. As said in the topic, the piece of code that gives the error isn't really working with an array. I ran the program through the gdb tool in g++, and it says the the seg fault occurs in the …

Software Development c++
Member Avatar for phfilly
0
155
Member Avatar for sijei

Im a beginner programmer this semester, and python is my first language. I can do the homework but am naturally curious at spiffing up my programs to help me understand how to have many things working at once in a program. I have some ideas but have not been able …

Software Development python
Member Avatar for TrustyTony
0
127

The End.