43,549 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for noobday

I've been trying to compile a very simple c++ code ; when trying to compile on codeblocks it says : error - stray '\312' in program [CODE] #include <string> #include <iostream> using namespace std; int main() { char letter1, letter2; string lastName; cout << "Enter your two initials and last …

Software Development c++
Member Avatar for noobday
0
880
Member Avatar for Godflesh

I have a problem again :) I try to use this code: [code] import time from threading import Thread from threading import Lock def main(): for i in range(3): my_thread = MyThread(i) my_thread.start() class MyThread(Thread): lock = Lock() def __init__(self, i): Thread.__init__(self) self.i = i def run(self): while True: self.lock.acquire() …

Software Development python
Member Avatar for jcao219
0
382
Member Avatar for TheWhite

so I have 2 methods, 1 with an argument the other without command_hello(String sender); command_hello(); I am trying to invoke the method using just their name: command_hello I can do this by using the following for the method with no arguments: getClass().getMethod("command_hello").invoke(this); Works! Great! But the moment I try getClass().getMethod(cmds.get(cmd)).invoke(this, …

Software Development java
Member Avatar for TheWhite
0
157
Member Avatar for pac-man

hi guys, I've created a function that returns the number of times a value resides in a container (in this case, vector). The user is able to specify were in the vector they wish to search for the value. [CODE] int number(int n, vector<int>::iterator start, vector<int>::iterator end) { int count …

Software Development c++
Member Avatar for pac-man
0
231
Member Avatar for gangster88

I need to have 4 functions which asks the user how many times to flip the coin and then displays the number of heads and the number of tails as a decimal? [code] def getInputs(): times=input("please enter the number of times the coin should be flipped: ") def simulateFlips(): for …

Software Development python
Member Avatar for charlottetemp
0
1K
Member Avatar for Tech B

I've seen a program called Devcon ([url]http://en.kioskea.net/faq/sujet-1886-enable-disable-a-device-from-the-command-line[/url]) used for enabling and disabling hardware devices. I want to do the same hopefully with python. I want to turn the internet connection off with a script. I can already do it with popen('ipconfig /release') but I want something more robust. Is there …

Software Development python
Member Avatar for Tech B
0
2K
Member Avatar for adams161

Hi, when i run my java program it has that little java coffee cup image in teh task bar. All my apps have this. i guess its default. How do you set that to something custom? i cant seem to come up with teh proper name for what that image …

Software Development image java
Member Avatar for adams161
0
82
Member Avatar for abhay1234

Dear sirs, I am trying to learn vb.net in 2005 and 2008.Where can i get good tutorials to learn basic as well as advanced. OOPs and web development etc. thank you

Software Development vb.net
Member Avatar for abhay1234
0
203
Member Avatar for OldQBasicer

In old QBasic I could use the LOG function to get the base-10 log of a number. So I would have something like this... [CODE]sglFormula = 150 - (LOG(intTemp + 10) * 30)[/CODE] ... the LOG function would give me the log base-10 of a variable (intTemp) plus 10. How …

Software Development vb.net
Member Avatar for OldQBasicer
0
119
Member Avatar for Shillz

can anyone guide me how to run a c++ program inclusive of graphics through notepad++ by using borland compiler OR plz guide me hw to compile n run a c++ graphics prog in vista..as it's not possible by normal tcpp

Software Development c c# c++
Member Avatar for CppBuilder2006
0
983
Member Avatar for jorgelex008

Hi all, I'm new to Java and going through a steep learning curve. Every now and then I'm getting dead stuck, so your help is immensely appreciated. So, here's the problem: (with Java NetBeans IDE) I have a JFrame form, and in it 4 JComboBox'es. Also a JButton titled "Enter". …

Software Development ide java java-netbeans
Member Avatar for javaAddict
0
7K
Member Avatar for san_fran_crisko

Hi, Apologies if this has been covered already - I searched but couldn't find anything relevant. I am looking to learn both of these languages mainly because I am in a bit of a dilemma career-wise. To be as concise as possible (this aint no agony aunt page I hear …

Software Development audio c++ career puzzle
Member Avatar for Narue
0
286
Member Avatar for mahela007

Is there someway I can parse badly written HTML code in python? I want to get some info from a web page which uses HTML tables for it's formatting and I found numerous flaws in the code using w3cs validator. can I parse this code in python?

Software Development html-css python
Member Avatar for mahela007
0
95
Member Avatar for jammiedude

Just downloaded Office 2010 to see what changes have been made in the VBA environment and all looks well. But i am having a big problem typing in my code! as soon as i type something it appears in red, it autocorrects so fast that if i type .range("A1") it …

Software Development visual-basic
Member Avatar for jammiedude
0
136
Member Avatar for explorepython

Hello all, After googling around for a few hours i can't find any example for passing arguments to an user-defined method in pyqt.. The only link i found related to this is [URL="http://www.commandprompt.com/community/pyqt/x1408"]http://www.commandprompt.com/community/pyqt/x1408[/URL] . In this example we have to make it to emit the signal and pass the argument.. …

Software Development python
Member Avatar for explorepython
0
1K
Member Avatar for JAM1011

Hey everyone. I am having problems trying to figure out how the user can select the times they want to start work at, the time they want to have from lunch and finally the time they would like to finish. I then would calculate the number of actual working hours. …

Software Development vb.net
Member Avatar for JAM1011
0
88
Member Avatar for Nikhar

Hi guys...I am learning binary trees and its quite interesting. But I am unable to make4 a the delete a node function in it. Whenever I try to delete a node, a fatal error occurs and the program closes. Can you please point the error out for me in the …

Software Development c++
Member Avatar for Nikhar
0
126
Member Avatar for Godflesh

Hello! I have more questions :) Is it possibe to create a "threadlock", "lock" if you use a file as a common resource? If you have a class that create data and put the data into a file and you have another class that will take data from the same …

Software Development python
Member Avatar for Gribouillis
0
104
Member Avatar for ayeshawzd

how can i find value of cos without using math library of c# .......plz send me code example or formula by which it ia possible i thank full to u

Software Development mathematics
Member Avatar for ayeshawzd
0
485
Member Avatar for NickT80

I am to create a superclass that has at least two data fields, a constructor and two other methods. Create two subclasses that inherit from the superclass each one of which adds at least one more field and at least one more method, one of which must be an 'over-riding' …

Software Development java
Member Avatar for javaAddict
0
78
Member Avatar for xfrolox

Ok i'M making a program for a game a tool software I made that when I press a button in another dialog it appear a text + textboxs.text so when I press a button it appears in the dialog but all in the same line how do I do that …

Software Development vb.net
Member Avatar for QVeen72
0
86
Member Avatar for Godflesh

Hello i have a big problem, i want to import queue but i get this message, somehow it dont exist. Traceback (most recent call last): File "D:\Python26\test.py", line 9, in <module> import queue ImportError: No module named queue isnt that strange.

Software Development python queue
Member Avatar for Godflesh
0
16K
Member Avatar for xfrolox

well the last thing i need is a button that will copy TextBox1.Text like Select All and Copy it all, i use a simple code no very effective... i put sendkeys ctrl & a and ctrl & c but i just realize that all pcs doesn't have the same hotkeys …

Software Development vb.net
Member Avatar for gatzaraki
0
121
Member Avatar for compovet

HI I'm trying to insert data in 2 tables one is the master and the other is the details table, let us say it is test details first table : the master data of the test (name,date,......) second table : the parameter details (masterID,parameter,value) I want to do that through …

Software Development
Member Avatar for compovet
0
171
Member Avatar for vaibhav2614

Hi everyone, I've been trying to code up a generic vector implementation in C, and the compiler has not been kind to me... Here is the struct I have defined in a file "vector.h." [CODE]typedef struct 72 { 73 int elemSize; 74 int logLength; 75 int allocLength; 76 int delta; …

Software Development c
Member Avatar for vaibhav2614
0
129
Member Avatar for theMediator

Hi, I'm building an application that reads barcode scanning data into multiple forms and textboxes. At the moment, to handle that data I have created a large nested if statement that checks to see which object has focus so that the scanned data is placed there and focus moves down …

Software Development vb.net
Member Avatar for theMediator
0
149
Member Avatar for checho

Hi, here is my problem. I have the next task //Write a program that removes from a given //sequence all the numbers that present in it odd //number of times. Example: //{4, 2, 2, 5, 2, 3, 2, 3, 1, 5, 2} {5, 3, 3, 5} The problem comes in …

Software Development java
Member Avatar for JamesCherrill
0
2K
Member Avatar for makdu

Hi, in order to organise the functions based on its usage, i want to add a new code file to the project. I tried to add a new code file and gave a name to it and then wrote a function in it . This function is called from another …

Software Development c#
Member Avatar for mahmoud_wow
0
239
Member Avatar for gunbuster363

I want to use MySQLDB to connect MySQL but I got a problem. the problem is: --------------------------------------------------------------------------------- cs6201:/home/lamwaiman/python/data # python dm.py Traceback (most recent call last): File "dm.py", line 11, in <module> import MySQLdb File "build/bdist.linux-i686/egg/MySQLdb/__init__.py", line 19, in <module> File "build/bdist.linux-i686/egg/_mysql.py", line 7, in <module> File "build/bdist.linux-i686/egg/_mysql.py", line 6, …

Software Development mysql python suse
Member Avatar for Stefano Mtangoo
0
384
Member Avatar for roadmaster

As the Title states I'm trying to Display a Form that has a Listbox Docked to "Fill", theres no problem displaying the form but I want to Display the Items in the ListBox as each line is added to it (in this case the lines are added programatically through the …

Software Development display
Member Avatar for roadmaster
0
107
Member Avatar for -ordi-

[CODE]import java.io.*; import java.util.*; class Telefon { public static void main(String[] args) throws Exception { /* IO */ BufferedReader sisend = new BufferedReader(new FileReader("telefon.sis")); // IN PrintWriter valjund = new PrintWriter(new BufferedWriter(new FileWriter("telefon.out"))); // Out int n = Integer.parseInt(sisend.readLine()); // Reading first integer String abi; String abi2; String[] numbrid = …

Software Development java
Member Avatar for javaAddict
0
96
Member Avatar for TheWhite

I have a class which extends LinkedList and implements Runnable. I also have a main class which modifies the extended LinkedList. So, the issue is, the LinkedList is being modified by 2 threads: main() in the main thread and run() in the thread which is created from implementing Runnable An …

Software Development java
Member Avatar for TheWhite
0
1K
Member Avatar for adams161

I have a gameboard class: class gameboard extends JInternalFrame In the constructor i have the line: setDefaultCloseOperation(DISPOSE_ON_CLOSE); my gameboards are actually in an array myboards[500] were each is an object of this class. the deal is I want to be able to tell which are open and i want to …

Software Development java
Member Avatar for adams161
0
102
Member Avatar for Hidden-Coder

G'day all, The program i'm currently working on has a search feature, I want to be able to search a Folder and any Sub-Folders contained within that structure. I'm really confused at the moment as to how i'm going to keep going deeper into a directory and still manage to …

Software Development
Member Avatar for Hidden-Coder
0
123
Member Avatar for Godflesh

Hello again! I have a new question. I have run a script and wants to run it again with a "keypress" input from the user, how do i code that. Like this: import subprocess drive=input(" If you want to start the script again , press 1: ") if drive == …

Software Development python
Member Avatar for Godflesh
0
2K
Member Avatar for Katsurou

Heyah Does anyone know how can I change the bacground color of my textfield by using : the commands if & else It's for one of my school assignments but I really can't get to solve it by myself i searched through web but nothing :S We must use the …

Software Development programming-construct visual-studio
Member Avatar for ddanbe
0
227
Member Avatar for iamcreasy

Im trying to solve a ACM problem 10189, LINK: [url]http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=13&page=show_problem&problem=1130[/url] It looks ok to me...but, online judge is showing wrong answer... can anyone help me to figure out the problem. [CODE]#include<stdio.h> int row = 1, column = 1,i=0, j=0, a=0, b=0; char array[100][100] = {0}; int change(int a, int b) …

Software Development c
Member Avatar for iamcreasy
0
204
Member Avatar for asm2hex

Hello, I have a quick question I want to ask. How can I copy the data from a allocated variable, so that when I free up the allocated variable the copied data isn't erased with it. Thanks, -A2H

Software Development c
Member Avatar for Narue
0
104
Member Avatar for ryy705

Java implements pass by reference right? So when I do cons("item", stack) with the following code I should print out --> itemabcd. But that isn't the case, why? String stack = "abcd"; cons("item",stack); System.out.println(stack); // public void cons(String item, String stack) { stack = item + stack; }

Software Development java
Member Avatar for tux4life
0
225
Member Avatar for jakesee

Hi, I am playing around and trying to understand template singleton class and I accidentally created something that I am surprise it even runs. What I don't understand is when did Apple and Orange instances get created? Could you also comment on the good and bad of the Singleton class …

Software Development apple c++
Member Avatar for jakesee
0
486
Member Avatar for TheStig01

Hi all, So i basically created a database with an arraylsit. All the data is stored in the arraylist and is added by a stringLine. [B][U]All this is shown in the code[/U][/B] My Database is an Insurance Database. Well basically i'm finding it hard to find out how to actually …

Software Development java
Member Avatar for TheStig01
0
215
Member Avatar for freesoft_2000

Hi everyone, I have quite a problem. I have a text pane and three menu items which are cut copy and paste. In my textpane i have some text and an embedded icon. when i select all the contents of the textpane and click cut all the contents of the …

Software Development api email java
Member Avatar for javaAddict
0
2K
Member Avatar for JAM1011

Hi there , Just wondering if anyopne could help me out with a problem I am having with a update statement. I this error [I] ExecuteNonQuery: Connection property has not been initialized.[/I] I have been at this all day and still can't figure the problem. Hope someone can put a …

Software Development open-source vb.net
Member Avatar for JAM1011
0
165
Member Avatar for flying_bird

Hi guys, The following code doesn't compile, and I've been banging my head why. Some header code: [code] template <typename T, typename LESS_THAN> class RestrictedSet { private : int _size; int _max_size; set<T, LESS_THAN> _S; typedef typename std::set<T, LESS_THAN>::iterator tIt; public : RestrictedSet (int max_size); RestrictedSet (RestrictedSet<T, LESS_THAN> &other); ~RestrictedSet …

Software Development c++
Member Avatar for flying_bird
0
772
Member Avatar for Excizted

Hi people. :) I'm making a function callback system for a console, so I would dynamically be able to send a function pointer to my console class, and then it would be callable from the console. Well, it works - but only with functions that are not member of a …

Software Development c++
Member Avatar for Ancient Dragon
0
259
Member Avatar for pac-man

Hi guys, just playing about with pointers and keywords and to my surprise, this code does not throw up an error... can anyone tell me why? [CODE] int main() { int *P = new int; *P = 50; cout << *P << endl; // output: 50 delete P; *P = …

Software Development c++
Member Avatar for pac-man
0
125
Member Avatar for NoviceChrilill

Hi, I have the problem that a char ch2 = '\u0041' is confirmed as a character and also printed as "A", but the char ch3 = '\u00c6' , which is also confirmed as a character, is not printed only as a "?" where it is supposed to be a "æ". …

Software Development
Member Avatar for NoviceChrilill
2
259
Member Avatar for jen140

Hello again. I was trying to login to my web server protected with basic auth, and after i understood that it would be nice to automatically detect the realm so now i want to know on how to do so. Thanks in advance.

Software Development perl web-server
Member Avatar for jen140
0
442
Member Avatar for gu0gu0

hi, i debug it keeps show: Syntax error in FROM clause. i google and read many website tried remove ' ' from sql line still cannot. can anyone help pls [code] Public Class frmLogin Dim mypath = Application.StartupPath & "\password.mdb" Dim Password = "" Dim conn As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\Users\Du\Documents\password.mdb") …

Software Development open-source vb.net
Member Avatar for gu0gu0
0
107
Member Avatar for kplcjl

How does a property that returns a byte[,] signature have the same parameter types as a function that returns a bool and has a passed byte[,] signature? Here is the command: ...My Documents>csc /target:library /out:CourtneyNumbrs.dll CourtneyNumbrs.cs here is the output: Microsoft (R) Visual C# 2008 Compiler version 3.5.30729.1 for Microsoft …

Software Development
Member Avatar for kplcjl
0
116

The End.