43,549 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for stephen lowry

hi guys this is probley simple and i have an external board controlling various things on the board is a button which i would like when pressed activates code within a button on my vb form i have tried button1.select but that only well selects the button on my form …

Software Development vb.net
Member Avatar for Luc001
0
139
Member Avatar for isayas

#include <iostream.h> void main () { int i,j,temp,smallest; int list [10]; for (i=0;i<10;i++) { cout<<"enter a number\n"; cin>>list[i]; } for (i=0;i<10;i++) { smallest=i; for (j=i+1;j<10;j++) { if(list[j]<list[smallest]) smallest=j; } temp=list[smallest]; list[smallest]=list[i] list[i]=temp; { for(i=0;i<10;i++) cout<<list[i]<<endl; getch(); }

Software Development c++
Member Avatar for avarionist
0
130
Member Avatar for avarionist

i realize the topic isnt much descriptive but i thought that my code was a bit strange so i hope dw can give me a bit of info this is the most random thing ive ever made. on windows it produces quite a bit of ruckus in the console but …

Software Development c++
Member Avatar for avarionist
0
243
Member Avatar for nortech

Hello All, I am currently in the process of adapting an application that previously worked only with Microsoft Access to work with SQL server or Access. Previously, all database interaction was designed based upon using the XSD file to create queries (etc). I wasn't sure how to handle the new …

Software Development microsoft-access web-server
Member Avatar for nortech
0
180
Member Avatar for carylle

Can someone please help me. I want to call an MS Word Document in my system using VB.net what should be the syntax? Thanks!

Software Development vb.net
Member Avatar for augamal
0
285
Member Avatar for gingerfish

Please help me =( I'm not native english speaker, therefore some things might be not clear here I have 2 separate files: [B]Main.java[/B] and [B]Open.java[/B] inside [B]main.java[/B] there is a GUI and it has a [B]JTextArea[/B]) where i want to show text (variable) called from [B]open.java[/B] in [B]Main.java [/B] i …

Software Development gui java java-swing
Member Avatar for adams161
0
3K
Member Avatar for Jeramy

Be aware this is going to be ugly because I have never written anything in python and am attempting to quickly pick up just enough to solve my problem. I need a way to automate doing about 2 weeks of daily archives of a backup file. I think I have …

Software Development python storage
Member Avatar for Jeramy
0
110
Member Avatar for DelilahDemented

I'm doing this simple program that checks for number validation and I have an infinite loop in it. I can't figure out how to stop it. It's supposed to check for numeric digits only, but when it finds something other than the above, it hangs up in the loop. Could …

Software Development c c# c++
Member Avatar for DelilahDemented
0
237
Member Avatar for Jesi523

Hi, I have a question please I am using a DetailView to Insert into a SQL Server database. I then want to get the last identity id and use it at the end of url to redirect it to another page. I've done a lot of research and I think …

Software Development asp.net
0
81
Member Avatar for YasaminKh

Hi, I'm writing a code that takes a file name from user and opens it if it exist and if it doesn't asks for another file name. What i wrote is this: [CODE] #include <iostream> #include <string.h> #include <string> #include <stdlib.h> using namespace std; int mani() { string input; cout<<"please …

Software Development c++ file-system
Member Avatar for YasaminKh
0
111
Member Avatar for Mitja Bonca

I would like to know why sql query for month and year is working, and i[B]s not working for day[/B]: [CODE] string myQuery = "SELECT StudentName FROM Students WHERE " + "YEAR(Birth) BETWEEN @yearFrom AND @yearTo AND " + "MONTH(Birth) BETWEEN @monthFrom AND @monthTo AND " + "DAY(Birth) BETWEEN @dayFrom …

Software Development sql
Member Avatar for finito
0
120
Member Avatar for echellwig

Hi, I'm looking to break up a file with space delimiters. Its really just a list of numbers with spaces in between them, and I need to put each of the numbers in a list as separate entries. However, they are all on one line like so: 5 7 6 …

Software Development python
Member Avatar for echellwig
0
180
Member Avatar for bbman

Hey, I apologise for the noobishness of this question, but I am unable to move the form. [CODE] if (Screen::PrimaryScreen->Bounds.Top != Screen::PrimaryScreen->WorkingArea.Top) { this->Left = Screen::PrimaryScreen->Bounds.Right - this->Width; this->Top = Screen::PrimaryScreen->WorkingArea.Top; } else if (Screen::PrimaryScreen->Bounds.Left != Screen::PrimaryScreen->WorkingArea.Left) { this->Left = Screen::PrimaryScreen->WorkingArea.Left; this->Top = Screen::PrimaryScreen->WorkingArea.Bottom - this->Height; } else { this->Left …

Software Development c c# c++
Member Avatar for jonsca
0
130
Member Avatar for madzam

I'm took an fundamental of C++ . Here is my code, could you please help me to point out the error . Thanks [CODE]#include <iostream> #include <cstdlib> #include <iomanip> #include <string> using std::cout; using std::cin; using std::endl; using std::string; using std::fixed; using std::setprecision; int main() { int unit_of_desks = 0; …

Software Development c++
Member Avatar for nbaztec
0
115
Member Avatar for dhruv_arora

What's the differences between exit(0), exit(1) and exit(-1)?

Software Development c++
Member Avatar for dhruv_arora
0
117
Member Avatar for TommyRay

Hi, I am using VS2008 and for the project I am creating, I have a "settings" text file I am using to save user defined settings like color theme, homepage, etcetera. It works fine, however, I am unsure as to how to handle the eventual distributed apps' destination folder/file. Creating …

Software Development file-system vb.net
Member Avatar for TommyRay
0
152
Member Avatar for gangster88

atlast I have managed to get some working code but the first problem is that I have is taht.. when I call draw(2,4) I have a column of 2 circles and 4 rows and I would actually like it to be a clomun of 2 and row of 4. Secodly …

Software Development python
Member Avatar for gangster88
0
183
Member Avatar for darelet

Hi all, I've been trying to work on solving this myself but failed short of new ideas. I am experiencing memory heap errors ever since I tried to transfer some functions (for calculating statistics i.e. getMode/getMean/getVariance) into a new class in the spirit of OOP. Compiler error is... --> This …

Software Development c++ oop
Member Avatar for mitrmkar
0
383
Member Avatar for Simes

Guessing Game with functions, classes, methods, etc [CODE=python]#Code should always be in a method or class #Always start variable names with lowercase, classes could be capital #input.upper() allows the user to use lower or upper case for each option import random from operator import itemgetter def isint(x): try: int(x) return …

Software Development python
Member Avatar for TrustyTony
0
282
Member Avatar for bubacke

hi, i want to have a vector of strings. i know i could declare it by [code] #include <iostream> #include <string> using namespace std; vector<string> vec; vec.push_back("this"); vec.push_back("is"); vec.push_back("my"); vec.push_back("array"); [/code] but thats very tedious. isnt there a more elegant way? if i had the vector as an argument to …

Software Development c++
Member Avatar for bubacke
0
193
Member Avatar for amishosh

Hi! I copied and pasted a grapics.h example from the help>index in borland C. When I try to run it the compiler gives me 9 error messages, all going something llike this: Linker error: Undefined symbol _closegraph in module "my file name" here's the example: [code] #include <graphics.h> #include <stdlib.h> …

Software Development c
Member Avatar for leduduong
0
430
Member Avatar for Valaraukar

Ok, so I'm really after knowledge rather than a quick easy solution here. I am part of a team that is currently working on the development of a 'kind of' physics engine but I have hit a small wall since adapting the functionality of a class which was previously working …

Software Development c++
Member Avatar for Valaraukar
0
202
Member Avatar for bbman

Hey, I have an item class: [CODE] #pragma once using namespace System; using namespace System::Drawing; ref class Item { public: Item(void); int Type() { return _type; } void Type(int value) { _type = value; } String ^ Text() { return _text; } void Text(String ^ value) { _text = value; …

Software Development c++
Member Avatar for jonsca
0
130
Member Avatar for dhruv_arora

I created this function for my program : [CODE]int calcTotal() { petShop p; fstream f1; f1.open("Pet_Shop.dat",ios::app|ios::binary); int loc; loc=p.tellp(); float records; records=loc/sizeof(p); cout<<"Total number of records = "<<records; cout<<"Going back to main menu"; menu(); }[/CODE] I am getting this error : [CODE]error C2039: 'tellp' : is not a member of …

Software Development c++ ios
Member Avatar for dhruv_arora
0
100
Member Avatar for genie0582

I tried to debug Macro variable but i cannot. I use Dev c++ [CODE]#include<stdio.h> #define TIME 5 int main() { int i=TIME; printf("%d",i); }[/CODE] when I run it, of course it gives correct result. but when I debug, it reports "TIME = not found in current context"

Software Development c
Member Avatar for Adak
0
106
Member Avatar for Sarevok19

Hi. I am trying to write server side windows forms application that supports multiple clients. What I want is following: 1) I need an infinite while loop to accept new connections. In order to do that I start new thread which executes while loop. I can't execute while loop without …

Member Avatar for nick.crane
0
513
Member Avatar for gokul.raja

Hi, I have a problem in repainting in a JPanel. Situation: I have a ButPanel which extends JPanel. In this panel I draw some sequences with some text along with it, by overriding paint() method. Eventually the screen size exceeds as input increases I use a CompareFrame which extends JFrame. …

Software Development java java-swing
Member Avatar for gokul.raja
0
110
Member Avatar for 1x4n

hi all i want to create an xml file from an array i've been googling but can't find the right one the closest one that i get is in [URL="http://www.higherpass.com/java/Tutorials/Building-Xml-With-Java-And-Dom/"]http://www.higherpass.com/java/Tutorials/Building-Xml-With-Java-And-Dom/[/URL] but it doesn't create an xml file like i wanted to i want to print and create it like c:\xml …

Software Development java xml
Member Avatar for 1x4n
0
182
Member Avatar for aj79

I am working in Microsoft Visual C++ 2008. Here is my sum of digits code: [CODE]#include <iostream> using namespace std; int main() { int num; int sum=0; cout << "Number, please? "; cin >> num; while (num>0) { sum=sum+num%10; num=(num-num%10)/10; } cout << "Sum of digits: " << sum << …

Software Development c++
Member Avatar for aj79
0
215
Member Avatar for Zinderin

I know you guys MUST be tired of scope questions ... but I need some help getting through this fog ... The following code works ([I]notice where I instanced 'cp'[/I]) .... [CODE] public partial class frmMain : Form { ConnectParams cp = new ConnectParams(); public frmMain() { // Fires up …

Software Development c#
Member Avatar for Zinderin
0
155
Member Avatar for daviddoria

I hear perl is the way to go for string parsing, so here is the test! I have a file like this: [code] ... <li><a href="DSC_9866.JPG"> DSC_9866.JPG</a></li> <li><a href="DSC_9867.JPG"> DSC_9867.JPG</a></li> ... [/code] and I want to get a list of the file names. That is, the result I want is …

Software Development perl
Member Avatar for daviddoria
0
90
Member Avatar for mack00234

I have been trying to use a wxPython textctrl to display a list of files, but it did not fit my purposes. The wx.StaticText seemed useful, and a ll works except for one major kink; I don't know how to scroll it. Moved post to its own thread, since the …

Software Development python
Member Avatar for mack00234
0
876
Member Avatar for uhmyeah

i am pretty new to c++ and dark gdk. im trying to make a simple platform game to start off. i have the basic controls down, the animations, and collision. but i am having much trouble finding how to create the effects of gravity. please help.

Software Development c++
Member Avatar for nbaztec
0
168
Member Avatar for Kanoisa

Hi everyone, I'm not so sure if this belongs in here or in computer science but I think as I want to use c++ this may be the place. I was wondering if anyone could point me towards some tutorials/references or books on methods for approaching the design of larger …

Software Development c++ opengl visual-basic visual-studio
Member Avatar for Bench
0
144
Member Avatar for morelve

I want to make a native win32 program that simply moves the cursor to x=100 y=200 on the screen, and then clicks the left mouse button once. Where do I start? For once, Google got me nowhere. I use VC++ 2010 to compile.

Software Development c pc-peripheral windows-api
Member Avatar for Adak
0
3K
Member Avatar for ashish2234

I know its silly but once i tried this and output is not what it should be.. [code] #include<stdio.h> #include<conio.h> int main() { int i=0; i=i++; printf(i); } [/code] i MEAN post increment will store a value, say 0 here.and then increment but that value is given to the variable …

Software Development c
Member Avatar for genie0582
0
310
Member Avatar for Dimansu

Hi, I am using RDLC in my reports.Can someone tell me the syntax for IF THEN ELSE statement in RDLC? I want to write else if loop in my expression. Thnx in Advance

Software Development asp.net
Member Avatar for chan_lemo
0
3K
Member Avatar for aladar04

i am newbie in java programming. So as a beginner, i need to understand technical terms from developers like you. Please answer the question in a way that a beginner like me would understand. I don't like links, i want a definition from you. Thanks a lot in advance.

Software Development java
Member Avatar for JamesCherrill
-1
72
Member Avatar for Olliepop

This code should get one random line from sample.txt and put it in Label1 - problem is that it's only getting line 2. Every single time. What's wrong with it? Please help. I bet it's something rediculously obvious but i can't find it :'( Thank you so much in advance. …

Software Development vb.net
Member Avatar for Olliepop
0
113
Member Avatar for IconKana

Hi folks, I'm wondering how to close a VB6 multiform application using the red x on the main form. There should be a message box that lets the user confirm the exit ( yes ), or ( no ) resume the application. Thank You!

Software Development visual-basic
Member Avatar for kinwang2009
0
117
Member Avatar for frankinaround

hi. wondering if someone can take a few min to help me out. Well im taking this opencourseware from MIT, intro to programing. I got this assignment [url]http://ocw.mit.edu/courses/electrical-engineering-and-computer-science/6-00-introduction-to-computer-science-and-programming-fall-2008/assignments/pset9.pdf[/url] and I could do it on my own... the only problem is I dont understand what the hell they want me to …

Software Development engineering pdf python
Member Avatar for TrustyTony
0
264
Member Avatar for iamcreasy

This code is supposed to get one int and one string.But after entering the int, the [B]getline[/B] line is acting weird...it dont prompt me for any string input, rather then it shows the same value as the int. [CODE]#include<iostream> #include<string> using namespace std; int main() { int teacherID; string teacherName; …

Software Development c++
Member Avatar for Bench
0
438
Member Avatar for DelilahDemented

I'm trying to use a switch statement in my code but I'm having a bit of difficulty. I have an error message I do not understand and do not know how to fix. The message reads, "switch quantity not an integer". I'm new to C++ and would appreciate any help …

Software Development c++
Member Avatar for arkoenig
0
222
Member Avatar for Alex_

Hi, i want to do a listener and this is what i have at the moment: [code] class MyListener extends MouseInputAdapter implements KeyListener{ @Override public void mousePressed(MouseEvent e) { if(e.getButton()==1){ out.println("MSE press "+e.BUTTON1_MASK); }else if (e.getButton()==2){ out.println("MSE press "+e.BUTTON2_MASK); }else if (e.getButton()==3){ out.println("MSE press "+e.BUTTON3_MASK); } } @Override public void …

Software Development java
Member Avatar for Alex_
0
164
Member Avatar for seena_srini

Hi I'm devolping a project in which backend is ms access and front end is vb 6.0. For security reasons i made the ms access as password protected. when i tried to connect the vb and access, the following message is displayed. How to handle it? Please help me.. [IMG]http://i48.tinypic.com/ddyge0.jpg[/IMG]

Software Development visual-basic
Member Avatar for bhrain
0
1K
Member Avatar for muthulazmi

import MySQLdb db = MySQLdb.connect(host = "localhost",user = "root",passwd = " ",db = "TESTDB" ) cursor = db.cursor() sql = """CREATE TABLE CRAWLER ( FIRST_NAME CHAR(20) NOT NULL, LAST_NAME CHAR(20), AGE INT, SEX CHAR(1), INCOME FLOAT )""" cursor.execute(sql) db.close() when i execute this code there is an error occure like …

Software Development python
Member Avatar for muthulazmi
0
91
Member Avatar for trelek2

Hi! I'm writing a Java simulation of a physical system. I wrote the whole simulation without any problems and later decided to add very simple GUI to paint the current sate of the system after each iteration. This is where the first problem occurred. After creating my JFrame and JPanel …

Software Development gui java java-swing
Member Avatar for trelek2
0
200
Member Avatar for muthulazmi

how to install the msqldb package and where to place it in python? then when i compile the code there is an error like no module named MySQLdb.... pls clarify this....

Software Development mysql python
Member Avatar for muthulazmi
0
106
Member Avatar for Hawkpath

Hello All! I ran across a bit of code that I wanted to try. In this code it had a line reading, "[COLOR="Red"]orig = POINT()[/COLOR]" When I tried to run I got this error: [COLOR="red"]NameError: name 'POINT' is not defined[/COLOR]. This led me to believe that I didn't have the …

Software Development python
Member Avatar for Beat_Slayer
0
126
Member Avatar for iamcreasy

I am trying to grab some data after opening a text file with append flag. I am using the following code...but nothing is being printed and program execution is progressing forward. Can anyone point me my mistake... [CODE] fstream outStream("test.txt", ios::app);string testID; cout << "Enter Teacher ID - "; cin …

Software Development c++ ios
Member Avatar for iamcreasy
0
341

The End.