2,827 Posted Topics

Member Avatar for VernonDozier

I have some simple php code. It worked fine on the old server, but now I am getting an error on the new server. Both former and present servers are Linux. [code=php] <?php function ConfirmationEmail () { $from = "mo@abc.com"; $recipient = "bill@yahoo.com"; $cc1 = $from; $cc2 = "mo@gmail.com"; $subject …

Member Avatar for blocblue
0
193
Member Avatar for solimanmuttawa

Code tags and formatting please. [noparse] [code=cplusplus] // paste code here. [/code] [/noparse] You also need to give us a much more detailed description of what the problem is.

Member Avatar for Lerner
0
89
Member Avatar for valluvanl

[code] [COLOR="Red"]void[/COLOR] mainMenu() [/code] [code] [COLOR="Green"]void[/COLOR] studentDetails(); [/code] Add red void. Function header needs the return type. Delete green void. Function calls DO NOT need the return type. MosaicFuneral beat me to it! Edit : So did Majestics.

Member Avatar for valluvanl
0
122
Member Avatar for MJFiggs

[QUOTE=MJFiggs;744556]I dont know why, but this program I wrote is having a problem. it has a problem converting an Ace from 11 to 1 when the players have more than 21. if you could look over this, I would appreciate it. lenghty, isn't it?:icon_eek:[/QUOTE] Yes, very lengthy. It would help …

Member Avatar for MJFiggs
0
120
Member Avatar for JackDurden

You have too many nodes. You want one node per UNIQUE word, not one node per word. I would rename your class to word or node. You should have one tree and several nodes. You don't want to name something "tree" if there is one "tree" per word, in my …

Member Avatar for cikara21
0
207
Member Avatar for freelancelote

[QUOTE=freelancelote;743859]Hi, here is my problem: I'm writing a small program that needs to read a text file and write the words of this text as a list. I could only come up with the little piece of code I wrote below and it's not even working. I believe the problem …

Member Avatar for cikara21
0
139
Member Avatar for Se7Olutionyg

[QUOTE=Se7Olutionyg;743201] Sorry for keeping creating those new topic, but I am in urgent I can not draw the hangman [/QUOTE] Don't apologize, just don't do it. That's five, count 'em five, threads on this topic. Mark four of them solved. You've had comments on the other threads which you have …

Member Avatar for cikara21
0
395
Member Avatar for VernonDozier

I am working on a program where there are several tasks that take time that users can implement. I would like a progress bar to pop up to inform the user how far the task has gotten. When the user presses a button on the main frame, I want a …

Member Avatar for VernonDozier
0
173
Member Avatar for cam875

[QUOTE=cam875;743017]that didnt help.[/QUOTE] His point is that x never changes. [code] xDisplacement = 0; x += xDisplacement; [/code] is the same as [code] x += 0; [/code] which does nothing. Second problem. You are comparing two doubles using the == operator. Generally that is a bad idea. You should probably …

Member Avatar for VernonDozier
0
95
Member Avatar for Se7Olutionyg

[QUOTE=Se7Olutionyg;743114]"program 5 final. exe has encountered a problem and needs to close. We are sorry for the inconvenience" . That how it is, there are no other problem, can you correct for me please, it will be dued tommorow[/QUOTE] Shall we correct it [URL="http://www.daniweb.com/forums/thread159161.html"]here[/URL], [URL="http://www.daniweb.com/forums/thread159142.html"]here[/URL], or [URL="http://www.daniweb.com/forums/thread159042.html"]here[/URL]? Close two of …

Member Avatar for vmanes
0
337
Member Avatar for koushal.vv

[url]http://msdn.microsoft.com/en-us/library/system.guid.aspx[/url] [quote] A GUID is a 128-bit integer (16 bytes) that can be used across all computers and networks wherever a unique identifier is required. Such an identifier has a [COLOR="Red"][B]very low probability [/B][/COLOR]of being duplicated.[/quote] How low of a probability are you looking for?

Member Avatar for ArkM
0
146
Member Avatar for TimothyKhoo

[QUOTE=TimothyKhoo;696192]haha.....lol....[/QUOTE] What kind of response is that? Do you want advice or are you just posting random stuff that makes no sense on message boards or what?

Member Avatar for TimothyKhoo
-1
138
Member Avatar for Lardmeister

[QUOTE=Lardmeister;623222]We are down to the finish stretch, most likely only two folks to choose from. I have added 'Other' if you don't like any of the two, and you want to write in your own favorite like Captain Kirk, Tammy Baker or such.[/QUOTE] I'm wondering whether "Other" will raise his/her …

Member Avatar for jbennet
0
3K
Member Avatar for The Dude

[QUOTE=Ezzaral;740844]Um, what? Is that supposed to make sense?[/QUOTE] I think he's talking about vmanes' byline.

Member Avatar for Ezzaral
0
89
Member Avatar for davids2004

[QUOTE=davids2004;739310]Write a program that calculates how much a person earns in a month if the salary is one penny the first day and doubles each day worked. [B]The program should ask the user for the number of days worked during the month[/B] and should display a table showing how much …

Member Avatar for VernonDozier
0
151
Member Avatar for madmaxx350

Looks pretty good except that you are defining an integer with the same name as the parameter passed to it. I doubt I would pass anything to the function. I don't see that you use the number passed to it or that you need anything passed to it. I would …

Member Avatar for vmanes
0
73
Member Avatar for 666kennedy

[QUOTE=666kennedy;739301]i have an array weights[16][60] 16 rows of 60 columns if you are changing indiviual elements it goes from weights[0][0] to weights[15][59] right? [/quote] Correct. [QUOTE=666kennedy;739301] see if im using them in a loop for instance [CODE]]for(int i = 0; i < 16; i++) {[/CODE] so each element is used …

Member Avatar for Rashakil Fol
0
87
Member Avatar for 666kennedy

[QUOTE=666kennedy;739312]this is my sub proceedure [CODE]/****************************************************************************** * * Name: patpixselect * Parameters: none * Returns: patpix[] * Globals: none * Description: database for which pixels for which pattern *****************************************************************************/ int patpixselect (int pat); { float patpix[9] ; // array for pixels in patterns if (pat == 1) { patpix[0] = …

Member Avatar for VernonDozier
0
71
Member Avatar for CantDoThis

[QUOTE=CantDoThis;733620]cool thanks, but it doesnt stay on the screen. getchar() doesnt work[/QUOTE] [url]http://www.dreamincode.net/forums/showtopic30581.htm[/url] You can try cin.get () instead of getchar. [code] #include <iostream> using namespace std; int main () { char ch = 'a'; cout << ch << endl;; ch++; cout << ch << endl; cin.get (); return 0; …

Member Avatar for mujash.techee
0
156
Member Avatar for forgoodor4awsum

[QUOTE=forgoodor4awsum;737417]we are to write the entire code..here is the project "Your Sudoku class should have a constructor, and a “read” function that reads in the file “Sudoku_game.txt,” a 9 by 9 matrix of digits from 0 to 9. (Zero indicates that no number has been put in that cell.) Your …

Member Avatar for VernonDozier
0
2K
Member Avatar for davids2004

Write a function that does not allow for negative input: [code] int GetNonNegativeInteger () { int input; cin >> input; while (input < 0) { // display error message. // ask for input again } return input; } [/code] Call this function from main when you need non-negative integer input.

Member Avatar for davids2004
0
9K
Member Avatar for koman

[QUOTE=koman;738304]I don't understand that can u post it in my code?[/QUOTE] [code] getline(infile, buffer); while ( !infile.eof() ) { cout << buffer << endl; } [/code] This is an infinite loop. Put the getline statement inside the while loop. If you put it where Narue says to put it, you …

Member Avatar for VernonDozier
0
150
Member Avatar for Jaqky
Member Avatar for altrim

[QUOTE=altrim;738217]hi everyone i am new to C++ need help; //Write a program that for 5 books with this atributes //books name //authors name //publishing year //book price to be selected only the books from the same year typed by the user(using structures) |[/QUOTE] Post your attempt and ask a specific …

Member Avatar for VernonDozier
0
133
Member Avatar for christiangirl

I don't see anywhere where the program reads from the file. item.number is never initialized so it is printing whatever was in that memory location, which could be anything, but has nothing to do with the contents of your file, since the file is opened, but never read from.

Member Avatar for christiangirl
0
94
Member Avatar for localp

[QUOTE=localp;736770]it didnt work, i get an error when i type a string like " hhfdh "; it works for numbers but not for string ...[/QUOTE] I don't know what you did, but you perhaps aren't catching a NumberFormatException. IOException won't catch the error you are referring to. parseInt throws a …

Member Avatar for stultuske
0
164
Member Avatar for mshefa

[QUOTE=mshefa;737499]How do I write a C++ class program to convert temperatures from Celsius to Fahrenheit and vice versa?[/QUOTE] Use the Daniweb search engine. There have been scores of threads dealing with this that can help you get started.

Member Avatar for MosaicFuneral
0
247
Member Avatar for StainlessSteelR

[QUOTE=StainlessSteelR;737386]Okay I got it to work halfway. I had to put the cout statement inside the last } because of an "error: expected constructor, destructor, or type conversion before '<<' token". Don't know what that means.... Theirs just one problem with the findMax function the max_id= i; produces the last …

Member Avatar for VernonDozier
0
170
Member Avatar for egsonas

I'd say people aren't downloading because it's a big zip file. There's actually not much code in there at all, but people see a big zip file, figure it's thousands of lines of code, and ignore the post. You have to point out a particular problem you're dealing with, generally. …

Member Avatar for VernonDozier
0
256
Member Avatar for anbuninja

Change lines like this: [code] if (package == 'A' || 'a') [/code] to: [code] if (package == 'A' || package == 'a') [/code] Edit: You have some bracket problems. Do you mean this? [code=cplusplus] if (package == 'B' || package == 'b') { cout <<"Enter hours used:"; cin >> hours; …

Member Avatar for WaltP
0
140
Member Avatar for abhaydiwan

Code tags, formatting, and please point out the errors and where they are. You can quote a line number or highlight the error in red. [noparse] [code=JAVA] // paste code here [/code] [/noparse]

Member Avatar for VernonDozier
0
96
Member Avatar for leeba

Code tags and formatting please. [noparse] [code] // paste code here [/code] [/noparse] It looks at first glance that you have a brackets problem. If the code to execute if an if statement is true is more than one line, you need to surround that code with brackets.

Member Avatar for leeba
0
137
Member Avatar for Syrus_Jones

[QUOTE=Syrus_Jones;735722]Ok, i just realized what an idiot i am, i got the factor thing figured out, and putting in increasing order, but........can someone help me with the 4 factors per line, and each factor being in a field of 10... [CODE] while(number > 1) { if (number%factor == 0) { …

Member Avatar for skatamatic
0
818
Member Avatar for DesiFrank

[code] effectiveRadius = wheelradius * frontsprocke / rearsprocket ; // ( Is that right ? ) [/code] Yes, that looks right except for the typo. You are getting an error (in addition to the typo) because you are using variables that aren't initialized yet. Read in the values, THEN calculate …

Member Avatar for BestJewSinceJC
0
131
Member Avatar for wander4heat

What's the question? Is it not compiling? Is this all one big file? Is it the whole file? The main thing I see is that you have a bunch of semicolons in the implementation functions where they shouldn't be and you have a bunch of const declarations in your function …

Member Avatar for VernonDozier
0
105
Member Avatar for Blackout22

There are a few things to think about when designing functions. One, what does the function do? Two, what parameters, if any, does the function need to take? Three, what, if anything, does the function need to return? Four, how do you call the function? [code] cout << "What do …

Member Avatar for skatamatic
0
121
Member Avatar for mrjoli021

You have a whole bunch of threads going. Please mark the ones that are solved "solved". We don't know which thread to respond to and we don't know whether someone else has posted a solution on another thread. It saves us all time, including you, if you don't have multiple …

Member Avatar for stultuske
0
88
Member Avatar for The Dude

Check out the date, Dude: August 06, 2004. Nobody writes stuff like that now (well I guess some people still do). It was during the Bush v. Kerry 2004 campaign, when you could get away with it. Too much has come to light since then.

Member Avatar for jbennet
0
177
Member Avatar for Trekker182

[QUOTE=Trekker182;730145]I was wondering if anyone could offer some suggestions on how to validate a social security number & their employee # that a user would input separately through prompts? The SS# would be in the form of xxx-xx-xxxx where the x's are 0-9. I tried using this function that I …

Member Avatar for Trekker182
0
833
Member Avatar for Tchevalier

[QUOTE=Tchevalier;735487]The data file is a set of floating point numbers. Here they are the ones I have in my data file: 1.2 3.3 1.5 2.9 2.5 2.1[/QUOTE] In order to do the standard deviation, you need to store each number for later use in either an array or a vector. …

Member Avatar for VernonDozier
0
201
Member Avatar for thangarajforyou

[QUOTE=thangarajforyou;733770]the thing is that i cant able to get the code because the page source code is locked . i mean the trading terminal page..now have your say buddy[/QUOTE] Hostile, aren't we? What do you expect anyone here to do? You probably don't have access to the source code because …

Member Avatar for stultuske
0
397
Member Avatar for resduq

Here is an example of how to pass an ofstream. [code] #include <fstream> using namespace std; void foo (ofstream& outs); int main () { ofstream outs ("file.txt"); outs << "one"; foo (outs); outs << "three"; outs.close (); return 0; } void foo (ofstream& outs) { outs << "two"; } [/code]

Member Avatar for ArkM
0
164
Member Avatar for mrjoli021

Your question has already been answered on your other thread, and I've explained twice the mistake you are making on the code tags. Again, it's this: [noparse] [code] // paste code here [/code] not this: [/code] // paste code here [/code] [/noparse]

Member Avatar for Ezzaral
-1
142
Member Avatar for mrjoli021

Close on the code tags: [noparse] [code] // not [/code] here // paste code here [/code] [/noparse] Can you post the updated code and an input file?

Member Avatar for BestJewSinceJC
0
255
Member Avatar for The Dude

[QUOTE=hughv;732449]I was later able to put all this training to good use in Vietnam[/QUOTE] I've hear that most Drill Instructors, if given a choice, prefer to train someone who has no experience shooting. That way there are no bad habits to unlearn and they can train them as an adult …

Member Avatar for hughv
0
277
Member Avatar for VernonDozier

This is part of a larger project. I've simplified it here. I am implementing a word search program where word puzzles are produced and displayed. There are two main panels. One is the word search panel where there are rows of letters that spell words in different directions. The user …

Member Avatar for VernonDozier
0
5K
Member Avatar for CTOBiz

[QUOTE=CTOBiz;732933]Friends, First off, I'd like to thank each one of you for setting up such a fantastic supporting network to help each other. Here's what I want to do and I think this is feasible but haven't done it myself as my focus can been more architecting web and DW …

Member Avatar for ArkM
0
129
Member Avatar for stunt_man33

> Hi, im having some problem while doing my assignment, > i cant make my recursive function to loop as to get each digit from the number generated randomly. > int random (int num) > { > > srand (time (NULL)); > num = rand(); > cout << num << …

Member Avatar for Denniz
0
91
Member Avatar for VernonDozier

I have an applet that is not initializing: [code=JAVA] import javax.swing.*; public class WordSearchApplet extends JApplet { public WordSearchApplet (int width, int height) { } public void init () { new WordSearchApplet (700, 800); } } [/code] Here is the error I get. [quote] load: WordSearchApplet can't be instantiated. java.lang.InstantiationException: …

Member Avatar for VernonDozier
0
107
Member Avatar for jagr200

We can't do it all for you and send you the solution for money. It's not that kind of forum. I doubt you are going to be able to get it done in seven hours if you have no idea of how to do it. Here's a skeleton that could …

Member Avatar for VernonDozier
0
150

The End.