199,114 Archived Topics
Remove Filter ![]() | |
Hi Everyone, I want to develop a tool in which I will input the following details 1.Total Area of your house roof. 1.Direction of the Roof of your house 2.Average Monthly Power Bill 3.Style of the Roof (wood shake, foam, rolled, spanish tile etc) 4.How steep is the Roof slope … | |
Hello I was wondering how can I set a char limitation in my code when I am asking for an int? When you input a char my program goes crazy. Let's put the following simple program as an example: [CODE]#include <iostream> #include <iomanip> using namespace std; int main() { int … | |
Hi everyone![I] I need to write program that will find the average of 20 element array and also display the number of each number in the array occurs.[/I] [I]I have sorted average number but straggle with "number of occurrences". Please help!!!![/I] [code=c] #include<stdio.h> #include<math.h> main() { float avg,sum=0; int i,j; … | |
I am taking an algorithm class and haven't coded in c in around 5 years and realized I have forgotten alot. I tried to use atoi, i know there is a better function but for what I'm using it for and my lack of knowledge now it is simpler, for … | |
Hey there, I'm having trouble figuring out the next step of my program. What I'm trying to do is make a function that will add two polynomials, and I don't know how to exactly fix it. My first question would be if the Polynomial operator+ function is right, or whether … | |
im currently building a game who wants to be a millionaire..the interface is already done but there was an error..there was an incompatible types exception..here is my code..it says found java.lang.String but expected java.awt.event.ActionEvent..help please [CODE]public class MillionaireBoard extends JFrame implements ActionListener { private MoneyLabels a; private JLabel A; private … | |
I had just started learning C++ for couple months n this program is involved with pointer there is a bug in my "doInsert" function however, I dont seem to be able to figure out what is wrong with it every time after I enter the "position" the program crashed can … | |
im trying to write the post order print out of a preorder binary tree reading into a text file though everything i have attempted to do so far as resulted in an error. ive tried reading the preorder into stacks, queues, arrays, and the best ive been able to come … | |
Can anyone help me figure out why I have a segmentation fault error occurring during runtime? I'm guessing that I am accessing memory that doesn't exist or attempting to place data into a node that hasn't been allocated, but can not figure it out. FYI - It's a work in … | |
that an error in my .h , and i need a hint,which would be the problem? | |
I'm currently in a data structure class and i have little programing experience. The assignment is A. In this part, you are supposed to design an integer random number generator that would produce random numbers between 10 and 99 (both inclusive). Design schemes to evaluate its performance as a random … | |
Hi There I am trying to create some javascript to do the following:- Actually its cool, I posted some stuff, but I think I want to work on it some more, so I have deleted the rest of the post. Sorry to trouble anyone. | |
I have a scenario where i am given a file that contains info such as: (just a sample) img01.jpg|Washington DC|aquarium|puffer fish|seahorse img02.jpg|CHICAGO|AQUARIUM img03.jpg|Chicago|fish where the first section is the "image" (just a made-up name, not an actual image) and the rest of the words are keywords. ive been able to … | |
Ok what am I missing?? I have a dropdown list so that admin can select a value from and then update the database. The list IS populated but the select box isn't wide enough to see any of the option values. I even tried adding a size attribute. I know … | |
This program is suppose to grab the first letter of each name and then output the initials. #include <iostream> using namespace std; const char blank= ' '; const char newline= '\n'; void main() { //Declare character variables char firstInitial, middleInitial, lastInitial; cout<<" Please enter first, middle, and last name separated … | |
Hello, In some functions of my program this code doesn`t work normally [code] string w1; string w2; cout<<"1st msg: Enter 2 words: "; getline(cin,w1); cout<<endl; cout<<"2nd msg: Enter 2 words: "; getline(cin,w2); cout<<endl; cout<<endl<<"w1: "<<w1<<endl; cout<<"w2: "<<w2<<endl<<endl;[/code] But when i run it is some functions(except main and some others) of … | |
![]() | Hi All I am trying to add a no under 18's feature to my register page. I have got a simple function which uses the year of birth but I am not sure what to do for the day and month. Here is the code. If someone could help me … |
[COLOR=Blue][B]hi.i've written a program that loads #'s into an array and sorts them.The end user then inputs a number and the program is supposed to perform a sequential search for the input number and tell wether it was found or not found.I'm hoping someone canhelp me with my sequential search.binary … | |
Good morning all; This one is blowing my mind and I could use a little expertise. I'm retrieving data from an Excel sheet, using a simple SQL query using a textbox as input to my variable. It works great when I enter an integer to search for (such as 213 … | |
Hi, I have this error: Notice: Undefined index: menu_name in C:\wamp\www\widget_corp\create_subject.php on line 16 this is the code: [CODE]<?php require_once("includes/connection.php")?> <?php require_once("includes/functions.php")?> <?php //for validation $required_fields = array('menu_name', 'position', 'visible'); $errors = array(); foreach($required_fields as $fieldname){ if (!isset($_POST[$fieldname]) || empty($_POST[$fieldname])){ $errors[] = $fieldname; } $fields_with_lengths = array('menu_name' => 30); foreach($fields_with_lengths … | |
I'm a first semester student of Master degree and i need to implement a project in C# that uses a database with transactions and any kind of monitoring. I already know how to connect a database with C# and i know how to work with databases, but i don't have … | |
I need to query data from a table accourding to user level to genarate a menu list for different user levels, the code worked well with (session->username) but when I changed to (session->user_level) it does not want to work. Any help will be appreciated. Here is my code: [CODE=php] <?php … | |
Good morning all. I've run into a slight stumbling block with some code I'm writing. I'm sure you've all seen the numerous Mortgage Calculator threads so I hope you're not too sick of them yet. Basically, I need my code to first ask the user for a decision, then based … | |
Is it the boost library? Regex in particular? I have searched and searched, but this is all I could come up with. If this is the correct library, then how do I get it to work in Dev-C++? I managed to add all the boost .h files to my Dev-C++ … | |
Hey i am a beginner in programming. My code looks like this: public ChatClient1(String screenName, String hostName) { super("Chat"); String host=(args.length<1)?null:args[0]; ...and it continues. The error I am getting when i compile is: cannot find symbol symbol: variable args and its for both the args in the code above. this.screenName=screenName; | |
if a pointer is a dangling pointer and one applies delete[] to it. is the result defined or not. i basically have the following situation [CODE] class A { private: int *p; //other data members public: //rest of class } [/CODE] i intend to initialise p in the constructors. but … | |
I'm totally new to this, as will be evident, and I can't figure out the syntax for what should be the most basic code. I'm just trying to get a piece of data from a SQL database and store it in a variable. From various book and websites, I cobbled … | |
i have made a program with a vector that is a instance of a class student with three variables. i have stored the information and calculated the class average. what I want to do is get the person with the highest test score and output "this student has the highest … | |
I'm having a little trouble returning the current date from a dll function. Here is my code [CODE]LPSTR __stdcall date() { int i; char dateStr [10]; _strdate( dateStr); LPSTR string = ""; for (i = 0; i < 10; i++) { string += dateStr[i]; } std::cout<<dateStr<<"\n"; return dateStr; }[/CODE] I … | |
Hey! I started using java this year and I finished a java project but when I try moving it somewhere else in my directory it does not execute anymore. My project directory tree goes like this (I am using eclipse)... (ignore the "-") /Root - /bin -- JavaProgram.class -- JavaProgramMain.class … | |
hi, i am trying to switch tabs without page going back to top. i am using this script. [URL="http://www.sohtanaka.com/web-design/examples/tabs/"]http://www.sohtanaka.com/web-design/examples/tabs/[/URL] but i just can't stop it from the page going back to the top when you click a tab. Thanks | |
helo all i wanted to import .csv file to my application [CODE] private DataSet ReadExcelData(string sFilePath) { DataSet dsOutput = new DataSet(); string sConnection = string.Empty; try { if (TypeExcel == "Excel 12.0 Xml") { sConnection = "provider=Microsoft.ACE.OLEDB.12.0;Data Source=" + sFilePath + ";Extended Properties=\"Excel 12.0 Xml;HDR=YES;IMEX=1\""; } else if (TypeExcel … | |
Alright, so I have been working on building a photographer a website. She requested that she would like a page that would allow users to log in and view their proofs and only allow THEM access to their own pictures. I have successfully created a log in page using sessions … | |
Really, the title says it all. Is there any way to compile all the instances of a class into a list, or other such data structure? | |
Hi, i have created a data structure {heap based}, capable of manipulating up to 10 million elements....I noticed that i can't go above this number because i have serious memory leaks.... The problem seems to be that i haven't written a destructor!{i a bit used to garbage collection!} if i … | |
Hi, I have a DataTable oDT. oDT is populated from SQL Server with 6 columns including a column "bAAA" of varbinary(200) I have a function fx(ByVal byteArray As Byte()) as String I would like to add a calculated column to oDT something like this: [code] oDT.Columns.Add("sAAA", GetType(String), fx(bAAA)) 'bAAA is … | |
If I wanted to declare a large number of variables that were all similar, for example: [code=c] var x1; var x2; var x3; var x4; var x5; var x6; var x7; var x8; var x9; var x10; var x11; [/code] ...etc Is there a faster way to do that? Maybe … | |
Hello. How can i use SendMessage to "press" other program's button? I don't know other program's button's ID but there is only one button in that program. I searched MSDN and found something. I tried this piece of code: [CODE]HWND hWnd; hWnd = HWND(FindWindow(NULL, "WindowName")); SendMessageW(hWnd, BM_CLICK, NULL, NULL);[/CODE] At … | |
hiii guys.. i am trying to make an mp3 player using ADSP 21369 processor. For that i need a code which can convert mp3(mpeg2 layer3) samples to wave samples in c. thanx in advance. | |
Hi all, Could anyone please help me with this i have a cascaded menu button and i am adding nodes in a loop like this [CODE] #Create a cascading menu button for adding attribute types AttTypemenuBar = Pmw.MenuBar(topF, hull_relief = 'raised',hull_borderwidth = 1) aname = " Select...." self.createAttTypeMenu(AttTypemenuBar, topF, typeF, … | |
Hi ! I have one Windows Form. On it i put 4 labels and every label it have Click event. I need to understand who of labels is Clicked ? Example: [CODE]label1.Click += new EventHandler(label_Click); label2.Click += new EventHandler(label_Click); label3.Click += new EventHandler(label_Click); label4.Click += new EventHandler(label_Click); private void label_Click(object … | |
The problem of scheduling unit-time tasks with deadlines and penalities for a single processor has following inputs S={a1,a2,...,an} of n unit-time task. A unit-time task requires exactly 1 unit of time to complete deadlines d1,d2,...,dn, 1<=di<=n penalities w1,w2,...,wn. A penality wi is incurred if task ai is not finished by … | |
I'm writing a code in Java where input is a user generated integer string and I have to reverse the integer and check for boolean true or not. I'm stuck at the math portion because I can't exactly figure out the mathematical process of trying to reverse an integer. [CODE]// … | |
My problem is to design a program that uses a mathematical model for heat loss, or Tnew = Told - m(Told - Tair). It also asks me to repeat the code for 60 minutes, generating a new answer every minute. I have completed the code, however I receive no output. … | |
Is there a way you can detect if an incoming referrer is from a url using https? I know you can detect http but it doesn't seem to show anything for https. | |
Hello, I have a txt file of the following format: 315151,34.56,1,1,54442221,23344445 512512,12.54,1,1,23444442,45612345 I am using the following code to parse it and it works: while( fgets( output,sizeof(output) ,file) != NULL ){ i=0; token[i] = strtok(output,","); while( token[i] != NULL){ i++; token[i] = strtok (NULL, ","); } dec2bin(atol(token[4]),binaryBefore); dec2bin(atol(token[5]),binaryAfter); dec2bin is … | |
![]() | Hi out of personal interest i have decided to make a space invaders games. I know all the things i need to implement and i have done a good job if i do say so myself :D. But i have one final problem. When my space ship is just staying … |
Hi friends, It’s hard to find a clear answer elsewhere- Is JavaScript needed for the client-side in asp.net websites or will C# work totally fine (even without the .net framework installed on the clients machine) ?? Is it better to still use some JavaScript in there? (I'm a newbie, just … | |
[code]import java.util.Scanner ; public class Verk6 { static public void main(String[]args) { Scanner scan=new Scanner(System.in) ; double[] a=new double[1000] ; Stats stats=new stats() ; int i=0 ; while(scan.hasNext()) { a[i]=scan.nextDouble(); stats.add(a[i]); i++ ; } Arrays.sort(a, 0, i) ; if(i%2==0) { int m=i/2 ; System.out.println("Median value:"+(a[m-1]+a[m])/2.0) ; } else { System.out.println("Median … | |
Hi friends I am working on a project where I need to show results based upon user queries.I have created the pages,but results are not showing.as I am new to php I can't figure where the problem is. Here is the code [code=php]<html> <head><title>Showing Results</title></head> <body bgcolor="#666666"> <?php include_once "connection.php"; … |
The End.