199,114 Archived Topics
Remove Filter ![]() | |
Hello I'm new at using c++ and new at this forum as well, I'm wondering if you could help me with my atm project. Could you please show how to make my program accept pin number but display ***** or any other character,[ICODE][/ICODE] instead of showing numbers when inputting them? … | |
hi, i am new here and i hope you could help me with my ERD ... it goes like this • A patient can make many appointments with one or more doctors in the clinic, and a doctor can accept appointments with many patients. However, each appointment is made with … | |
hie there..i m using tis embeded media player in my web. but, how can i provide checkbox for each song and then let the user play the multiple songs together using tis code? the music file format are .wma, .mp3 or .midi.... plz help me...thank you [code] <embed type="application/x-mplayer2" id="music1" … | |
Hey guys. So I want to learn how to do a simple I/O to and from a file. I want the simplest way to do this. My teacher sent me her program but I don't think I get what she is doing and it's giving me an error. So I … | |
Hi, I am making a program where I am to ask the user a series of questions and add up the amount they get right blah blah.... I have to ask them the area of a square, the perimeter of the square along with other shapes.... So I was going … | |
Hi everybody, i just registered here. Hoping to learn some from everything i find here and also hoping a bit to be helped out. I am creating a small program which has a few texboxes which i want to saved in a access database. My problem is i have no … | |
I have a very simple question for someone. I am trying to get back into java programming and I downloaded the latest textpad. Can someone please provide me the link of what else I need? I am on a Windows 7 machine. | |
C# double click datagridview record, show data to textbox/combobox. | |
Hello! I wonder if someone can help me. I have a combobox named Requirements and The values of it come from sql. I want to ask how can I detect if I already selected one item to avoid selecting it again the next time I dropdown the combo box. Thank … | |
im a newbie here in python and in this forum site. im using python 2.7.1. and im making a simple calculator that can trap if the second input is zero in division 0peration.. is it possible to call def to def within the if-else statement where ?? because im trying … | |
I'm trying to find a way to make a wx.Frame stay on top of my other windows until I call hide(). I do not mind if it stays on top of all windows or just the windows called by my program. I think I need to set a style on … | |
Can someone please explain it saying that warning C4700: uninitialized local variable 'd' used? Enhance the Quadratic program in the following manner. If the user enters a valid set of coefficients (the else” case compute the value )of the discriminant d, defined as: d = b^2 - 4ac If the … | |
Hi, I am trying to serialize an operation to an xml file and have a specific xml format. I have 4 classes "Recipe" and the other 3 classes implement class "Recipe", being classes "Breakfast", "Lunch" and "Dinner". Class "Recipe" implements members "name" while the other 3 classes have the member … | |
I have a simple login module wherein I enter login info to a database. After that, I use another file, loginauth.php which validates the login info. However, I am getting the else statement executed. Can somebody point out what's wrong. [CODE]<?php session_start(); if (isset($_POST['userid']) && isset($_POST['password'])) { $userid = trim($_POST['userid']); … | |
Hi, I am having a lot of difficulties with the DataGridView control in Windows Forms. No matter what I do, I can not affect the height of rows in any way, shape, or form. I try to set the grid's properties so that it will automatically resize to row contents, … | |
I have 2 projects that I have been working on for a while. I want to open a form that is part of project 2 when I click a button on a form in project 1. I have no doubt that that this is possible but I don't know how, … | |
Hi everyone! I am doing in php that among users can be added as friends. When I save the data I keep this name user1 logged and username2 of who wants to be friends. User1 keep the session and when I click on follow me this appears Unknown column 'UserSession … ![]() | |
hey guys.....i need for a part of my homework in python...to change the text in color. for each letter a specific color will be assigned, in this way, the text that will be typed in will be turned into the specific color. can anybody help me? | |
I hope this is the right place to post this, since it's more of a wordpress question than anything else. I was wondering if anyone can give me an opinion on the best way to redirect a site to another url when a mobile phone opens the page. Since I'm … | |
Hello, I have written some java classes to generate a random network. The network is made of : 200 nodes . Each node has a maximum of 50 neighbors. What i want is to Randomly chose a node from that network and GRAPHICALLY show it with its one hop neighbors … | |
I am new to programming and trying create a program that will be able to input students test scores. After this another prompt will ask you for the students name who received that score. When finished inputting, the program should tell me the highest score and lowest score, along with … | |
I created a simple [B]Node.java[/B] class, where each Node instance has an 1-id variable of type int 2-Neighborlist of type Arraylist I wrote a code that gives me a random network, made of 200 nodes, and each node can have up to 55 neighbors. [CODE]for(i=0; i <200; i++ ) // … | |
Hi, I am new to java (normally program in perl and bash). I have an array that has X amount of rows that look like this: 2011-02-24,XXXDAO_456912 - (none) - (direct),(none),(direct),(not set),(not set),0,5447,1,3639.71,3521.86,0,0 What I need to do is take this column - XXXDAO_456912 - (none) - (direct) - and … | |
it give an access denied<java.io.filepermission Item.txt write> error any suggestion for a simple id generator? [code]import java.applet.Applet; import java.awt.*; import java.awt.event.*; import javax.swing.*; import java.io.*; import java.lang.*; public class Shoes extends Applet implements ActionListener, ItemListener { Font SansSerif = new Font ("SansSerif", Font.BOLD, 12); Button create = new Button("Create a … | |
Hi guys, ran into a small problem, i can read & write anything i want to a text file as well as append to the end of the line but I cant seem to figure out how to edit a specific line. Lets say in the text file i have: … | |
I was wondering if someone can help me with this. [url]http://img189.imageshack.us/i/50468910.png/[/url] I'm looking for the matlab code for this one. Wikipedia has an example: [code] i := 1 j := 1 while (i ≤ m and j ≤ n) do Find pivot in column j, starting in row i: maxi … | |
yt= 1.0 + 0.90yt-1 + e1t zt= 1.0+ 1.0zt-1 +e2t Using RATS generate 500 observations for y and z. note e1t and e2t are iid. save the generated y and z in a RATS data file (.rats) and open your data file. plot y and z and discuss the time … | |
I would like my wx.TextCtrl box to only accept numbers, preferably to only 2 decimal places. Where should i start? should i use an input mask or are there styles too control this kind of input? [CODE]value = wx.TextCtrl(parent)[/CODE] | |
I have 10 words. How can I get all possible combinations of 5 words (n=10, k=5). The order does not matter. For example: "A", "B", "C", if k=2 (n=3 in this case), it would like AB, BC and AC. Maybe you know some usefull code or example. P.S. Sorry if … | |
Hello everyone, I wrote a c program in order to write 5 students records (name, ID and average) to a file. Now the difficult step is to firstly to find the highest average among students. Have anyone any clue how I can do this? Thank you | |
How can i get graphics.h header file and put it in my Visual C++ 6.0 directory ?? | |
The code below displays a signature on the screen previously signed on the form before. It has now displayed the image as a png. How do i go about saving the image into a mysql database field so i can recover the picture as and when i need to / … | |
Memory allocation. Pretty simple, but I guess there might be some people here who do not know what it is... [CODE]#include<stdio.h> #include<iostream.h> int main() { int *n = new int; *n=12; printf("n's value is %d\n",*n); *n=25; printf("n's value is %d\n",*n); delete n; printf("n was deleted\n"); system("PAUSE"); return 0; } [/CODE] | |
I'm having a bit of trouble replacing parts of a string. I'm using preg_replace and it works but it replaces everything in between. I need it to search for every match between the string. What I have so far: $message = 'I have a [color]red[/color] apple and a [color]blue[/color] car.'; … | |
The problem is I use malloc in the last function(toString()). I just wanna know if there is anyway to free it? or that I dont have to? Thanks [CODE] #include<stdio.h> #include<string.h> #include<stdlib.h> #include<ctype.h> /* Function prototypes */ void process(char input); void update(char words[][51], int position); char * toString(char character); /* … | |
please people your help will be appreciated. i have a table with data definition: column Datatype BookID int AuthorFirstname nvarchar(20) AuthorSecondName nvarchar(20) BookTitle nvarchar(50) Price nvarchar(50) My problem is that i can't see the inserted data in my table Below is the whole code: [CODE]Imports System Imports System.Collections Imports System.ComponentModel … | |
Hi guys i need help with one thing in Python... I've got something like [code] number=001 example = "picture%d" % number print example ---> But it prints picture1 not picture 001.... [/code] and i need it as integer not as string because i want to use --->[code]number=number + 2 for … | |
Hi all, I am at a stand still with trying to figure this out. I have a textarea, i would like to check for links entered by users and replace/remove the anchor attribute from the string. ie. change [ICODE]<a href='google.com'>website</a>[/ICODE] to [ICODE]website[/ICODE] its more so to validate ( i have … | |
for(j=0;j<3;j++) { repeat:if((int*)ch[j][l]>(int*)ch[j+1][l]) { strcpy(tmp,ch[j]); strcpy(ch[j],ch[j+1]); strcpy(ch[j+1],tmp); } else if((int*)ch[j][l]==(int*)ch[j+1][l]) { l++; } goto repeat; } for(i=0;i<3;i++) { printf("%s",ch[i]); } return 0; NOt gettin any output | |
How do i prevent a C string input from the user from exceeding the capacity of the array? is this not possible? [code]int main() { char buffer[8]; printf("enter a string"); scanf(%s,&buffer); return 0; }[/code] | |
Im a noob in C and I got this simple code working.. [CODE]#include <stdio.h> #include <conio.h> #include <string.h> int main () { char str1[20]="burke",str2[20]; printf("Dog's name?:"); scanf("%s",str2); if (strcasecmp(str1, str2)==0){ printf("Gratz you got it",str2); } else{ printf("Wrong Answer!!!"); } getch(); } [/CODE] My problem is what if instead of "burke" … | |
I write a simple average program, but for some reason I keep getting compiler error. I tried to check my work, but still can't find where do I do wrong. It shows the message on average = total/10, and it says something like unable to reach statement. [CODE] //test import … | |
Hi I have recently learned c++, I'm 14 and want to get started on developing software. The problem is I'm too young to get a career in programming but I would like to start now partly to make it easier in later life and partly because I enjoy programming. The … | |
Hi, i am trying to write a program for my homework. Write a function, lookupPrice that uses the product code to look up for the price. If the product code is on special promotion, a 10% discount is given. If the product code is found, the function returns the price, … | |
I have 5 strings, such as: "one", "two", "three", "four", and "five". I need to get all permutations of these words. I've explored all internet resources, but all solutions are so bulky and it's hard for me to understand it and integrate it to my program. So, maybe you know … | |
Hi, Sorry for many questions... I need help for button sound that when i click the button sounds. Thanks | |
the function keeps returning 1. if i echo $i within the function then it counts up to six. the function should return 6, because there are 6 results from the mysql_query, so $i iterates upto 6. please any help solving this? [CODE] $i=0; $thewidth = $database->width($theid, $i); echo $thewidth; [/CODE] … | |
after examineing this code, it seems like it actually allocates space for the pointer....but how? is this a bug? how can u allocate space for an array of 0 elements [CODE]int main() { int *ptr = new int[0]; return 0; }[/CODE] | |
Hi I am trying to put up simple app, and i get an error, could you tell me what I am doing wrong please. Here is my code: [CODE] #include <afxwin.h> class myapi: public CWinApp { public: virtual BOOL InitInstance(); }; class myframe: public CFrameWnd { public: myframe(); protected: afx_msg … | |
Hi, can anybody help me with this program output. Program is based on GCC compiler standards [CODE=c]#include<stdio.h> main() { int *ptr=10,j; j=ptr+19; printf("ptr=%d\n",ptr); printf("j=%d\n",j); } [/CODE] [CODE=text]output: ptr=10 j=86[/CODE] when ptr value is 10 in statement "j=ptr+19", why the j value is 86?? |
The End.