199,114 Archived Topics

Remove Filter
Member Avatar for
Member Avatar for AnGuRuSO

so I'm using code from [url]http://schmidt.devlib.org/java/file-download.html[/url] in the hopes of inputting a URL and getting the file that URL points to. It works, sometimes. 90% of the time it doesn't work. Also, it seems a lot of the pages I want to download do not end in html, although I'm …

Member Avatar for nalini.harsha
0
856
Member Avatar for arsh_arsh

need to replace all occurences if substring by new string. below code replace first occurence but not other substrings present in input string.

0
251
Member Avatar for sakhi kul

Hi to all, I have table student in which I inserting first name,middle name, last name in 3 different columns. but when i want to show it in gridview I want to join three columns into only one heading "Name". Is it possible...? or any other way to show it..?

Member Avatar for Kusno
0
109
Member Avatar for dhanya_piit

hey, can any one tell me whether i can write methods other than getxm or put xml in restful web services.If yes then which will be the first function to be called

Member Avatar for klactose
0
96
Member Avatar for websurfer

Hello, all: I'm trying to sanitize/secure my query, and it all seems ok when I test it with most special-characters... but when I try to test the single quote (') like this... [url]www.mysite.com/page.php?category=[/url]' Then it gives me this error: "You have an error in your SQL syntax; check the manual …

Member Avatar for network18
0
122
Member Avatar for eggmatters

Hi all, I am rather new to PHP, but have a fairly ok grasp of software design. My question arises from the fact that I'm getting ready to deploy some scripts etc. to my website which is hosted on a *nix type server. My home / work computer that I'm …

Member Avatar for leviathan185
0
108
Member Avatar for mahakaal
Member Avatar for fallopiano

hi everyone. Just out of curiosity more than anything; does anyone know of a library that can grab microphone input (on windows)? I'm looking into how to write a kind of VoIP (voice ip) program. I know how to use sockets for sending/receiving data, but I just need the microphone …

Member Avatar for Stefano Mtangoo
0
278
Member Avatar for COKEDUDE

Could anyone tell me what is wrong this code please. I'm trying to do this. Add a static method Account consolidate(Account acct1, Account acct2) to your Account class that creates a new account whose balance is the sum of the balances in acct1 and acct2 and closes acct1 and acct2. …

Member Avatar for skoiloth
0
209
Member Avatar for yatman

Hi, I am trying to write strings to a file line by line and trying to format the output so that the alignment is proper. output should be it should appear in the output file as david 10 15 16 sam 11 15 16 but appears as david 10 15 …

Member Avatar for yatman
0
171
Member Avatar for bushimports

How can I draw text in a glut window with the keyboard; I have tried doing cin with [CODE] void TextBox::Keys(unsigned char key,int x,int y){ switch(key){ case 13://enter key cin >> String; DrawString = true; break; case 27: exit(0); break; } [/CODE] and then in the draw function [CODE] fontx …

Member Avatar for mrnutty
0
2K
Member Avatar for jrosh

I created some data files with 'outfile ' command. The files are created in the mysql folder.{I use WAMP} I want to create those files in another directory. How can I do that? Thankx in advance.

Member Avatar for jrosh
0
166
Member Avatar for COKEDUDE

I'm trying to do some consolidation but I'm not sure on the specific rules of consolidation so I'm having A LOT of difficulty on it. Here's what I'm trying to do. Write a program that prompts for and reads in three names and creates an account with an initial balance …

Member Avatar for COKEDUDE
0
116
Member Avatar for knrakesh

Hello Guys I am working on a website I am not getting the forget password can u please help me in solving problem please Thanks in advance

Member Avatar for Stefano Mtangoo
0
131
Member Avatar for nccsbim071

What is the difference between following declarations: [CODE=C#] WebUserService.Service.IUserService userService = new WebUserService.Service.UserService(); WebUserService.Service.UserService userService = new WebUserService.Service.UserService(); [/CODE] I want to know the difference in usage and the the one that is most efficient in terms of programming in C#.

Member Avatar for nccsbim071
0
119
Member Avatar for luvsom

I have to create a program that accepts 3 user inputs (hours, minutes, seconds) and then asks the user whether they want it to show in standard or military time. The main program should make 2 calls to the function DisplayTime, whether its true if they want standard time or …

Member Avatar for restrictment
0
144
Member Avatar for Samyx

What is wrong with my code? [code] String[] movieString = {"movie1", "movie2", "movie3", "movie4"}; JComboBox movieList = new JComboBox(movieString); movieList.addActionListener( new ActionListener(){ public void actionPerformed(ActionEvent e) { JComboBox a = (JComboBox) e.getSource(); //String movies = (String)a.getSelectedItem(); if (e.isSelected()); return subpanel; } }); }[/code]

Member Avatar for BestJewSinceJC
0
80
Member Avatar for sebassn

Hey guys, I justs started this code to make a diamond with stars (*), but I get confused how to print the spaces that I need, I don't know if you understant what I'm trying to say. It is something like this: Prompt the user to enter (odd) height (of …

Member Avatar for restrictment
0
838
Member Avatar for lewashby

First of all, I'M reading the book "Microsoft XNA Game Studio 2.0". I understand the error I'M getting but I don't know what to do about it. The error says I can't use backgroundColor before it has been declared. I'M following along with the book so I don't see why …

Member Avatar for jbennet
0
140
Member Avatar for JonnyHawes

Hello everyone! So as my first post, I would like to say I am in no way unfamiliar with Visual Basic or programming in general, but this Database integration is giving me quite a problem! lol So basically I have a VB 2008 Project with a single form that displays …

Member Avatar for JonnyHawes
0
174
Member Avatar for Mitja Bonca

I have a problem with alignment of the child form in a parent form. I would like to have this Form3 in the upper right corner of the Form1 - always - even when user changes the size of the form1. Form3 it has to be located there. The location …

Member Avatar for kvprajapati
0
100
Member Avatar for newbie_to_c

Hello everyone, I need help with this code, which does not work properly. It prints fine at the first instant and when I convert it into a double it prints some unknown value. I am trying to get the maximum of all the values in the row. First: I cant …

Member Avatar for newbie_to_c
0
83
Member Avatar for blamp

can someone help me figure out why my output is incorrect any help would be apprecaited [code]#include<iostream> using namespace std; class fractions { public: fractions fractions :: operator+(fractions f); fractions fractions :: operator-(fractions f); fractions fractions :: operator*(fractions f); fractions fractions :: operator/(fractions f); fractions addFraction(fractions); fractions subFraction(fractions); fractions multiFraction(fractions); …

Member Avatar for jonsca
0
105
Member Avatar for konefsta

im new with C++ . i was in java but now im learning C++ and i am not very good at it . i am making a program about spam and ham emails . i have all the files in the same directory . i created Ergasia1.cpp , Ergasia1.h , …

Member Avatar for jonsca
0
185
Member Avatar for bees1

This is an example program that I am studying so that i can make my own mixed mode assembly/C program. I am having trouble understanding on the assembly code, why I have to push SI twice at different times and only pop it out once. Also why push and pop …

Member Avatar for mathematician
0
155
Member Avatar for axn

How do I reinitialize array to null or zero when reprompted to renter data. Tried this but still computes average for previous entry. Student[] students1 = new Student[studentCount]; here is a snippet of code [CODE]float totalscore = 0.0f; boolean isValid = false; String lastName = ""; String firstName = ""; …

Member Avatar for Chaosis
0
386
Member Avatar for blamp

can someone help me figure out why the output of my program is coming out wrong [code] #include<iostream> using namespace std; class fractions { public: fractions fractions :: operator+(fractions f); fractions fractions :: operator-(fractions f); fractions fractions :: operator*(fractions f); fractions fractions :: operator/(fractions f); fractions addFraction(fractions); fractions subFraction(fractions); fractions …

Member Avatar for jonsca
0
105
Member Avatar for EAnder

I've noticed there is at least 1 thread regarding to artificial intelligence. I assume most people new and old to python would be interested in artificial intelligence and the even greater goal of artificial life. I personally do not know anything about them. If you have ever had any experience …

Member Avatar for lrh9
0
157
Member Avatar for Alex_is

basically i have created a program which reads integers from a txt file and works out the averages etc. now the below code i wrote to simply state which month has the highest or lowest rainfall. below i have created the code but on compiling says there an error....can someone …

Member Avatar for thines01
0
154
Member Avatar for Chromana

Hey. I'm importing an array in a text file via [icode]array=numpy.loadtxt("testdata.txt")[/icode]. Is there an easy way to count the number of rows and columns? Maybe something like [icode]x=numpy.countrow(array)[/icode]? I've had a look around and couldn't find anything suitable. Thanks, Alex

Member Avatar for Chromana
0
306
Member Avatar for uberian22

this is my function [CODE]double area (int side_a, int side_b, int side_c) { double semi; double area_ans; semi = semi_peri (side_a, side_b, side_c); [COLOR="Red"]area_ans = (sqrt(semi * (semi - side_a)(semi - side_b) (semi- side_c)));[/COLOR] return area_ans; } double semi_peri (int side_a, int side_b, int side_c) { double semi_ans; semi_ans = …

Member Avatar for uberian22
0
82
Member Avatar for raigs

I get this gcc warning with [I]-Wwrite-strings[/I] flag. I want to return a string of chars correctly but I also do not want to use [I]malloc[/I]. I've read other posts but can somebody explain how to acheive this in layman wording? [QUOTE]a.c:14: warning: passing argument 1 of ‘VAR1’ discards qualifiers …

Member Avatar for Dave Sinkula
0
396
Member Avatar for neighbordave

I am trying to get two numbers to overflow and print an error message stating this. it works for some numbers, but other numbers for example adding the numbers 1073741824 and 1073741825 results in a negative number -2147483647 which is clearly overflow. However, I cannot get these negative numbers to …

0
79
Member Avatar for nonshatter

Hey, can anyone tell me what's wrong with this method? I keep getting <identifier> expected error on line 1. [CODE]public static void FaultHandler (DatagramSocket aSocket, InetAddress aHost, int proxyPort, byte[] requestArray, rec_bytes) { int faultCount = 0; while ( faultCount < 4 ) { DatagramPacket request = new DatagramPacket(requestArray, requestArray.length, …

Member Avatar for nonshatter
0
87
Member Avatar for pac-man

As the title says please. The issue I'm having is I've got a class which holds the vector. When I create a new instance of the class I assume a new vector is also created which results in the vector losing all its contents?

Member Avatar for pac-man
0
167
Member Avatar for jaison2

This is graphics.py from the zelle book. The following code seemed to be working but when i added the parameters to the function def drawEye(win, centre, radius): i get an error when i try to execute it Traceback (most recent call last): File "C:\Documents and Settings\Compaq_Owner\Desktop\t.py", line 22, in <module> …

Member Avatar for vegaseat
0
322
Member Avatar for ljvasil

I am having problems with my reverse polish calculator code. The code is as follows: [CODE]import operator OPERATORS = { '+': operator.add, '-': operator.sub, '*': operator.mul, '/': operator.div, } class Stack(object): "Creates a stack to enter numbers or operators into" def __init__(self): self.storage = [0,0,0,0] self.sptn = -1 def push(self, …

Member Avatar for vegaseat
0
619
Member Avatar for pyprog

Assume I have a file of the following format: a,1 b,2 c,3 d,4 Here is my code: [CODE]def junk(f): d1 = {} d2 = {} for line in f: columns = line.split(",") letters = columns[0] numbers = columns[1] d1[letters] = numbers d2[numbers] = letters return (d1, d2) def something(): print …

Member Avatar for vegaseat
0
270
Member Avatar for Gem74

Hi, I am trying to build a linked list, I have the following, and I get 4 error messages, ListNode, NumberList, and head undeclared, and then syntax error, please help. #include <iostream> #include <fstream> #include <ctime> #include <string> #include <cstdlib> //#include "input_data.h" using namespace std; class Node { public: int …

Member Avatar for jonsca
0
151
Member Avatar for tjackson

I am new to c programming. I am trying to write a parking garage program that uses arrays to find the charge for each car and the total charge. Here is what I have so far. Please help me in any way that you can. [code=c]#include <stdio.h> #include <math.h> float …

Member Avatar for Chilton
0
145
Member Avatar for Ballen92

Hello all. I have a problem that seems like it should be relatively simple to fix but I have been scouring the internet and can't find an answer =( I am trying to add a keylistener to this code, but it doesn't recognize the method addKeyListener(this); I am working with …

Member Avatar for Ballen92
0
789
Member Avatar for Espanhol

So i have to do a school project for next year and i was thinking about doing something like a Pokemon game. i don't know were to start, what software should i use and if you can give me any tips that would be great.

Member Avatar for Jiwe
0
82
Member Avatar for Calhoun

Could someone show me how to compile this [URL="http://sourceforge.net/projects/torrentsearcher/files/"]source code[/URL]? I dont know much about C++ but I want to edit the file that contains the homepage so the homepage is google. [url]http://sourceforge.net/projects/torrentsearcher/files/[/url] I think the program contains 3 different peoples source code that work together in the actual torrent …

Member Avatar for Grn Xtrm
0
82
Member Avatar for TheManual

I need to only allow integers and the letters "d" and "r" from raw input otherwise I need to run an exception. For example: [I]You entered 's' this is invalid[/I] I have tried to use try/except statements but can't work it out. Is this the best way? Can someone help? …

Member Avatar for vegaseat
0
124
Member Avatar for guffer

i have a program which displays a certain menu, after the menu it askes for the selection from the menu....now when an integer is used it works perfectly. but when you input a character(letter) in the menu it goes into an infinite loop. anything to use to stop this behavior …

Member Avatar for Jiwe
0
137
Member Avatar for Vikk

Hi all, Please I'm a newbie in PHP and MySQL, I have results from a GROUP BY (grouped by col2) query in the format. col1 | col2 ----------- a1 | a a2 | a a3 | a a4 | a b1 | b b2 | b b3 | b I …

Member Avatar for Vikk
0
136
Member Avatar for pyprog

Assume I have a file of the following format: a,1 b,2 c,3 d,4 Here is my code: [CODE] def junk(f): d1 = {} d2 = {} for line in f: columns = line.split(":") letters = columns[1] numbers = columns[2] d1[letters] = numbers d2[numbers] = letters return (d1, d2) def something(): …

Member Avatar for vegaseat
0
327
Member Avatar for gangster88

I have to get pthagaros to get the distance between 2 points. so the function distanceBetweenPoints(Point(1, 2), Point(4, 6)) should result in 5.0. the parameters are supposed to be P1, P2, which i think i have done?. The get an error when i try to execute this?.. help please def …

Member Avatar for gangster88
0
177
Member Avatar for abdelhakeem

Hello ! I'm New to ASP.NET, I want to use it with C++. I installed Microsoft Visual C++ 2008 Express Edition, And installed IIS ,When i've Written my First code to Test, I got this message: [QUOTE]An unhandled exception was generated during the execution of the current web request. Information …

Member Avatar for jbennet
0
218
Member Avatar for sonygamer

Hello everyone, I'm currently having some problems with this code. I am getting many compiling errors and i was wondering if you guys could help get rid of them. [CODE]#pragma once #define CAPACITY 128; typedef int QueueElement; class Queue { public: Queue(); int empty(); void enqueue(const QueueElement & value); void …

Member Avatar for sonygamer
0
179

The End.