43,549 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for Robert955

Hi, I am making a 2D game with XNA 3.1 where I want to make my space ship move with the arrow keys. atm when I press left or right arrow the ship rotates around its own axis. but now I want to make it fly into the direction its …

Software Development
Member Avatar for Robert955
0
77
Member Avatar for eman 22

[CODE] int main(){ // I have an error in the next line read_file("F:/2nd year_2/Data structure 2/books/lecture-26.pdf"); return 0; } string read_file(char* address){ string line; ifstream myfile (address); if (myfile.is_open()) { while ( myfile.good() ) { getline (myfile,line); cout << line << endl; } myfile.close(); } return NULL; }[/CODE] this program …

Software Development c++ data-structure pdf
Member Avatar for eman 22
0
139
Member Avatar for Rockpile

Hello, is this a bug? I get different results when I run this from command prompt and IDLE. [CODE] name = input('Hello what is your name: ') print('Hello ' + name + '.') [/CODE] From IDLE, it works correctly. The result shows as Hello Bob. If I run the program …

Software Development python
Member Avatar for vegaseat
2
448
Member Avatar for Ancient Dragon

I tried to write up a test program that uses std::copy and istream_iterator to copy one text file to another. But it doesn't work because the '\r' and '\n' in the file are lost. I've tried opening the input and output files in text mode and I've tried opening them …

Software Development c++ ios
Member Avatar for vijayan121
0
717
Member Avatar for caut_baia

Is this ok to do or have i forgot my manners?Thank you [code] struct A { virtual A* func()=0; }; template <typename T=int> struct B : public A { A* func () { return this; } }; typedef B<> B_int; typedef B<float> B_float; struct C : public B_int { A* …

Software Development c++
Member Avatar for caut_baia
0
134
Member Avatar for jmalbornoz

Hi, I have been programming in C for some time and now I am trying my hand at C++. As we all know, global variables are baaaaad... However, I am developing a collection of classes and I need them all to share a common variable (a time step) whose value …

Software Development c++
Member Avatar for jmalbornoz
0
3K
Member Avatar for mg120

I am trying to seperate JTextArea colums as you can see on the pic. How can i do that any idea ?

Software Development java
Member Avatar for mKorbel
0
73
Member Avatar for Falcon25

Hi i'm new to C# and programming in general. First of all this site has been very helpful and I was wondering if someone could explain what constructors are to me as simple as possible. I'm teaching myself at home and the book is either not very good or i'm …

Software Development
Member Avatar for Falcon25
0
80
Member Avatar for jamshed ahmed

in below code there is syntax error in from Clause but i think every thing looks fine iam using access database thx and relation is fine between thes two table [CODE] Public Function GetGridData() As DataTable Dim dt As New DataTable Try Dim con As New Connection() Dim cmd As …

Software Development vb.net
Member Avatar for jamshed ahmed
0
98
Member Avatar for saddas

hello i have a form and a database linked by SQL. i have checkboxes in the access database that are ticked when a product is sold is there a way to make a checkbox in access tick once the product has been selected in the form? thanks, help would be …

Software Development visual-basic
Member Avatar for reygcalantaol
0
107
Member Avatar for Bladtman242

[B]TL;DR:[/B] I am asking for help considering the structure on the following code, and advice on code structure in general. The problem in this case is the try blocks, which are messing up the scopes and complicating error handling. I will elaborate a little for the more patient readers below …

Software Development file-stream file-system java
Member Avatar for Bladtman242
0
228
Member Avatar for Limiter

A very small problem I am having. Here is an example: A class representing a book [CODE] public class Book { private String title, author; //Constructor for book public Book (String name, String writer) { title = name; author = writer; } [/CODE] Another class called Bookshelf representing a collection …

Software Development java
Member Avatar for Limiter
0
2K
Member Avatar for stereomatching

[code] std::tr1::array<double, 10> alpha; std::iota(alpha.begin(), alpha.end(), 0); using namespace boost::accumulators; size_t const SIZE = 1000000; accumulator_set<double, stats<tag::mean, tag::lazy_variance > > acc; std::for_each(alpha.begin(), alpha.end(), [&](double const VALUE){ acc(VALUE);}); [/code] How could I clear the contents of the acc if I want to evaluate a new mean and variance? Thank you very …

Software Development c++
Member Avatar for vijayan121
0
879
Member Avatar for tim.newport

Ok So I am trying to save text from a textbox to a rtf file. The Saves Text would come from the active mdi Child. However I can not figure out how to Save using active child just calling the actual form name. Below is my code so far. [CODE]Private …

Software Development vb.net
Member Avatar for tim.newport
0
768
Member Avatar for rookanga

Database edit then save problem Im trying to make a database and for the most part it works. The form1 has add new button (which goes into my form2 window that adds all of the information there, then I hit save, when I exit it and comes back to the …

Software Development vb.net
Member Avatar for rookanga
0
611
Member Avatar for rhuffman8

I wasn't sure which section to post this under but I am working on an assignment in SQL and have created a batch file to make the tables, load the data into the tables, and then sends several queries to sql to get results. Is there a way I can …

Software Development sql
Member Avatar for rhuffman8
0
174
Member Avatar for Carrots

Hi, I am new to C# and Forms/GUIs. Basically I am trying to pass a value in a textBox to my programs program.cs file where I can apply my programs logic, but I'm stuck with how to do this. To get started all I am making is a form which …

Software Development c c# c++ gui visual-studio
Member Avatar for Carrots
0
2K
Member Avatar for IamAuser

Hello all, here is the code I came up with for implementing a circular linked list. I get a segmentation fault when I create the list with just one node. With size > 1 circular list works fine! Im not sure but I think it may have something to do …

Software Development c++ linked-list
Member Avatar for IamAuser
0
272
Member Avatar for leo88

hi there, i got some problems in extract the minimum value in a sortedlist, as below: [code] Dictionary<string, double> sortList = new Dictionary<string, double>(); double min; sortList.Add(1,2); sortList.Add(2,5); // min = sortList5.Min(x => x.Value); [/code] I wants to find minimum value of the sortlist.value, is there has any functions of …

Software Development
Member Avatar for leo88
0
7K
Member Avatar for Taimoor Rana

hey guys, I drew many lines for the purpose of my project but for some reason, I cannot draw this specific line[U](code line 44)[/U] and cannot figure out why. Note: I have debugged the code and this code line is red by Java but it's not applied to the graphic. …

Software Development java java-swing
Member Avatar for Taimoor Rana
0
144
Member Avatar for CrankyMero

Hello Everyone, I have this small system that i developed for a company that is basically a Skill Map for the employee's, so in the following image will show the search of the employee's skills through the Family, in the following image the users does a search of the family …

Software Development vb.net
0
95
Member Avatar for elvis1

Hi guys. Im very new to C#. I am trying to make use of Tamir.SharpSSH.dll to be able to allow users to perfom actions in a linux console without the needed knowledge. Ive done right click over references --> add references --and Ive browsed -->Tamir.SharpSSH.dll. This is when I stall …

Software Development
Member Avatar for elvis1
0
150
Member Avatar for Suzie999

I'm having big trouble understanding this. [CODE]namespace nspace { public class eclass { public double elevation { get; set; } } public class Program { static void Main(string[] args) { eclass first = new eclass(); first.elevation = 500; Console.WriteLine(first.elevation); Console.ReadKey(); } static void setup() { Console.WriteLine(eclass.first.elevation); // line dosent work …

Software Development
Member Avatar for Momerath
0
110
Member Avatar for ShailaMohite

i am create one mdi application in c# dot net. mdi form contain many child forms when open one child form and again open this child form then open 2 times this child form please help me to open one child form at a time in this application

Software Development
Member Avatar for vivekagrawal
0
855
Member Avatar for Morten Brendefu

I am trying to draw a few items on a canvas using Canvas.TextOut mainly. My problem is that when I grab the form holding the canvas and then move the form outside of the screen and back again, all text and drawings have vanished, as if they have been erased. …

Software Development pascal printer
Member Avatar for Wolfgan
0
141
Member Avatar for TrustyTony

[URL="http://www.pyside.org/"]PySide[/URL]: Python for Qt 1.0 released! The PySide team is thrilled to announce the release of PySide: Python for Qt version 1.0.0. In addition to the source code release, project community packagers have already released binary packages [developer.qt.nokia.com] for all major Linux distributions, Microsoft Windows, Mac OS X, and Nokia’s …

Software Development microsoft-windows os-x python qt
Member Avatar for e-papa
2
420
Member Avatar for pmark019

[CODE] #include <iostream> #include <sstream> using namespace std; int main() { int a, b; string s = "34:22"; istringstream ins; ins.str(s); ins >> a >> b; cout <<a <<b; } [/CODE] This is my code and I want to ignore the ":" in string s. The outpout should be 3422. …

Software Development c++
Member Avatar for pmark019
0
1K
Member Avatar for yozzie

Alright - this is my conundrum. As a noob to C++ I am only in chapter 9 of my book, having just covered object oriented programs and the exciting world of vectors and arrays. I have an assignment that asks me to run a loop to get and calculate a …

Software Development c++ data-structure
Member Avatar for yozzie
0
2K
Member Avatar for satti

iam facing a problem ,i want to add a form to my project from another project,when i add the form and try to run it give me error,i dont know what is the problem i have added its module and database also but still giving me [COLOR="Red"](ERROR:Run time error 3709 …

Software Development visual-basic
Member Avatar for reygcalantaol
0
170
Member Avatar for Morten Brendefu

I am designing a lot of TCheckBox at runtime, and uses mathematical formulas for placing these in columns and rows afterwards on a form. I assign an on click event that is exactly the same on all of them, and everything work, except... Color. My OnClick event is made like …

Software Development delphi pascal
Member Avatar for Wolfgan
0
3K
Member Avatar for MUFC4life

Hello, i have to write a piece of code that allows me to open a txt file which then tells me the amount of each letter there is in the document. However i have this code which opens the document but instead of telling me how manu letters it lists …

Software Development python
Member Avatar for MUFC4life
0
125
Member Avatar for bhattpratik

Hello! I want to know exactly What Is [COLOR="Green"]Difference[/COLOR] Between The [COLOR="Red"]FileFilter[/COLOR] and [COLOR="Red"]FileNameFilter[/COLOR] in java.io.*; Do they both work the same ? Please answer ....... [B]-> {Pratik Bhatt}[/B]:)

Software Development java
Member Avatar for bhattpratik
0
2K
Member Avatar for ZER09

Hello to all, I got problem in my vb.net program in publishing it. I am using Microsoft Visual Studio 2008, when I publish my program and I got the setup file and when i tried to run into another computer I got some error saying that it cant connect into …

Software Development digital-publishing mssql vb.net
Member Avatar for bincly
0
170
Member Avatar for Cassandra Low

Hi, I'm currently trying to store all the text in text area into a txt file in directories using java. I know how 2 use mkdirs() to create directories, for example C:/d1/d2, but if i type [CODE](new File(C:/d1/d2/sample.txt)).mkdirs()[/CODE] it makes the txt file into a folder too. I tried with …

Software Development java
Member Avatar for mKorbel
0
153
Member Avatar for Cap'nKirk

I recently had a PC crash and had to do a fresh install of Win XP. Luckily I had backups of a vast majority of my data including my VS projects. I have just reinstalled VS2010 Ultimate and then decided to open my latest project only to be told that …

Software Development
Member Avatar for Cap'nKirk
0
126
Member Avatar for Atistus

I am having a little bit of trouble with loops. [CODE] mainTest = "Menu:\n(R)enter Numbers\n(O)dd or Even\n(S)um and Average\n(Q)uit\nWhat would you like to do?: " getInteger1 = input("Your first number?: ") getInteger2 = input("Your second number?: ") print mainTest while userInput != '': if userInput == 'r' or 'R': #This …

Software Development python
Member Avatar for TrustyTony
0
140
Member Avatar for lielee

Hi. My problem is, the data that I pull from the database, when try to multiply it, it didn't multiply. The database has Fruit and FruitPrice column. When select fruit form the combo box, it will search the price. But I can't seem to multiply it. The price is display …

Software Development open-source vb.net visual-studio
Member Avatar for lielee
0
160
Member Avatar for EMT

Hi, In my python application I am importing my module from a xyz[B].[/B]dll. When I try to import my module from the xyz[B].[/B]dll the python shows error no xyz module found. But after [B]renaming the xyz.dll to xyz.pyd[/B] the same python code ([COLOR="Red"]without any change[/COLOR]) imports my module easily. The …

Software Development python
Member Avatar for TrustyTony
0
602
Member Avatar for Pascode

Hi, Im new to c++ and this site but I have been reading it for the last few weeks to month. I have a problem with a battleship game im trying to finish. Basically I have the random and custom boards working, the function to prevent overlapping and placement off …

Software Development c++
Member Avatar for Pascode
0
180
Member Avatar for satti

Hi , i use enable choice function to enable or disable the ADD button for data grid. now when i tried to use the code for update button its not working.. need to add cmdUpdateEntry. here is the code..[CODE]Sub EnableChoice() ' disable to remove button ' check to see if …

Software Development visual-basic
Member Avatar for satti
0
223
Member Avatar for sarifah n

Hi, I want to ask how to add/insert new row/record and it show at the top in datagridview. i don't want the new add record at the bottom but i want it at the top. I mean,the current is at the top in datagridview. i'm adding the new record is …

Software Development vb.net
Member Avatar for sarifah n
0
3K
Member Avatar for Jake.20

Guys, i have a question. Is it possible for datagridview to be use for a time-in, time-out program?

Software Development vb.net
Member Avatar for codeorder
0
105
Member Avatar for sarifah n

hi, i want to ask about keyevent when keypress on form load in a function. what i want is when i click "F2" then the key of "F12" and a button is enabled=false. Anyone, please help me..:?: thank you.

Software Development vb.net
Member Avatar for sarifah n
0
92
Member Avatar for fibbo

Alright, I suspect there is already a solution here somewhere on the forums but I'm not quite sure I'm searching for the right terms so I hope you dont mind me asking the question anyway. My goal is to make a constructor for a class called building. instance variables are: …

Software Development c++
Member Avatar for mike_2000_17
0
2K
Member Avatar for kazekagerandy

how can i zoom an image inside a picturebox? and i also want to know how can i make a picture inside the picturebox draggable while at the same time, it can be zoomed in and out. my goal is to crop an image inside the picturebox and i can …

Software Development image vb.net
Member Avatar for kazekagerandy
0
2K
Member Avatar for kipslem

Hello, Could someone help me with this one? I have developed a small application. It has a MDIParent form on which the other childforms are displayed. I have a Panel on the MDIParent on which there are buttons to call up the MDIChild forms. Now my issue is, when anyone …

Software Development display gui vb.net
Member Avatar for kipslem
0
694
Member Avatar for Mr.BunyRabit

Hey there. Now Reaaaaly close to finishing my project =), had a bit of scope creep with the person we are doing the project for. uffff, yea i know... so now im saving all the details to my mysql database. like this field. "name" of the person, i would save …

Software Development mysql
Member Avatar for Mr.BunyRabit
0
126
Member Avatar for inzombiak

Im writing a program that creates matrices and what not then count different things based on the elements in the matrix. That all works fine except 1 part, dividing 2 specific numbers. What htis is for isint important because everything works fine EXCEPT that one part. Anyway, im supposed to …

Software Development c++
Member Avatar for VernonDozier
0
106
Member Avatar for SMITA6076

I'm working on a CyberPet assignment and I'm not sure how to do the following: 'Then write an [ICODE]encounter ( CyberPet )[/ICODE] method that allows one CyberPet to encounter another and will describe the encounter by returning a String data type. Note that the method should take a CyberPet parameter. …

Software Development java
Member Avatar for SMITA6076
0
599
Member Avatar for stefilina

Hy! I want to improve the design of my windows application.I've searched a lot on google but i couldn't find anything good. Can everyone please tell me some web addresses or maybe turorials were I can find stuff about the design of a windows application?Something like a special form for …

Software Development web-design
Member Avatar for stefilina
0
131

The End.