199,114 Archived Topics

Remove Filter
Member Avatar for
Member Avatar for stereomatching

Since the data structure are something like [code] struct morph { size_t num; std::string name; //and so on } [/code] I have to find the different of the two sets with functor or some 3rd party where could I find something like this? Below is the implementation alter by me(refer …

Member Avatar for mike_2000_17
0
330
Member Avatar for woodenduck

Hey, I was wondering if anyone could show me a little javascript. I've never used it before and am unfamiliar with how to reference outside API's. What I'm trying to do is read a string in from a website/Web API. So..: HTML with javascript document: [code] <script type="text/javascript"> var wantedString …

Member Avatar for woodenduck
0
604
Member Avatar for C++newbie chick

Hello guys, I've tried searching the internet on how to cout a struct in an array via a binary search, but with no success. I've only learned how to do a linear search and I sort of understand how to do a binary search but: how do I cout the …

Member Avatar for C++newbie chick
0
2K
Member Avatar for javedmirza

AOA Dear fellows i have code in which i uses linked list.when i compile that program the compiled file run but not work. I write this code in Dev c++. [CODE] #include <iostream.h> #include <string.h> #include <stdlib.h> using namespace std; class Node { public: int value; string Name; Node * …

Member Avatar for raptr_dflo
0
242
Member Avatar for Zarl

Well i'm completely new to C# so my code is very simple but i want someone to look at this very small piece of code and tell me what's wrong with it because when i am finished writing it, it gets an error at all my semicolons. [CODE]{ class Program …

Member Avatar for Zarl
0
297
Member Avatar for newbie26

i need help with my database. i always backup my database everyday.. but whenever i am doing this and when the backup is ongoing, all the system which connects to this database server always encounters hanging. now, i have no choice to stop backuping the database so that the users …

Member Avatar for newbie26
0
118
Member Avatar for swoshromp

What my problem is I don't know how do I set it up so that when the entire word has been guessed I can stop the game and tell the user they won or lost. I tried adding in another if statement after maxTries--; where it says if (maxTries == …

Member Avatar for JeffGrigg
0
259
Member Avatar for visored23

hi, i'm new to c# programming and i have this problem that i encountered while trying to create a database browser. Here is my code: [CODE]private void button1_Click(object sender, EventArgs e) { string search; search = searchbox.Text; if (search == "") { MessageBox.Show("You have not entered anything. Please enter the …

Member Avatar for visored23
0
194
Member Avatar for DoubleGee

Hi guys, I'm new to Java and was wondering if you could help with one little problem with my code. [CODE]System.out.print("Enter title: "); String title = keyboard.next(); if (title.equals("Mrs") || title.equals("Miss") || title.equals("Mr") || title.equals("Ms")) { title = title; } else { System.out.println("Enter a valid title"); }[/CODE] If the title …

Member Avatar for thines01
0
235
Member Avatar for renzlo

I know this is quite simple for you to code but for me as a beginner I need some examples or guides. I have a text file which has this content: [CODE]random line random line random line random line random line random line random line random27061-1-0256487952random words random words random …

Member Avatar for renzlo
0
196
Member Avatar for AndyPants

Hello, im working on a project that works with an access database but i dont know how to edit an existing record... here is the code that i use for reading the database: [CODE]Public Function ask() Dim dt As New DataTable Dim ds As New DataSet ds.Tables.Add(dt) con.Open() Dim da …

Member Avatar for AndyPants
0
181
Member Avatar for calebcook

Hi. I'm trying to create a function which connects to a database, and then displays rows in it. I'm trying to use a function to connect, but it's not working. Here's my first code: [CODE]<?php define("SERVER", "mysql.example.com"); define("USERNAME", "username"); define("PASSWORD", "********"); define("DATABASE", "db"); function displayFunction() { $dbc = @mysqli_connect(SERVER, USERNAME, …

Member Avatar for calebcook
0
138
Member Avatar for BuhRock

So I have to implement a checkout line using a priority queue. I'm really stuck. I have 3 classes, a Register class, Store class, and customer class. Each customer has a service time which is the time it takes to check out. There are ten registers. Reach register has a …

Member Avatar for BuhRock
0
154
Member Avatar for Taximus

[COLOR="Red"]Hi everyone[/COLOR]. :?: I have a big problem. I have different classes: [B]Square, Circle, Star, Triangle[/B]. They allow me to draw figures on the picturebox. I have different buttons on my form. Example button "Circle" works like that: [CODE]Circle circle = new Circle(); list.Add(circle); circle.Draw(this.pictureBox1, circle.mypen, circle.pos, circle.num);[/CODE] When I …

Member Avatar for skatamatic
0
289
Member Avatar for digan

Hi I am trying to make a program that prints a snooker board on the screen. I am trying to print the different parts on top of each other. So far all I am able to do is print the background. when i try to print the cloth on top …

Member Avatar for hiddepolen
0
388
Member Avatar for datdude07

Hi I was wondering if anyone could help me figure out why every time I try to run this code it keeps bringing up an error of "cannot nest procedures". I need to use the PROTO and PROC directives in this program for my HW assignment. I'm also trying to …

Member Avatar for datdude07
0
451
Member Avatar for dennysimon

hello all I fill datagridview Row[0].Cells[0] with the following command dgv1.Rows[0].Cells[(0].Value="-1"; //------------------- how to give color so that the content "-1" in datagridview has red in color (forecolor) thank you denny

Member Avatar for dennysimon
0
137
Member Avatar for Labdabeta

I need to know how to extract the data in a display list in opengl. I have a font and use it to create a display list to draw, but then I want to get the actual vertexes of it so I can use them for collision checking. How can …

Member Avatar for Labdabeta
0
116
Member Avatar for grako84

Hi Folks! I got to game (know as concentration or memory)code for my assignment. I have found many similar tasks, but mine is a bit different. Our teacher asked us to implement comboBox that we could switch between images and text version. So far I have made image one, and …

Member Avatar for grako84
0
256
Member Avatar for applejax77

Looking for Java help! I am working on the payroll program below and would like some help please. When I run the prograom, I am using jGrasp, the program runs with no errors identified in the code but I get the following window that pops up...."No main methods, applets, or …

Member Avatar for hfx642
0
2K
Member Avatar for Jessurider

how to get only the file name from the given path............ [B]example1:[/B] String str1="C:\New Folder\My Data\kk.png" From the above how can we get only the file [B]kk.png[/B] [B]example2: [/B] String str1="C:\New Folder\My Data\Java\Project\yy.bmp" From the above how can we get only the file [B]yy.bmp[/B]

Member Avatar for JamesCherrill
0
103
Member Avatar for bigredaltoid

I need to read in a list from a text file, put that list in a list, read in the amount of credits the students earned as an int, and than add 16 credits to the list. Here is my code so far: [CODE]myList2 = [] myList = [] myFile …

Member Avatar for bigredaltoid
0
194
Member Avatar for python-noob

I know this forum isn't to give away the answers, but could someone maybe help me get started? My biggest problem is figuring out where to start. Even the pseudo code doesn't help me very much. I don't know how to use an excel file in a program either. I …

Member Avatar for python-noob
0
207
Member Avatar for ashsailesh

i am using an array of JButtons b[23].... my objective is that when i click a button it has to change its background color to black but it is giving a nullpointer exception.... if(ae.getActionCommand().equals("0")) { System.out.println("button b[o] is pressed"); b[0].setBackground(Color.black); } } can anyone help me with this please........

Member Avatar for hfx642
0
127
Member Avatar for cdudefire

I have been working on this code for a while and I can't seem to get to work right. I have been trying to make a credit card validator program in c for a class assignment. Any help would be welcome. [CODE]#include <stdio.h> #include <ctype.h> #include <stdlib.h> #include <string.h> #include …

Member Avatar for cdudefire
0
114
Member Avatar for techyworld

Write the definition of a class student. Student object should represent student in a school. it should contain the following information: id,name,age,address. Can someone tellme the definition using this example?? am still a newbie in java.

Member Avatar for jackmaverick1
0
100
Member Avatar for RaigaX9

Hello again everyone, on my recent thread about my rock, paper, scissors program, I had trouble running it from Applet to JApplet and that problem was solved. So far, I've added many functions for the program such as menus, checking your score, resetting the score, and setting the number of …

Member Avatar for jackmaverick1
0
446
Member Avatar for ptara1

So I'm trying to transfer a longblob from one data table to another. All the other data is transferring however the longblob isn't. I know it is getting up loaded to the temp table because the longblob column show s there is data in it. here is the snippet of …

Member Avatar for sjsnider
0
1K
Member Avatar for YourGamerMom

I used a multi dimensional array: [CODE]int grid[3][3];[/CODE] then I assigned all the variables in the array to the number 2 like this:[CODE] grid[0][0] = 2; grid[0][1] = 2; grid[0][2] = 2; grid[1][0] = 2; grid[1][1] = 2; grid[1][2] = 2; grid[2][0] = 2; grid[2][1] = 2; grid[2][2] = 2;[/CODE] …

Member Avatar for YourGamerMom
0
99
Member Avatar for tyricec

I'm trying to make my rectangles appear on screen, but it appears blank when I run the program. [CODE]#include <GL/glut.h> #include <stdlib.h> #include <math.h> using namespace std; struct GLPoint { GLint x; GLint y; }; void init(void) { glClearColor (1.0, 1.0, 1.0, 0.0); glShadeModel (GL_SMOOTH); } void display(void) { int …

Member Avatar for tyricec
0
234
Member Avatar for Sprewell184

I have this code below where I have to make it a function. I'm confused. I tried [CODE] def drawLine(img): .... .... .... [/CODE] Do I set the location of the picture as my variable? and then calling it? How would I call my parameter when I want to check …

Member Avatar for TrustyTony
0
123
Member Avatar for zippee

Hi, is there any php function can read text between tags or quotes. For example, I have <h1>This is heading 1</h1> and "This is text in Quote", how can I use php to read the text between <h1></h1> tags or the text between quotes? I know I can use substr …

Member Avatar for jpdeleon
0
679
Member Avatar for Sprewell184

Hi, I have this problem where I have to make a function that takes one parameter and draws two vertical lines, one is a red line from (50,0) to (50,300) and one made up of randomly colored pixels(150,50)to (150,250). I didn't define my function yet but for some reason my …

Member Avatar for Sprewell184
0
1K
Member Avatar for kytro360

I have a listbox filled with different items. For each item in the list it will visit a site in the web browser, the user using the software fills out text on the page, then it moves down the list. How can I make it so it iterates down the …

Member Avatar for zachattack05
0
237
Member Avatar for bukk123

I have a combobox which is filled with items from a table like this: [CODE] For Each rad In interntabell.Rows firstname = rad("firstname") lastname = rad("lastname") id = rad("id") ComboBox1.Items.Add(id & " " & firstname & " " & lastname) Next rad [/CODE] What Im trying to do is to …

Member Avatar for Phasma
0
590
Member Avatar for asif49

I want to write how long it takes to parse one of the pages for my website. I've got the setting up of the time variable at the top of my script then have a lot of stuff which is done in-between. I then display time elapsed at the bottom …

Member Avatar for asif49
0
110
Member Avatar for nicolebdillen

[CODE]//Program to find the sum of the main and right diagonals of a 2D array import java.io.*; public class Diagonals { public static void main(String[]args)throws IOException { int arr[][]={{1,2,3,4},{1,2,3,4},{1,2,3,4},{1,2,3,4}}; int maindiag=0;int rightdiag=0; for(int i=0;i<4;i++) { for(int j=0;j<4;j++) { if(i==j) { maindiag=maindiag+arr[i][j]; } } } System.out.println("The sum of the main diagonal …

Member Avatar for sneha_07
0
954
Member Avatar for zendet

Hello I need to figure this out, I tried if ((Fire = 0) || (Water = 0) || (Air = 0) || (Earth = 0)) { System.out.println("Hello"); } But the compiler says I cant use && for ints, I need to get a value for each variable and have certain …

Member Avatar for thines01
0
92
Member Avatar for smmcfarl

My program is compiling fine but my issue is with the output. The grades are not correct and the counters are not working either. If anyone can help that would be great. [CODE]//stud.cxx #include "stud.h" studType::studType(int idVal, float exam1Val, float exam2Val, float exam3Val) //********************************************* { id = idVal; exam1 = …

Member Avatar for gusano79
0
155
Member Avatar for my.name

Hello everyone, :) I have exercise for class that I can't complete, I don't understand why my loops aren't working The question--- Write code that will print a multiplication table for 10 positive integers across the columns and 10 positive integers down the rows. Prompt the user for the starting …

Member Avatar for my.name
0
848
Member Avatar for compulove

I wrote code that will send all my textbox information to a text file. It successfully goes there but it is all in one line and in no type of order. What I wanted to do was have it in on line spaced correctly and possibly with column headers to …

Member Avatar for lolafuertes
0
192
Member Avatar for praveens96

import MontyLingua theTagger = MontyLingua.MontyLingua() String = "when was tom born?" #tokenized the String tokenizedString = theTagger.tokenize(String) chunkedString=theTagger.chunk(tokenizedString) #error coming here #Tag the tokenized String tagString = theTagger.tag_tokenized(tokenizedString) print tagString #A more simple way to tag the String tagString = theTagger.jist(String) can anyubody help me why error is occuring there …

Member Avatar for sumitb128
0
627
Member Avatar for thatjoeguy01

Hey, So I am a very experienced PHP programmer and completely new to python, I was wondering if someone could assist me with this program I am trying to make, The idea is simple The program has 10 different fortune quotes, the user needs to be able to tell the …

Member Avatar for thatjoeguy01
0
184
Member Avatar for methuselah90

I'm writing a piece of JS code that returns a result of true if the pattern appears in string as a substring (case sensitive) but would like to extend its functionality to returns true if all the individual characters of pattern appear in string (regardless of order). For example: This …

Member Avatar for AleMonteiro
0
210
Member Avatar for adamfhs

I am 16 and have been trying to learn VB for a few months. I am trying to make a text box the user of the program can type in and when the are done they can click a button and it will be sent to my email. Im having …

Member Avatar for WaltP
0
155
Member Avatar for canarian

Hello! I have size about 200*250 icon for my simple application. I need to put it inside on frame as (about) 40*40 size. But when i try everything (image icon, icon for JLabel...) but i could not re-size it inside on JFreme. I f i set the size as 40*40, …

Member Avatar for mKorbel
0
625
Member Avatar for Sbing

I cant figure out how to fix the "public class Triangle implements Measurable" i dont know what i am doing wrong to get this error.. i am not fluent in java but i never had this error before. i tried changing the name but in the process i get more …

Member Avatar for Sbing
0
160
Member Avatar for ibpet11

Hi Pal, I have issues with inserting date into my database. Though i declare the datatype as datetime in my SQL server database I will sincerely appreciate someones assistance in helping me fix the error. the error message is " [B]Conversion failed when converting datetime from character string[/B] " here …

Member Avatar for Mitja Bonca
0
114
Member Avatar for dew97
Member Avatar for dcazacu

Hello everyone, I just made a .cpp file to modify a data file in .txt (not relevant actually) file. I basically want to apply what this program is doing to all the .txt files in a ./input folder , and I couldn't find anything relevant so far. The code is …

Member Avatar for WaltP
0
246

The End.