64,152 Solved Topics
Remove Filter ![]() | |
Hi, I'm about to start making some little program with input of type string which'll later be converted into numbers, but it has to pass the check is there any non-digit character. Considering I was lazy to search for functions like that I decided to make my own header for … | |
Hello everyone. I have a problem using strtok in C. I get a user input from the command line and I want to tokenize it with pipe ("|") as the delimeter and put the result in a double pointer variable. Here's my code: [CODE]char** argv; char *token; token = strtok(userInput, … | |
My assignment is to write a program that outputs the following columns of numbers using mathematical operators and the loop index. This is what I want the program to output: [CODE]1 10 0 1 1 0 2 20 1 4 2 0 3 30 2 9 3 0 4 40 … | |
i have one list and one database. The list is made after i've decided a number in a numbericUpDown. So for an example i can get the list fj1Section: 1 34 33 32 31 20 19 18 17 16 each of this sections exists in the database in the 2. … | |
Hello. I trying to solve this problem. The user inputs 4 numbers to each array (they are 2). I must output the common elements. So this is the problem i'm stucking with . Let's say p = 1,2,2,3 p1 = 3,5,1,2 the output is 2 1 3 1 2 but … | |
[CODE]#include<conio.h> #include<string.h> //prototype declaration int pnc1(FILE *fp); int pnc2(FILE *fp); int findstr(char *p[], char *name); int sum_array(int a[][], int element); //function to pick data and then convert bits to number // for notes_disp , notes_req int pnc1(FILE *fp) { int tot=i=j=k=0; i=getw(fp); j=getw(fp); k=getw(fp); tot=(100 * i) + (10 * … | |
![]() | Hi, New to wordpress and php so please bear with me. I am using WAMP as a testing server and Dreamweaver CS5 as a text-editor to manipulate the theme files. I have successfully set up a live local connection between WAMP, WP and DW and can view the live index.php … ![]() |
Probably a stupid question but why does the following loop works ? There is nothing wrong with it I just want to understand how does this code know how many entries I have in database. [CODE=PHP] $result = mysql_query("SELECT * FROM post_categories"); while ($row = mysql_fetch_array($result)){ echo $row['Name']; } [/CODE] … | |
short story short, I've got data file which looks like this: [CODE] PrekÄ—s pavadinimas Atvežimo data Pardavimo data Kiekis Kaina --------------------------------------------------------------------------------- Juodos vilnojinÄ—s kojinÄ—s 2011 10 28 2011 10 28 5 6.79 Smulkus cukrus 2011 11 19 2011 10 28 15 3.66 Pigus Batonas 2011 11 23 2011 10 28 … | |
Hello, I managed starting a session and store some data when a user login to the system. The user can edit his/her prifile by clicking on edit, then some of the data will show in the edit form. Now I have the form with empty fields and I need to … | |
I need a function that returns True or False if an integer n is a prime. Any 'high speed' thoughts? | |
I'm doing a program that is supposed to reverse a string entered my the user using a recursive function, I almost have it solved except for one little elusive bug that I can not understand. [CODE] //****************************************************************************** //Programer: Kyle Willett //Course: CS-1513 //Program: 3 exercise 7 page 933. //Purpose: Reverse … | |
Hello, I'm trying to write a script which is listing files based on different preferences, like filetype or permissions. All is fine, except for one: I want to list files in /home which has a different owner than the home directory it is in. Here is an example: /home/UserA is … | |
So wrote this code all in main and it worked then tried to put it into function, per assignment, and i'm getting three errors both in the last function where I call the previous functions to print. [CODE]#include <iostream> #include <fstream> #include <iomanip> #include <string> using namespace std; ifstream infile; … | |
My boss asked me to write a PID class to control a motor today. No big deal, except that the deadline is tommorow evening. My calculus is rusty, and my vb6 is probably worse (which is the language I am to use). Anyone have a good understanding of a PID … | |
[ICODE] org 0100h mov dx, msg mov ah, 09h int 21h mov ah, 4ch int 21h msg db 'Hello Wold! \nThis is my first program using Assembly', '$'[/ICODE] Hi guys, I'm learning Assembly Programming using NASM and had a question. Would it be possible to break lines in Assembly? Say … | |
Hello all, The program I am working on is calculation of areas (of shapes). For example, for triangle area calcuation I have: [CODE] else if (character == 't') { double b,h; cout << "Enter base: "; cin >> b; cout << "Enter height: "; cin >> h; area= h * … | |
I am working on an application in which I select a color from a color selection dialog and click on a graphic shape to change its color. Everything is working fine, but now I would like to change the default arrow-shaped cursor to an eyedropper shape when I am in … | |
I have an [URL="http://pantheonarts.host22.com/xml/feed.xml"]RSS feed[/URL] set up using XML on the website I've developed for [URL="http://pantheonarts.host22.com/"]Pantheon Arts Unlimited[/URL]. I'm still fairly new to PHP and MySQL, so I find myself often jumping to various forums looking for answers for what are usually fairly obvious questions. My newest problem, however, I've … | |
My Java instructor yesterday gave us a sample test. One line that surprised me was something like [B] if ( m2++ < 10 ) { ………[/B] iow the first thing done is , in effect m2 = m2 + 1, an ASSIGNMENT. Whether the instructor ever actually discussed this in … | |
I have been asked to create to check if a word is palindrome or not. But I am facing some problems. After the code you can see the messages that I received from the compiler. [CODE] import java.util.*; public class Palindrome { public static void main(String[] args) { [B]Stack<String> stack … | |
May i know how to matching 2 array keywords? e.g I have 1st array keyword like kfc,mcd,fastfood,etc 2st array keyword like kfc,mcd If i want to get the matching keywords among these 2 arrays, how to i write the matching code? Thank advance for your help. | |
Hi, I am facing OutOfMemory exception in Java, Kindly help me to resolve this issue, really appreciate your help [U][B]ERROR: [/B][/U]java.lang.OutOfMemoryError: Java heap space [B][U]CODE:[/U][/B] [CODE] public Blob getBlob(String databaseInstance, InputStream inputStream) throws SQLException, Exception { applog.info("Entering getBlob"); InputStream stream = null; applog.info("inputStream : " + inputStream); stream = inputStream; … | |
im creating a custom button . when user select a image file for button image i want to add it to the project resource (in design time) . how to do this?? im currently drawing image using image location but its not a good solution. | |
Hey guys. I'm trying to create a program which adds, searches & removes items from an array & i've been messing around with the code, trying to find answers on the internet but so far no dice. Could any of you help out? [CODE] void removeString(List& s, string strKey, const … | |
hi all, I have script that sums all textboxes value from dynamically added row, but still i have problem with the script. below listed two version of script [CODE]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title></title> <script type="text/javascript"> /*<![CDATA[*/ function addRow() { // grab … | |
Hey i have no idea whats goin wrong with this i think its to do with the fact that its in private but i have an error with calling weapon in the monster class (Monster.cpp) the error states that it is inaccessable :S here is my code: [CODE] //Monster.h #ifndef … | |
Hi, I am wondering if it is possible to "transfer" a Socket connection to another ServerSocket? So, say I listen for a connection on ServerSocket with port 1111. A connection is established, I know want to use a ServerSocket with port 2222 to handle this connection. Is he possible without … | |
Hey there, I am trying to build a small survey for a homework assignment. So, I have the following code: [CODE] $con = mysql_connect("localhost","user", "mypassword"); if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("mydatabase", $con); $slq = "INSERT INTO results VALUES('', '', '', '', '', '', '', '', … | |
Hey Im currently working on a application server written in Java but to use information from a C++ program. The company seems to agree that rewriting thousands of lines of code would be time consuming and simply making libraries of key functions of the C++ program and then passing them … | |
Hi guys I am trying to declare a array within a structure, and it is not working. I'll paste the code below and if anyone can help it would be greatly appreciated. [CODE]Structure league Dim id As String Dim name As String Dim players(20) As String End Structure Dim leagues(100) … | |
Hey guys, I am to do a final year project to monitor the trading floor of the Nigerian Stock Exchange and my question is if I were to write an application what things should I consider. The application is supposed to be a stand alone but works when it connects … | |
I need to pass some parameters to button_click is that possible and if so how can I do it?? | |
Hi all, I have taken slide show script from net. But There some functions i cannot understand here is script [CODE]<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd" > <html lang="en"> <head> <title></title> <script> var interval = 1500; var random_display = 0; var imageDir = "my_images/"; var imageNum = 0; imageArray … | |
I need a help to understand what condition can be applied to the below requirement: If suppose we have 2 species name eg. dog and cat... and we have few breed name for the above mentioned species.... so what condition can be applied in such a way that the user … | |
hi everyone I'm new to c# and working with file currently I need to read some string from the file but not the whole file so what functions can I use to read the file string by string ? | |
Hello, Am not new to PHP but new to OOP, I have watched lot of tutorials for oop and as I saw, class is almost a new language!! To be a pro programmer, I should learn existing class attributes or I should create my own?? example of default class attribute: … | |
![]() | Soo last year, if im not mistaken , i asked for help with the random numbers generator. I didn't do C++ for quite some time, but i started again. So here is what i have : [CODE]#include "stdafx.h" #include <iostream> #include <fstream> #include <ctime> using namespace std; int main(){ srand(time(NULL)); … ![]() |
I'm having problem with my login php files. I don't know if it is in the passing of values from inputboxes or connection with my database records. log-in code: [CODE] <td align="right" width="130px"> Username: </td> <td><input type="text" size="40" id="username" class="inputbox" /></td> </tr> <tr> <td align="right"> Password: </td> <td><input type="password" size="40" … | |
I can't figure out what is wrong since my codes are correct. [CODE] $host="localhost"; $username=""; $password=""; $db_name="database"; $tbl_name="members"; mysql_connect("$host", "$username", "$password")or die("cannot connect"); mysql_select_db("$db_name")or die("Cannot Find Database"); [/CODE] Keeps on saying the die statement. I'm using WAMP, and yes. my database name is "database" and table is name is "member". … | |
Hey guys! I have limited experience with Visual Studio and have a question about Querying an Access database. I have created a Visual Studio application that displays and modifies an access database. I have use datagridview and detailed view to insert data and view data in the Access database. I … | |
[CODE]int numdigits(int num){ int len = 0; while(num >= 10){ num = num/10; len++; } return len; } [/CODE] This algorithm is used to count the number of digits but I can't understand it. Someone explain it to me please :D Thanks ![]() | |
hi guys, sorry to disturb but I'm looking for the instructor's manual to 'C by a modern approach' written by KN king. | |
is there a warior i can do the following: lets say i have [CODE]string userChoice;[/CODE] assume i have a Warrior class with move function in it is it possible to define : [CODE]#define WARRIOR "Warrior"[/CODE] and than use [CODE]userChoice=WARRIOR;[/CODE] and call the function [CODE]userChoice.move()[/CODE]? [CODE]void play(char gameWorld[][BOARD_SIZE]) { Warrior War(1,1); … | |
Hello everyone I am trying to code an address book in C#, the program should be a console application and should stores names address etc in a string. The menu should loop and continue wish I have done using a do loop, at the moment I am stuck on the … | |
Good Morning All, I am doing a membership site for a client and would like to use SSl, but know absolutely nothing about it... My primary concern is whether there are any specific programming differences required in my scripts to accommodate the https as opposed to http? I use about … | |
Hi everyone :) Title says it all... I'm trying to bind events to a wx.GenericDirCtrl. I've visited more than 20 web sites but i haven't found how to do it. I've tried different manners but it doesn't work as i expect it to. In some case my control is seen … | |
Can Anyone advise me on the problem with the namespace in this code im getting an error. [CODE]//Main. #include "Weapon.h" #include "Room.h" #include <iostream> #include <fstream> using namespace std; int main() { ifstream myfile; string line; myfile.open("BronzeSword.txt"); if (myfile.is_open()) { while ( myfile.good() ) { getline (myfile,line); cout << line … | |
i used to create sub procedures in vb6 under tools/ add procedure. Same is not available in vb2008. how can i create sub procedure in form. for eg. Private Sub CmdDisabl() Cmd_New.Enabled = False Cmd_Amend.Enabled = False End sub if i type above code in form i get error statement … |
The End.