64,152 Solved Topics
Remove Filter ![]() | |
would the workings of strlen() be something like this? [code=c++] int strlen(const char * str) { int size = 0; while (!!*str) size++; return size; } [/code] any feedback would be appreciated. also i have learned that !! will convert a value to an actual bool eg. !!104 = 1 | |
Hi, so in essence I have two little scripts: a server side script and a client side script. My client script sends a request to the server, and the server sends a string to the client. Once I get the string back into the client, I set it to the … | |
![]() | Hi guys, as per title above, im at my wits end after a week of thoughts.... i want to download a file from a SSL web to my local(C:\) e.g [url]https://www.abc.com/File/myfile.txt[/url] Scenario: from the web browser(Internet Explorer), i required to login to the site in order to download the file. … ![]() |
//I am trying to use the reverse function but only get garbage when trying to print s2. How do I properly assign s2 a value in order to print it in main? #include <iostream> #include <string> using namespace std; class ch_stack { public: void reset() { top = EMPTY; } … | |
[QUOTE]Hi all I have two forms which are being displayed from the MDI Parent form. In the following code I would like to send data from form 1 to form 2. [/QUOTE] [CODE] DsgnForm.InsertOE = txtOrderEntry.Text DsgnForm.InsertFN = txtFirstName.Text DsgnForm.InsertLN = txtLastName.Text DsgnForm.InsertAD = TxtAddress.Text [/CODE] [QUOTE] My problem is … | |
I have a homework assignment that's due in a couple of days and I need a set of experienced Java eyes to confirm that a few of the answers to the questions below are correct. The hard part about these questions (for me anyways as a newbie Java person) is … | |
I'm new to Java and can't seem to understand why this code doesn't work. Any input would be appreciated. Thx. [code]Public class MyClass int a; float b = 1.5; public void static main(String args) { MyClass mc = MyClass(); mc.a = 1.5; system.out.println(b); }[/code] | |
[CODE]current = queues[i];[/CODE] This line of code is killing me. I am suppose to be doing a write method for an array based priority queue. However I cant seem to get the first node on the give part of the array. queues is of the Queue class which is a … | |
Trying to learn recursion. Problem asks to use recursion on non-negative number to insert commas. Ex: 20131 as 20,131. My program adds in an extra comma at end. Any help in pushing me in the correct direction to fix this would be appreciated. Tried to use a 'count' to determine … | |
My problem is I want to be able to read through this xml document and populate a winform before validating it and then storing it into a table. This is a snippet of the xml document, it's way too big to put it all here. [code=xml] - <Applicant> + <common:PersonName> … | |
HOMEWORK HELP - Just so i stick by the rules. The second part of my assignment is to create an array object, and love and behold, im having problems passing my small array into the function. Bellow is my code of what i have done so far, the solution seems … | |
[CODE]#include <iostream.h> float salary (int, float); int main() { int n,h,i; float r,GS; cout <<"Enter number of employees: "; cin >> n; for (i=0;i<n;i++) { cout << "\n Hours= \t"; cin >>h; cout<< "\n Rate= \t"; cin >> r; GS=salary(h,r); cout << "\nSalary=\t"<<GS << "\n"; cout << "Rate=\t"<<r<<"\n\n"; } return … | |
Hi all. I'm having an issue that I CAN NOT figure out for the life of me. The program is to get user input about there paycheck , then calculate the answer. What my problem is I can not get the php part to print anything inside the <?php?> tags. … | |
Hay I'm just spent hours on google and other sites, can't find any help. I just wrote my 1st major application and now I want to make it installable. Is there components I can download or built in that I can use to do this? | |
A couple things to mention: 1.) This program uses system("PAUSE"); in the main function, if you are not using Windows, you might have to pull it. 2.) There are a couple lines in there that are not needed, I'm just using them to test the size of the array. My … | |
I`m trying to use sets and gets for a code, but it`s not compiling I`m not sure how to set and get a String, this is what I have so far this is class Car [CODE] String color; void setColor(String col) { color = col; } String getColor() { return … | |
Hi :) I am certain of when to use static_cast, but often I can get satisfactory results by writing the target type in a parenthesis. For example: [CODE]void* data = somePointer; SomeClass* new_ptr = static_cast<SomeClass*>(data);[/CODE] seems to work when replaced with [CODE]void* data = somePointer; SomeClass* new_ptr = (SomeClass*) data;[/CODE] … | |
![]() | Hi again folks. I have a PHP member registration script that collects registration details from the user, encodes the password (with RIJNDAEL_256) and emails the user a URL containing all the variables so I can verify the email address is correct. The user clicks on the URL, the correct page … ![]() |
Hello everyone, I have a problem with my drop down list box on my edit page in php. I would like my drop down list box to show what the user has selected, then if the user wishes to, change their selection updating the DB(mysql) at the same time. I … | |
I have changed the Path Environment Variable for Windows Command Prompt to: C:\j2sdk1.4.2_04\bin so why, when I try to run javac while in the code folder directory, do I still get the error message "javac is not recognized as an internal..." I was forced to put the path info in … | |
How do I get rid of the zero digit in this program? this is a factorial problem and I have to show the numbers to be multiplied before arriving to the answer. The problem is, in the iteration process, the number zero will show. How do I get rid of … | |
How to Save Web Pages in WebBrowser1 using VB6? It's not about saving the source code to text file.. It's the same as clicking [B]File > Save Page As...[/B] in Firefox. :) | |
Hey all, I am currently creating a program that is like an automated food ordering menu. Imagine a form that has two listboxes (or listviews), the first listbox contains the items that can be ordered, I stored these items into an array and displayed them using a for loop construct … | |
Hi! This is for a homework assignment, and I'm trying to do cascaded deletions on tables that refer to each other. [B] Homework question:[/B] Give an example instance of C and D, having at least 4 tuples in each of C and D, such that a deletion of a single … | |
I have a multi form... I searched online and found this link... [url]http://www.html-form-guide.com/php-form/php-order-form.html[/url] so i was doing a test, but it didnt work for me.. Can some1 help me, where i have gone wrong. Here are my codes.... [COLOR="red"][U]Form1.php[/U][/COLOR] [CODE] <?php session_start(); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" … | |
i have a main java code called home.java which is an interface. when i press button BTNSTART , i want d progm WebCam.java to exxecute. but it's giving me an error saying : [B]ERROR[/B]: home.java:146: cannot find symbol symbol (constructor WebCam()) the code home.java : [CODE] import javax.swing.*; import java.awt.*; … | |
I am writing a program for class that I keep getting a segmentation fault on. I am fairly certain that it has to do with the assignment of the 'string location.' Could anyone possibly give me a hint as to what I'm doing wrong? I'm very new to this, I've … | |
Do any of you guys know if Winsock is a popular API that is used for companies hiring programmers? Thanks | |
Hi, I seem to be getting myself into a lot of segmentation fault errors lately. The that currently has me stuck is one that shows up after I exit my program (an SDL App). When I need to debug I usually use the debugger or a Logger class I found … | |
ok so i am taking a list of numbers and stashing them i an array by going $total[]. then i try to use array_sum($total) and i dont get the last added number instead i get numbers that keep adding up to the final number EX: 10,15,5 output: 102530 i have … | |
I am trying to start the odometer reading at 0 to start with, but I want it to increase everytime the user inputs MilesDriven. I can't seem to get it to work...any ideas? [code] //Paul Baker //TRCC Intermediate C++ //Assignment 3, Odometer #include <iostream> using namespace std; class Odometer { … | |
[code] #include <iostream> using namespace std; class A { private: int a; }; A::A() { a = 10; } int main() { A obj1; cin.ignore(); cin.get(); } [/code] It is giving me the error Error 1 error C2600: 'A::A' : cannot define a compiler-generated special member function (must be declared … | |
I am creating a C program to work with environment variables and I am having some problems. I have three choices to input from the command line: a.exe, a.exe <environment_variable_name>, or a.exe -a. The 'a.exe -a' should display a list containing all environment variable names and assigned values, with one … | |
Hiya. I'm a complete C++ noob. I'm trying to make a bingo game where the computer gives the user eight numbers and the user slowly plays a game of bingo. It's very much work in progress. However, I'm having a problem when trying to compile it, the program seems to … | |
Hi! I am trying to make an element shake, and I have [I]tried[/I] to make a function in JavaScript, but it won't work. Here is the test page, used only for testing. It is the [I]Genious test[/I] div that I want to shake. Here is the code: [CODE] function Shake(Pow){ … | |
hey guys im working on a homework problem..im done with 99% of the problem :|however i cnt figure out how to display my output(which is in dollars) using the comma my output shows >>160000 how would i make it >>160,000 um should i use setprecision??? please help thanks:) | |
hello can you help me how to use the code tags so that i can post all my code and not to be banned.. [CODE][/CODE] where i put my code inside this bracket or in the middle of this two bracket? i have 3 points more to go..hoping for your … | |
Hi, Ive posted this in a mysql forum, but the more i think about it i think php is really where i think the solution lies. When i call a row, how could i count the number of empty entries? so say its an address with 5 lines, and ive … | |
Hi I am a J2ME developer I am new to Dani Web. I am using chartapi.finance.yahoo.com to calculate and display chart. My questions is how to convert TIMESTAMP value to a Java Date or Calendar Object ?..... For Eg: URL GIVEN BELOW [URL="http://chartapi.finance.yahoo.com/instrument/1.0/aapl/chartdata;type=quote;range=1d/csv/"]http://chartapi.finance.yahoo.com/instrument/1.0/aapl/chartdata;type=quote;range=1d/csv/[/URL] Its output will be uri:/instrument/1.0/aapl/chartdata;type=quote;range=1d/csv/ ticker:aapl unit:MIN … | |
Hi folks, First a bit of context (Errors are shown at the bottom of the post): I am creating an object viewer for opengl in Visual C++ 2008 Express Edition. I have written a parser which reads the file and stores all the info I want in a Mesh object. … | |
Hello!... Can anyone help me on this project? I already have created a simple program called Website manager and ive already release it on my website [URL="http://www.silentproject.tk"]http://www.silentproject.tk[/URL] i want to improve it by adding an Auto login feature for websites like yahoo mail..etc.. does anyone of you know how to … | |
hello please help me on this how to make the log in password in gui that can accept at least 6 characters and not more than 10 characters..and if i will re enter the password and it will prompt to the user that password is already exist..hoping for your positive … | |
Sir, Please anybody help me My another question is in txtlani textbox I have to enter only digit i.e. 0 to 9 and currency formate i.e. 1,000.00 and 1,00,000.00 it is possible in text box. and another text box which I have to enter only date i.e. at run time … | |
i want to convert string into hexdecimal value.. Like 'Hi' into 00680069 [code=php]<?php function ascii2hex($ascii) { $hex = ''; for ($i = 0; $i < strlen($ascii); $i++) { $byte = strtoupper(dechex(ord($ascii{$i}))); $byte = str_repeat('0', 2 - strlen($byte)).$byte; $hex.=$byte." "; } return $hex; } //echo ascii2hex('he'); echo dechex(ord('hello')); ?>[/code] I got … | |
Hello People, I cannot understand how this expression gets evaluated .. 1+~0 From what I know ~ has higher priority . So the expression becomes 1+(~0)= 2 But the answer that I got was 0. I know it is some thing to do with the fact that ~ is right … | |
I'm having trouble combining tkinter windows/functions, i have simplified my problem down to this which i think seems to be the problem. Both these functions will work on their own, but not together. (at least the way i want them to!) What I am after is to be able to … | |
Basically I am totally confused on how to pass a char, which is given by the user, and then store it and pass it to another function by reference. | |
i have a webpage wherein it has two frames in it. now, i want to transfer the data coming from FRAME A to FRAME B. now, i thought of using a session, but it does not work, what i want is that when i click the button in FRAME A, … | |
[CODE] int main() { char c1, c2; printf("Enter a character: "); scanf("%c", &c1); printf("Enter another character: "); scanf("%c", &c2); system("pause"); return; } [/CODE] Thats what my code looks like, the problem is the code skips the part where it lets you input c2. I dont understand why its doing this. … | |
Hello, How can I disable beep sound in KeyDown event? I already tried using "e.Handler = true" but it doesn't seem to work. I have used it sucessfuly with KeyPress events, but now with KeyDown I can't get it work... This is my code: [CODE] private void msg_textbox_KeyDown(object sender, KeyEventArgs … |
The End.