64,152 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for Thinka

Hello again people, I've got some questions about timing that I hope can be answered by someone. I'm trying to use the functions [I]getrusage[/I] or [I]times[/I], or the [I]time[/I] command to time my programs. Now I've got this piece of code that uses getrusage, and my first question is a …

Member Avatar for Narue
0
1K
Member Avatar for mithesh

hi i have inserted the date value into the database but its showing as 0000-00-00 why like this can anybody help me whats the correct format to insert date from a drop down list to the database ; heres my code to handle this : <?php include("dmy.php"); echo "<Html><Head></Head>"; $setdate …

Member Avatar for stymiee
0
346
Member Avatar for ptaylor965

I have a SQL table with a list of forms (frmForm1, frmForm2) i have a listbox that fills from this table and i would like it to call the form in the 'FormToCall' Column How can i call a form if i only know the form name at runtime?

Member Avatar for ptaylor965
0
132
Member Avatar for erlkz

i'am newbie on using Tkinter, and i need help for my application i make application small calculator, but i can't make it just like standard calculator on MS Windows please Help me i wan't my application calculator like this :

Member Avatar for vegaseat
0
93
Member Avatar for machine

Hi im using switch to access some member functions through object [U]s1[/U] of that class [code]switch(choice) { case 1: s1.Now(); break; case 2: s1.create(); break; case 3: s1.display(); break; case 4: s1.change(); break;}[/code] Is there a way to change/use only a part of a function? For example for case 2 …

Member Avatar for machine
0
79
Member Avatar for Teresa_Hall

Hi all - First time posting so please bear with me. I'm in the last week of a C++ class and cannot figure out how to do this assignment. I need to evaluate each character of a string and process using a switch statement. The CASE processing I have no …

Member Avatar for Narue
0
238
Member Avatar for dudegio

Hello guys! I am editing a program regarding billing system done in Php and MySQL and generated using the Code Charge Studio. I have problem in validating a newly entered data. What i want is to check if the billing statement number is existing or not and will not saved …

Member Avatar for dudegio
0
100
Member Avatar for lotsofsloths

Ok, say im using the cmd prompt version of MSVC++(or the windows app type), how do i post a project on daniweb, HTML, or any other website(or like a quick luanch desktop icon)?

Member Avatar for ~s.o.s~
0
325
Member Avatar for sadaka

Hello you guys. I'm very excited since I'm so close to finishing my project. However before I'm totally done I am kind of stuck on this error message when compiling. It says "[COLOR=red]cannot find -lobjc[/COLOR]." Have anyone seen this before? [U]What does it mean?[/U] I've added my entire code if …

Member Avatar for Ancient Dragon
0
143
Member Avatar for Prozeen

Hi all, I have 3 labels, with 3 captions (i.e. integers)... Label 1 = 1 Label 2 = 3 Label 3 = 2 What I want to do is search all these labels and find out what the highest number is (in this situation it's 3) so that I can …

Member Avatar for Prozeen
0
442
Member Avatar for bops

Basically I'm writing a function to change all the '|' characters in a string passed as a parameter to '\n' characters. Seems simple enough to do, but I get one of those "Application has encountered a problem and needs to close. We are sorry for the inconvenience." messages. [code=c] char …

Member Avatar for Narue
0
118
Member Avatar for dotcom123
Member Avatar for alex905

well here is the part of my script that is malfuctioning. [CODE]require "config2.php"; require "config.php"; $result = mysql_query( "SELECT `sum` FROM `subs`" ); $sq = mysql_fetch_assoc($result); $value = $sq['sum']; $val = preg_replace('/$/', '', $value); ?> <br> <?php echo $val; $query = mysql_query( "SELECT title, threadid FROM `thread` WHERE forumid = …

Member Avatar for coolkartik
0
133
Member Avatar for ruhi

hello everyone, how to write exit code in visual studio.Net so that whole program closes on button click event? And how Message box is created, also how to take input from user as we do in javascript using prompt command? Can anyone help me in this..... Thanx in advance.

Member Avatar for ruhi
0
175
Member Avatar for sk8ndestroy14

This is just a simple question. There are four command buttons in a control array. I want to write code for one of them that changes the same property in the same way for all of them. When I tried doing this with just a specific button (I entered the …

Member Avatar for DenisOxon
0
162
Member Avatar for hbweb500

So Im trying to write some code that takes a chunk of text, splits it up into words, then puts these words into an array. What I have is: [code] string buf; stringstream ss(database); // database is my chunk of text while (ss >> buf) // Tokenize when whitespace met …

Member Avatar for hbweb500
0
254
Member Avatar for hinduengg

Could you please give some info regarding - What are basically linked lists . I know that they can be used as arrays and stacks and queues. But confused a bit about FIFO and LIFO CONCEPTS. I cant understand how do we always access the stack from top.It is just …

Member Avatar for hinduengg
0
114
Member Avatar for fernando22

ok i have a problem, like you can see in the code i already create a bidimesional array step by step..... ok i want to eliminate that, and instead of that i want to load the array from a .txt like this> 0-0-6-0-0-0-6-0-0-0 0-0-8-4-0-0-0-0-0-0 6-8-0-0-0-0-0-0-0-0 0-4-0-0-2-0-0-0-0-0 0-0-0-2-0-4-0-0-0-0 0-0-0-0-4-0-0-1-0-0 6-0-0-0-0-0-0-0-0-5 0-0-0-0-0-1-0-0-7-0 …

Member Avatar for fernando22
0
189
Member Avatar for olufunkky

Please I need help with this program. I tried different approach, but doesn't seem to be getting no where. [B]QUESTION:[/B] [B]You've been going to work on a database project at work for sometime now. Your boss encourages you to program the database in Python. You disagree, arguing that Python is …

Member Avatar for olufunkky
0
152
Member Avatar for JRM

Here is a snippet from an example on C++.com. They use what looks like a do loop. I tried putting it into their search, but nothing came back for "do". As far as I can tell it forces the loop intially, otherwise the while statement would cause it drop through …

Member Avatar for JRM
0
116
Member Avatar for whoost

hi i'm not really sure if this is the right place to post this, but i was wondering how you go about compiling programs from source for windows XP. i've heard vaguely about a program called Cygwin, but am not sure if i should download it or not. i'd download …

Member Avatar for whoost
0
129
Member Avatar for doraemon

What is the difference between "\n" and '\n'.? Also what is the difference between " " and ' '??

Member Avatar for doraemon
0
86
Member Avatar for Lardmeister

I would like to reverse a sentence. I have this: [code=python]sentence = "a doctor kills your ills with pills and you with bills" print sentence[::-1] # sllib htiw uoy dna sllip htiw slli ruoy sllik rotcod a [/code]However, I would like the sentence reversed like this: bills with you and …

Member Avatar for vegaseat
0
1K
Member Avatar for hinduengg

HELLO THIS IS MY FIRST POST. I WISHED IF ANY ONE COULD HELP IN EXTRACTING WORDS FROM A CHAR ARRAY -STRING LIKE IF THE SENTENCE INPUTTED BY USER - [B]JACK WENT UP [/B] THEN I NEED TO PRINT THESE WORDS SEPARATELY ON FRESH LINES OUTPUT- JACK WENT UP [B] I …

Member Avatar for Narue
0
3K
Member Avatar for phalaris_trip

Why does this not work, and are there other alternatives? This will eventually be used in a loop of sorts.. the different fileName's will be determined by the program in real time.. [code=cplusplus] #include <fstream> #include <iostream> int main (int argc, char** argv) { std::string fileName; fileName = "testFile.txt"; // …

Member Avatar for ~s.o.s~
0
197
Member Avatar for Covinus

ive been trying to connect my c program and a postgre database using VC++. but i cant compile it because it cant find "postgres_fe.h". and also i cant find any tutorials about this one too. When i searched google, most are for linux. if anyone here knows some links to …

Member Avatar for ~s.o.s~
0
144
Member Avatar for tformed

I am to create a program in which the user puts in a word and the program displays the definition. The words are 20 words I select. I have a comon idea on how to achieve this, but I never scaned for text before. I know char is for a …

Member Avatar for tformed
0
135
Member Avatar for wwillow

This is my first visual basic 5 project and it's for work not a school assignment. Any help is appreciated. I'm displaying lines from a file in a listbox and I'm highlighting each line according to a timer. I don't want any user clicking in the listbox, but when I …

Member Avatar for wwillow
0
113
Member Avatar for Matt Tacular

Can someone look at this and tell me if it actually is doing what it's supposed to. [php]from __future__ import division counter = 1 while True: li = [] for i in range(1,(counter+1)): if (counter/i) % 1 == 0: li.append(i) if len(li) <= 2: print counter,"is a prime." counter = …

Member Avatar for vegaseat
0
288
Member Avatar for anud18

hi.......can anyone tell me how do i call a subroutine created inside my dll from another project example:- i hv created a dll having a sub-routine named "initialize" in it .....when i call this sub-routine from my project after having made all the necessary declarations its giving me an error …

Member Avatar for QVeen72
0
152
Member Avatar for meiyantao

Hi,sir.I encounterred a person who said that C++ is an unsafe language.I try the follow code ,but when I input an non-int type,the program will fall in a bad loop.(gcc4.1 in Linux) [CODE] #include <iostream> #include <string> using namespace std; class bot { private: int password; public: bot():password(567){} virtual ~bot(){}; …

Member Avatar for Narue
0
251
Member Avatar for alembic21

Hello, I have generated a group of random numbers but I can not figure out how to display the numbers in groups of 4. Any suggestions? [CODE]srand ((unsigned int) time(NULL)); int i, high, low, number; high = 47; low = 19; for (i=0; i<20; i++) { number = rand() % …

Member Avatar for alembic21
0
126
Member Avatar for Zorbie

I read somewhere about somebody importing the sys.py module. I can't find the bugger on my system! I have python 2.5.1 installed on this Waxows XP machine. I did a search for sys.py in the c:\python25 folder and sys.py isn't there! Isn't it supposed to be installed by default? If …

Member Avatar for StrikerX11
0
159
Member Avatar for nalinibh

Hi everybody, Can anyone among you let me know.how can i find execution time of an algorithm in my c coding!! thanks Nalini

Member Avatar for Ancient Dragon
0
111
Member Avatar for sadaka

I have been stuck on this one problem for sometime now and I have tried looking this up in all my references but was not able to come up with a solution to this error. Can someone help me with it please. My gratitude to you in a thousand years …

Member Avatar for sadaka
0
167
Member Avatar for msi_333

This a problem i faced .When i made applet the access file i faced the following exception: [INLINECODE]java.security.AccessControlException: access denied (java.io.FilePermission text.txt read) at java.security.AccessControlContext.checkPermission(Unknown Source) at java.security.AccessController.checkPermission(Unknown Source) at java.lang.SecurityManager.checkPermission(Unknown Source) at java.lang.SecurityManager.checkRead(Unknown Source) at java.io.FileInputStream.<init>(Unknown Source) at java.io.FileInputStream.<init>(Unknown Source) at java.io.FileReader.<init>(Unknown Source) at CheckTopScore.<init>(CheckTopScore.java:30) at MainFrame.<init>(MainFrame.java:200) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native …

Member Avatar for msi_333
0
183
Member Avatar for bala24

Hi, I was just browsing through some stuff about Initialization lists in C++ and got stuck with a doubt.. Why is it necessary to use initialization lists while giving a value to constants or references ?? Why is it not possible to do so in the normal way..i.e initializing them …

Member Avatar for ~s.o.s~
0
116
Member Avatar for le0pard13

Situation: I have a working shell script on our file server (OSXS Tiger) to connect to a workstation, which is using a portable home directory (phd), and rsync a user's MirrorAgent.log. I'm not that strong of a scripter, but I would like to add other workstations to this script as …

Member Avatar for le0pard13
0
153
Member Avatar for Es Sayen

Hello, I am developing an application in Visual Basic in which i have to enter the details of candidates and after that clicking on the print button, the details of that particular candidate get printed out without using/going to a report. I want to know how can i do that, …

Member Avatar for Es Sayen
0
167
Member Avatar for stanats

i'm having this problem and i would like to ask for some ideas on how i will read a file backwards, that is, from end, read the file backwards(forward, naturally) by line.. thanks

Member Avatar for echobase
0
2K
Member Avatar for tcyge

[code]class abc { public: virtual ~abc() {} static void operator delete(void*); }; int main(int argc, char *argv[]) { abc _a; return 0; } [/code]

Member Avatar for vijayan121
0
77
Member Avatar for tunday

I am relatively new to Borland 2006 C++ Builder. I have a form which has about 6 buttons and a text box for selecting and inputting values respectively (e.g. Clicking on Button 1 should return "100" to a variable in the calling form. Likewise, entering 100 into the text box …

Member Avatar for tunday
0
182
Member Avatar for prajay.shetty

i designed the myevenreceiver class but i dont know how to animate a object sydney.md2 to make her move according to arrow keys plzz help me out i want only the main section plzzz help me out

Member Avatar for prajay.shetty
0
96
Member Avatar for Matt Tacular

In my program I have a loop with a variable that shows the players name, they choose something then it goes back to display their name and all it shows is arrows.... why? I'll post my code, run it and enter 3 or 4 players are playing, give them some …

Member Avatar for Matt Tacular
0
173
Member Avatar for Mr.Wobbles

[code] [COLOR=green]Private[/COLOR][COLOR=green]Sub[/COLOR][COLOR=green] BindingNavigatorDeleteItem_Click([/COLOR][COLOR=green]ByVal[/COLOR][COLOR=green] sender [/COLOR][COLOR=green]As[/COLOR][COLOR=green] System.Object, [/COLOR][COLOR=green]ByVal[/COLOR][COLOR=green] e [/COLOR][COLOR=green]As[/COLOR][COLOR=green] System.EventArgs) [/COLOR][COLOR=green]Handles[/COLOR][COLOR=green] BindingNavigatorDeleteItem.Click[/COLOR] [COLOR=green]Dim[/COLOR] rowDeleting [COLOR=green]As[/COLOR] portfolioDBDataSet.CRS_AccomplishRow rowDeleting = PortfolioDBDataSet.CRS_Accomplish.Rows(CRS_AccomplishBindingSource.Position) rowDeleting.Delete() [COLOR=green]Me[/COLOR].CRS_AccomplishTableAdapter.Update([COLOR=green]Me[/COLOR].PortfolioDBDataSet.CRS_Accomplish) [COLOR=green]End[/COLOR] [COLOR=green]Sub[/COLOR] [/code] this is the function I have, it shows no errors, but if I try to delete the first record it shows that it deletes all of …

Member Avatar for AV Manoharan
0
98
Member Avatar for ruhi

hello everyone, i m trying to add row in database through this code: [COLOR=green]Private[/COLOR][COLOR=green]Sub[/COLOR][COLOR=green] btnadd_Click([/COLOR][COLOR=green]ByVal[/COLOR][COLOR=green] sender [/COLOR][COLOR=green]As[/COLOR][COLOR=green] System.Object, [/COLOR][COLOR=green]ByVal[/COLOR][COLOR=green] e [/COLOR][COLOR=green]As[/COLOR][COLOR=green] System.EventArgs) [/COLOR][COLOR=green]Handles[/COLOR][COLOR=green] btnadd.Click[/COLOR] [COLOR=green]Dim[/COLOR] rowNew [COLOR=green]As[/COLOR] System.Data.DataRow = DataSet31.Tables(0).NewRow [COLOR=green]Dim[/COLOR] temp [COLOR=green]As[/COLOR] Random rowNew.Item(4) = temp Response.Write(rowNew.Item(4)) '** DataSet31.Tables(0).Rows.Add(rowNew) DataGrid1.EditItemIndex = DataGrid1.Items.Count DataGrid1.DataSource = DataSet31 DataGrid1.DataBind() [COLOR=green]End[/COLOR] [COLOR=green]Sub[/COLOR] [COLOR=green]but …

Member Avatar for ruhi
0
74
Member Avatar for pbrookee

Hello all...I am in a rut, confused. I have created an html/php web form it works fine, the user enters the info and submits it to a confirmation page and then when the user clicks ok I need for the information to be sent to 2 email address' one it …

Member Avatar for pbrookee
0
155
Member Avatar for Matt Tacular

I was wondering how I could access my several countryAttachedXX arrays(in this post they start on line 85), without many if statements, determined by user input. I was thinking maybe an array of arrays, but had difficulty finding out how to do that on the web. Thanks, -Matt [code=cplusplus]/**************************** * …

Member Avatar for Narue
0
86
Member Avatar for richie2021

[code] #include<stdio.h> #include<stdlib.h> int main() { struct { char origin[50]; char destination[50]; char flight[10]; char aircraft[3]; char days_of[7]; char departure[4]; char arrival[4]; char begin_date[10]; char end_date[10]; }flight_details[1679]; FILE *fp; fp=fopen("iaschedule-07(edit).csv","r"); char buf[50]; int i; while( fgets(buf,sizeof(buf),fp) != NULL) { strcpy(flight_details[i].origin, strtok(NULL,",")); strcpy(flight_details[i].destination, strtok(NULL,",")); strcpy(flight_details[i].flight, strtok(NULL,",")); strcpy(flight_details[i].aircraft, strtok(NULL,",")); strcpy(flight_details[i].days_of, strtok(NULL,",")); strcpy(flight_details[i].departure, …

Member Avatar for richie2021
0
127
Member Avatar for olufunkky

Please I need help with this question. I have been trying to solve it, was able to solve a part, but not completely through with it [B]QUESTION:[/B] [COLOR=green]Write a program that allows you to do the following five Operations:[/COLOR] [COLOR=green]a. [/COLOR][COLOR=green]Prompt the user to input a list of numbers (Hint: …

Member Avatar for olufunkky
0
259

The End.