199,114 Archived Topics

Remove Filter
Member Avatar for
Member Avatar for arsenal_fan

I am watching lectures on C++ from the stanford online courses website. I have a slight problem in understanding how memory is allocated for a string in C++. Basically when you declare a vector the constructor is called and memory is allocated for the array arr, numUsed and numAllocated are …

Member Avatar for arsenal_fan
0
170
Member Avatar for Web_Sailor

Hi gurus's :cool: I have got an actionListner in my code. The problem is that when I try to set my JLabel as true it does not work and does not show up in the GUI ? :@ [CODE]Button.addActionListener( new ActionListner(){ public void actionPerformed(ActionEvent e){ label.setVisible(true); myFunction() //here's some timeconsuming …

Member Avatar for Web_Sailor
0
3K
Member Avatar for dsrepublic

struct tnode { int data; struct tnode* left; struct tnode* right; }; struct tnode*talloc(int data) { struct tnode*p=(struct tnode*) malloc(sizeof(struct tnode)) if (p!=NULL) { p->data=data; p->next=NULL; p->right=NULL; } return p; } int main(){} I am getting a [error: 'NULL' undeclared] error, Any help would be greatly appreciated.

Member Avatar for gerard4143
0
89
Member Avatar for Hardz

I am using treeview with checkboxes in each node as shown below: +[]Main []Child1 []Child2 I have an indicator from form1 which is checkbox1 and checkbox2 that is uses to control the checkboxes of child1 and 2. If checkbox1 is true automatically child1 will be true, and if checkbox2 is …

Member Avatar for Hardz
0
358
Member Avatar for +_+man

hi everyone how to generate random codes given to the computer if i give three codes example : 123,234,567 i need to output anyone of these at a time

Member Avatar for daviddoria
0
100
Member Avatar for ahmadjhoney

Hello Great developers, i am working on an application, where i am trying to implement the multiple users chat, Basically the users send message to mobile and then get back the reply , then it shows like normal chatting. all everything is working and GREAT :icon_wink: But Except the multiple …

Member Avatar for diafol
0
143
Member Avatar for Archenemie

I have recently tried installing cherrypy to no avail, and it got me wondering, is there a way to build websites using the wxpython toolkit? if somebody knows the answer and could point me in the right direction it would be a massive help

Member Avatar for ryuurei
0
105
Member Avatar for vidyaputra

iam trying to install phpmydirectory to my localhost server (i have testing it using xampp and wamp)...but there is a problem; when iam using wamp, the installation of mhpmydirectory working just fine, but then i cannot login as administrator. If i check on mysql there is administrator username and password, …

Member Avatar for Ezzaral
0
202
Member Avatar for Tommymac501

Ok, back to differences between 2.x and 3.x... I have the following code to convert the sort key to a float: [CODE]def sort_key_func(row): return float(row[76][0:5]) [/CODE] which (under 2.x) returned the value of the field in the current row in position 76 for a lengthof 5. It was called like …

Member Avatar for Tommymac501
0
102
Member Avatar for omGac0W

So this is part of the code in one of my functions, and whenever I enter either yes, no, or something else, no matter what the response the do loop will loop again. I don't think my "if(response == "yes")" is working. Help please? :D [CODE] char response[10]; int answer; …

Member Avatar for ryuurei
0
7K
Member Avatar for rogue005

I am doing a project using Java swing in Netbeans and I am using their in-built GUI generator thing. I have created a socket in one frame and i need to use the same object in another frame. these frames are present in the same package but are different classes. …

Member Avatar for Ezzaral
0
3K
Member Avatar for ThrasherK

I have a problem with code I am writing. I am supposed to count the instances of each specific digit that the user inputs. I am supposed to output blank digit appears blank time(s). I figured out how to get the numbers to go to different indexes in the array …

Member Avatar for ThrasherK
0
212
Member Avatar for TheComputerGuy

I have to convert 2D into 2 of Diamonds. I can not use if statements. If the person enters 10C then it prints out 10 of clubs. I've contemplated trying taking the string length, taking the position end of the string and using the D,C,S,H in the switch statements But …

Member Avatar for TheComputerGuy
0
179
Member Avatar for Isabelle

Hello guys, This project requires the use of an array of pointers to aRandomNumberGenerator (i'll call it Random for short) objects. Both aDie and aCoin are derived classes of the Random class. I am to use the array to call the virtual function generate. My problem arises in my main …

Member Avatar for Isabelle
0
126
Member Avatar for virusisfound

I want to retrive some controls form form1 to form2. i dont know how to do it. Please any one help me to solve this problem... virusisfund

Member Avatar for lotrsimp12345
0
273
Member Avatar for Aigulek

Hello everybody! I am just a beginner in C, so i have some problems with the password input . This is for bank account, it asks user for password input, but it doesn't works properly for three attempts, in order to go to menu: Could you help me please, what …

Member Avatar for Aigulek
0
107
Member Avatar for pawan_sharma777

I write this program to cheak user name and password enter by the use is same then the user is able to login, for this i declare a pointer array to store some user name and password (like sin up by user),and then the user enter her user name and …

Member Avatar for Ancient Dragon
0
160
Member Avatar for LevyDee

((serverDlg*)m_pDlg)->OnReceive(port); I built a server using MFC, and had to get the foundation going by using examples online. The OnReceieve(port), is a function that I created in my CDialog class. ((serverDlg*)m_pDlg) is the part I don't get. This line of code is in a function in my socket class, and …

Member Avatar for LevyDee
0
210
Member Avatar for kooia

Hi everyone, I was wondering if there's a way to write a command to the terminal from a c++ program. I'd like to be able to have some kind of loop with a Makefile, so the last command on a makefile runs the makefile again. Otherwise, is there a way …

Member Avatar for kooia
0
171
Member Avatar for leverin4

Is it possible to rewrite the following VB.NET code in VB6? [CODE]Dim Names(,) As String = New String(,) {{"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, {"UserName", "RealName"}, …

Member Avatar for leverin4
0
168
Member Avatar for Jamesbch

Hello everyone, I'm working on my game project and my aim is now to produce the interface part. I've found that there is an easy way to produce some text on the screen with [I]glutBitmapCharacter[/I] and it's working quite well except the font choice is a little bit restrictive. So …

Member Avatar for Jamesbch
0
475
Member Avatar for Easytime

Dear VB Pros, Please I want to solicit your assistance on a comprehensive database design for the following explanation: I have a customer order form comprising of: 1. the following controls will get information from the customer that will be stored in the customer table. [[B]CustomerName[/B]], [[B]CustomerAddress[/B]], [[B]City[/B]], [[B]State[/B]], [[B]DateofPurchase[/B]] …

Member Avatar for finito
0
127
Member Avatar for c++learner

Hello, I'm simply trying to keep track of how many times a space is encounteed in a string and then print the number of times to the console. Can someone please examine and give me a tip on what is wrong? Thank you! [CODE] #include <iostream> using namespace std; int …

Member Avatar for c++learner
0
184
Member Avatar for amit12
Member Avatar for Agni
0
334
Member Avatar for Lux Fero

Hello World, [INDENT][/INDENT]Can anybody help me to create a windows applcation with turbo c. Am newbe in turbo c and I learned to make c programmes very well, but I Am facing a lot of problems since I moved to windows applications and i can't understant why turbo c doesn't …

Member Avatar for Lux Fero
0
146
Member Avatar for spowel4

If I have the following line in a bash script, it works fine: [CODE]CoDescDate=$(awk -F"\t" '{print $22}' $1)[/CODE] If I embed the above line in a function that is within the same bash script, the script seems to hang at the point of invoking the function. [CODE]pay_ending_date () { CoDescDate=$(awk …

Member Avatar for spowel4
0
150
Member Avatar for Unbidden Ghost

Hi Does anybody out there know of some open source projects that uses Java and would be happy to accept another developer? I am busy with a skills upgrade effort (not to mention that I am looking to build my Java knowledge). Right now I am learning design patterns and …

Member Avatar for ~s.o.s~
0
159
Member Avatar for kooia

Hi everyone, I want to copy the output of a program with another program so I can write it to a file. I'm running Ubuntu Linux, and I'm trying to see what my system is like with hwinfo. The list is too long, though, so I need to put it …

Member Avatar for kooia
0
124
Member Avatar for mith_cool

I am a beginner to advance java and since am learning servlet am getting some weird error in my servlet. I am trying to get the method name and this is the code which i wrote down [CODE] import javax.servlet.*; import javax.servlet.http.*; import java.io.*; import java.util.*; public class NewServlet extends …

Member Avatar for ~s.o.s~
0
237
Member Avatar for dansnyderECE

I'm trying to compile an executable (ELF file) that does not use a dynamic loader. I built a cross compiler that compiles mips from linux to be used on a simulator I made. I asserted the flag -static-libgcc on compilation of my hello.cpp file (hello world program). Apparently this is …

Member Avatar for vijayan121
0
2K
Member Avatar for Tweed

I have a form that creates a row of checkboxes depending on the type of analysis the user wants to perform on the incoming file. I need to be able to determine if the checkbox is "checked" but I don't know how to do that when the controls are created …

Member Avatar for Tweed
0
1K
Member Avatar for markyjj

Can someone please help with the following problem I am trying to update a sql database through a command builder but I keep getting an sql exception (Additional information: System error.). I dont know where I am going wrong because I thought the command builder should carry out the update …

Member Avatar for Renas22
0
365
Member Avatar for edgias

Hie guys!I am developing an application(has 4 forms so far) and I want the Login form to be closed when one is on the Main Form.The application has an option of exiting the system on the Main Form but when I do that the Login Form will still be there..I …

Member Avatar for Geekitygeek
0
99
Member Avatar for rahul8590

Well i have a small code snippet which is a basic http server. Well its running fine , but i am unable to catch the feedback and store it in a log file of my own for further analysis. code snippet : [URL="http://codepad.org/MppnYU9n"]http://codepad.org/MppnYU9n[/URL] just in case wondering on how to …

0
109
Member Avatar for Indirect

Hey all. First post ;) and since i've used this site a lot for help i think its about time i registered and joined up. Im not new to programming but i am new with php + database manipulation. [CODE] $app = mysql_query("SELECT * FROM applicant_classinfo WHERE appid='".$_GET['id']."' AND '".$_GET['cname']."'"); …

Member Avatar for Indirect
0
152
Member Avatar for ichigo_cool

This might sound like a noob question, but that is because I am a noob. Anyways, I was just wondering what's good about inheritance and polymorphism in game development? I'm learning about them now and I can understand it mostly, but I can't wrap my head around an important use …

Member Avatar for helioptra
0
122
Member Avatar for sabareesh

// function declaration char* operator LPCTSTR(); // defenition char* String::operator LPCTSTR() { char* szArry = NULL; szArry[1024]; reurn(szArry); } how we can create a LPCTSTR string class member function in c++

Member Avatar for Ancient Dragon
0
238
Member Avatar for sfuo

So far I have written a program that draws text to the screen and I am able to change the font type but I am unable to change the font size. Here are the 3 main parts of my code that I think you need to see. Font structure: [CODE]typedef …

Member Avatar for sfuo
0
271
Member Avatar for ichigo_cool

Hello, I really have no clue how to start creating a game engine, what skills I need in C++, I want the engine to be for 2d RPG games and relatively simple, mostly for experience. Could someone give me a step by step guide or something, I'm just really baffled …

Member Avatar for mike_2000_17
0
122
Member Avatar for evinkeating

I'm working on a C program that needs a lot of dynamic memory allocation of 1-D and 2-D arrays. The program works fine when I compile and run it using windows and Visual C++, but when I compile and run it in a Unix environment, I get slightly different results, …

Member Avatar for Ancient Dragon
0
185
Member Avatar for java_programmer

Hi, I am writing a program in Excel Macro, where I need to create an array and then have to check wheather an element exists or not in that array. I have created the array as follows - Dim tmpArr(1 to 10) as Integer tmpArr = Array(2,4,6,8,10) Now, i can't …

Member Avatar for vb5prgrmr
0
168
Member Avatar for firoz3321

Sir, i'm new here searched the forums and web. I'm a beginner and dont know C very well. The Question actually is this: [QUOTE]Write a C function called DistinctWords that counts the distinct words in its input string and prints them in the descending order of number of its occurrence. …

Member Avatar for Adak
0
3K
Member Avatar for jaycastr

Hello All, I have a simple question How do i get a variable from one function into another function. I am new to javascript. Here is my code[CODE] function timestart(that) { var x = new Date(); that.value = x; } function timeend(that) { var y = new Date() that.value = …

Member Avatar for jaycastr
0
28K
Member Avatar for jenmhack

hi can you please help me with my project??? it is all about on making a map of the realty houses...and i dont have an idea to do it.. my teacher said..the concept is when you search the person his/her house will zoom in..please help me...

Member Avatar for vb5prgrmr
0
94
Member Avatar for gabhinav31
Member Avatar for scorpio26krf

I am writing a web page, on this web page there is a txtStart and txtEnd. Next to them I have Calendar ImageButtons. I would like to code it so when the ImageButton is clicked a calendar popup appears and when they select a date on the popup it goes …

Member Avatar for dutchaaron
0
120
Member Avatar for nasnoma

My program basically asks the users for a value (s) then calculates and displays the First, Middle, Last, and Final. The users have a choice to enter the value either in integer, real or character. If the user enters it in real or character, it will be converted into integer …

Member Avatar for nasnoma
0
521
Member Avatar for nodoso

Hello everybody, I have some trouble with the google maps api. I want to add markers from a xml file to my map but it seems that the function is not parsing my xml file and I am clueless. Any ideas here is my code: [code] <!DOCTYPE html> <html> <head> …

Member Avatar for SolidSolutions
0
949
Member Avatar for joe'g

hi am trying to code a program that uses a panel that has a functional calculator in it, and the calculator can be re-sized using a slider. here is my code please help me out import javax.swing.*; import javax.swing.event.*; import java.awt.*; import java.awt.event.*; public class CalcInSlider extends JPanel{ JSlider slider; …

Member Avatar for NormR1
0
125
Member Avatar for cmhampton

I am having issues parsing JSON data from a web service. The web service is local on my machine, and I have added it as a Web Reference. Simple data types from the service work perfectly. However, if I call a method that returns a complex structure (such as an …

Member Avatar for cmhampton
0
515

The End.