43,549 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for sciwizeh

hello, i'm making a small calculator program, and i want the display to look like this: [URL="http://www.freewebs.com/sciwizehgames/images/want.jpg"]want.jpg[/URL] but i'm getting this: [URL="http://www.freewebs.com/sciwizehgames/images/Getting.jpg"]getting.jpg[/URL] this is the code i am currently using for the task: [CODE]public void actionPerformed(ActionEvent e){ String currText = viewer.getText(); String text = enter.getText(); int len = currText.length(); enter.setText(""); …

Software Development java
Member Avatar for sciwizeh
0
723
Member Avatar for new_2_java

Can someone tell me what jar file do I need inorder to use the above class?

Software Development java
0
122
Member Avatar for darklich13

I'm having trouble getting my InputMismatch working on my program. Do I need some kind of throw for this exception? The program compiles fine, but it dosen't pick up the exception. Can someone please help. [code] public class EndingListener implements ActionListener { public void actionPerformed(ActionEvent e) { if (e.getActionCommand().equals("Convert")){ try{ …

Software Development java
Member Avatar for darklich13
0
206
Member Avatar for &rea

Hello, I have got a problem declaring a matrix. I have got a picture (bitmap) and I take the whole image with a rectangle so I can "paste" it in a matrix. My problem is that the constructor says that I need an array of Point (Point[]) but I don't …

Software Development c++
0
62
Member Avatar for SteveDB

Hi all. I am seeking to learn how to link my drag/drop GUI's to the code I wrote for a program from some 9 years ago. I.e., I have Borland, and MS's Visual Studio 6. I used both-- at different times-- to create a program, and was able to use …

Member Avatar for Necrolis
0
691
Member Avatar for dr_kac

Hello everybody! As I thought I became more comfortable with data structure I've got the problem I can't solve. It looks so: I have that kind of text file: ABCD vvvv 1e-12 ABCD hhhh 1e-6 ABCD ggggg 1e-3 ASDE ffffff 1e-57 ASDE dddd 0.001 etc. I would like to read …

Software Development data-structure python
Member Avatar for paddy3118
0
191
Member Avatar for Aamit

Here is my file text file data Tree Bush Apple Mango Animal Dog Animal2 Cat [code] #include <stdio.h> #include<conio.h> #include<string> #include<iostream> #include<fstream> using namespace std; int main() { FILE * pFile; char mystring [100]; char mystring2[100]; char ch; int i=0,j=0; pFile = fopen ("c:\\List.txt" , "r"); if (pFile == NULL) …

Software Development apple c++
Member Avatar for mitrmkar
0
110
Member Avatar for darkis

hello there, i was hoping someone could help me figure out why my program isn't compiling. Its a polynomial math program i put together...and with my function "MathPoly" //'d out it compiles just fine....It continually tells me that variables are undeclared and the compiler is crapping out on line 51 …

Software Development c++
Member Avatar for stephen84s
0
177
Member Avatar for reyev

Hi everybody! I need to split my path, let's say' "C:\path1\path2\path3\path4" into separate strings... Not sure how to do that, I've tried os.path.split / splitdrive etc. but it always give me just 2 arguments I need to get "C:\path1" from this path string for example, which would be the root …

Software Development python
Member Avatar for reyev
0
138
Member Avatar for Alex Edwards

The problem resides below - I'm trying to make a directive command that disable one constructor definition, or the other, based on the parameter of T. When I uncomment the block around the if statement, I get this error-- [ICODE]... missing binary operator before token "(" [/ICODE] --but when I …

Software Development c++
Member Avatar for Alex Edwards
0
230
Member Avatar for dlayante

hey guys...please help me with this project, I just need to create a Basic DLL Proxy (Proxy INTEROP DLL) create DLL in C# and use it in Visual Basic 6.0 Please give me codes and step by step instructions in making it... Thank you...You're a big help!!!!

Software Development visual-basic
0
244
Member Avatar for tirso

Hi to every body, I want to make an application that having a lot of buttons, such as payment, view info, deliquent, reports, edit etc. In vba I already created by creating each button to call an individual form, like payment I made (frmpayment), for view info(frmview), for deliquent (frmdeliquent). …

Software Development vb.net
Member Avatar for tirso
0
118
Member Avatar for Alex Edwards

Does anyone have an website they would recommend to me for learning Regex? I have tried using the Sun's tutorial on Regex as well as the Pattern and Matcher classes that use Regex but I am not quite understanding it. I'd like to use it to return the String values …

Software Development java regex
Member Avatar for sciwizeh
0
128
Member Avatar for thehype2049

Here is my question Write a command line program titled joinTextFiles.cpp that concatenates the contents of several files into one file. For example, the following command line [B]joinTextFiles chapter1.txt chapter2.txt chapter3.txt book.txt[/B] will create a long file titled book.txt that contains the contents of the files chapter1.txt, chapter2.txt, and chapter3.txt. …

Software Development c++
Member Avatar for thehype2049
0
95
Member Avatar for Superfat

I know about using ran() to create a random number between x and y, however i am creating a banking program and i am wondering how to randomly generate a 17 digit pin, then store the pin in an outside file, then have the program check the file for the …

Software Development c++
Member Avatar for tesuji
0
171
Member Avatar for acediamond

I am a first year IT student cramming my last assignments in before the monday afternoon deadline. I am battling with a problem that looks like this: I have to create a program using the case statements to choose a winner from rock, paper, scissors and count the wins,losses,ties to …

Software Development c++
Member Avatar for VernonDozier
0
268
Member Avatar for ruchika beddy

hey,Frnds I Have tried the Fill. Code,But the Foll. Code returns the no. of charcters of the File,But i want the File Size on Disk in KB. Can u Plz help me out. Imports System Imports System.IO Dim filelength As Long = 0 Dim objfile As New FileInfo("D:\Documents and Settings\Administrator\Desktop\URLs[1].txt") …

Software Development vb.net
Member Avatar for Jx_Man
0
631
Member Avatar for KJBB

I create an array of 16 text boxes, etc in code. I need to detect which one is clicked. I have created an event handler for each that points to the same handler routine for all 16 for(int box = 0; box < 16; box ++) { txtArray[box].Click += new …

Software Development
Member Avatar for KJBB
0
293
Member Avatar for Ellisande

Back with another question concerning my RPG. I had the idea to do a multi-dimensional array to represent a map, with each element in the array being it's own square, Depending on where you are, you can move in any of the 4 directions, unless you are on an edge. …

Software Development c++
Member Avatar for Ellisande
0
253
Member Avatar for henpecked1

This one actually tells me visual studio has a problem and needs to close this code. I'm sure it's in the insert/write section, but I'm not sure what I did wrong. I'll post the rather simple cpp below it. [code] #include <iostream> using namespace std; template <class T> class list …

Software Development c++ visual-studio
Member Avatar for henpecked1
0
135
Member Avatar for tirso

In my forms I have a tab control containing two pages, in tabpage1 (list view) tabpage2 (gridview) and a several buttons. my problem now is how to know that if the user hit a button then locate the active control or tabpage eaither tabpage1 or tabpage2. I intent that the …

Software Development vb.net
Member Avatar for tirso
0
98
Member Avatar for henpecked1

If you grab this code and run it, you'll see what I mean. The second half doesn't run, and when I can get it to run, it's all completely wrong. I'm trying, but I'm tired and just want to get it done...lol. The encrypt and decrypt are a separate cpp …

Software Development c++ encryption
Member Avatar for henpecked1
0
112
Member Avatar for Dajak

Hi Everybody, Im making a kind of notepad in VB 2008. But the problem is ive maked an Form whith a trackbar and a Buttton, its supposed that the trackbar should be the opacity value. The trackbar is changed to rigth to left, It comes no errors it just wont …

Software Development vb.net
Member Avatar for Jx_Man
0
229
Member Avatar for Kadence

Can getc()/putc()/fgetc()/fputc() be used to read/write chars and floats rather than ints only from binary files? If so, how?

Software Development c++
Member Avatar for Kadence
0
230
Member Avatar for Ellisande

I'm having this weird issue with a text based RPG I'm trying to create. I'm fairly new to C++, so I thought having a project that I can work on and expand as I learn more would be a good way to put what I have been reading about into …

Software Development c++ legal
Member Avatar for Ellisande
0
127
Member Avatar for SteveDB

Morning all. Hope everyone has great weekend. Once I get done posting this I'll be digging yet another hole for my spinkler system, and hopefully finishing off my drip system for more backyard. Ok.... Onto my issue. After a week of struggle to find out why I kept getting errors, …

Software Development c++ visual-studio
Member Avatar for SteveDB
0
833
Member Avatar for henpecked1

If this is the original class: [code] class StorageBin { public: StorageBin(); ~StorageBin(); void PutInBin( int Item, int Location); int ReturnFromBin (int Location); bool FindInBin(int Item); void DisplayBin(); private: int *pBin; int NumberInBin; int BinSize; }; [/code] Would this be the correct conversion to make it a template? [code] Template …

Software Development c++
Member Avatar for Alex Edwards
0
241
Member Avatar for henpecked1

When I'm opening a file, is it the file that is text or binary or is it the stream that can be text or binary? Also, when I close a file is that when the stream object is destroyed?

Software Development c++ file-stream file-system
Member Avatar for Ancient Dragon
0
128
Member Avatar for dlayante

I have this Insert Statement code in C# window application.... String MyString = @"INSERT INTO tblUsers(userID, Name, Position) VALUES('a','b','c')"; how if I would like to give values from a textbox: //Please correct this code because it is not working.... String MyString = @"INSERT INTO tblUsers(userID, Name, Position) VALUES('"txId"','"txtUser"','"txtPosition"')"; I need …

Software Development sql
Member Avatar for JerryShaw
0
87
Member Avatar for Alex Edwards

[code=c++] #include <cstdlib> #include <iostream> /** Test Class for learning template-metaprogramming */ using namespace std; template<int N> //General case for a number class ShowValues { public: static inline void show() { cout << "Start: " << N << endl; ShowValues< (N > 1) ? (N - 1): 1>::show(); cout << …

Software Development c++
Member Avatar for vijayan121
0
129
Member Avatar for rje7

[code] #include<iostream> using namespace std; class welcome{ public: welcome(){ cout<<"Constructor"; } }; int main(){ welcome c; return 0; } [/code] for the above code i get the following errors wen i try to compile using GCC in PCLinux minime version. cannot figure out if there is an error in my …

Software Development c++
Member Avatar for rje7
0
122
Member Avatar for javaAddict

Hi All, I am an experienced java programmer for many years. But my problem is that the final assignment that was given to me for my master at the university, has to be written in VB .NET. Do you know any good books for learning VB .NET for someone like …

Software Development asp.net java vb.net
Member Avatar for jwenting
0
149
Member Avatar for thehype2049

Ok, so im doing an assignment and Here is the question: -------------------------------------------------------------------------------------------------- Using the base class Person which has two member variables called name and birthday [both of type string], derive two separate classes from Person, called Student and Professor. The Student class has a major [string] and a gpa …

Software Development c c# c++ engineering
Member Avatar for thehype2049
0
90
Member Avatar for ninjaneer

Hello community. I am writing a program that will use multiple threads to run MATLAB functions inside of Cpp by using the MATLAB compiler to create a DLL. I have already written the MATLAB DLL and I have everything linked up just fine, but now I need to split this …

Software Development c++
Member Avatar for Ancient Dragon
0
140
Member Avatar for salman213

Hey, here are two codes and with one slight difference they do different things [B]CODE 1[/B] [code] #include<iostream> using namespace std; int main() { char array[2]; int i=0; while (i<2) { cin>>array[i]; i++; } cout<<array[0]<<' '<<array[1]; } [/code] [B]EXAMPLE OUTPUT:[/B] [code] two words t w [/code] [B]CODE 2[/B] [code] #include<iostream> …

Software Development c++
Member Avatar for salman213
0
149
Member Avatar for new_2_java

Hi all, I have an object, say its called MySuperType, which has a sub type, say it is called MySubType. MySuperType has the following attributes: int a; int b; int c; MySubType has the following attributes: (besides inhereting a,b and c) int d; int e; I was wondering if I …

Software Development java
Member Avatar for new_2_java
0
144
Member Avatar for salman213

[code] #include <iostream> using namespace std; class CRectangle { int x, y; public: void set_values (int,int); int area () {return (x*y);} }; void CRectangle::set_values (int a, int b) { x = a; y = b; } int main () { CRectangle rect, rectb; rect.set_values (3,4); rectb.set_values (5,6); cout << "rect …

Software Development c++
Member Avatar for salman213
0
146
Member Avatar for Shaun32887

Hey everyone, I'm a third year engineering student and a new programmer who needs to learn some C++ for a job this summer. My boss advised me to look into utilizing a hash table to get my project done. Hash tables aren't covered in the textbook I have. I've done …

Software Development c++ engineering
Member Avatar for Shaun32887
0
153
Member Avatar for msantosh18

can any one help me in the following problem i have created a database and its table at runtime(i.e. while running the exe). the problem is that i need to change properties of table such as 'required' and 'allow zero length' of a table. how to change these properties and …

Software Development visual-basic
Member Avatar for msantosh18
0
124
Member Avatar for salman213

Hi, I am a beginner in C++, I was just wondering what is it good for. This is probably a dumb question but I was searching on yahoo and google (What is C++ good for), and I did not find any real answers. What do people use it for? Is …

Software Development c++
Member Avatar for Narue
0
577
Member Avatar for anifreak

hello, ok i have this simple linked list program, as u can see below i got three functions: one to insert a node in the first of the list, the second to insert a node in the middle and the third to insert a node in the last of the …

Software Development c++ linked-list
Member Avatar for anifreak
0
256
Member Avatar for kux

What i want to do is write some of the rows of a report style CListCtrl with a color and other rows with another color, but if I switch the color with SetTextColor the color of the text in the entire control switches, i want it to switch just for …

Software Development c++
Member Avatar for mitrmkar
0
156
Member Avatar for dlayante

I have already connect my SQL database in C# windows application, Now, can somebody please give me sample codes for data manipulation, add/edit/delete of records....THANK you!

Software Development sql
Member Avatar for JerryShaw
0
98
Member Avatar for gargg321

Hey Guys, I am new to C programming and I got a task of storing hex dumps in character array and then use them as a string. I use the sprintf function for the job but it is giving me incorrect results. Please help me out. I am writing a …

Software Development c
Member Avatar for gargg321
0
289
Member Avatar for mrboolf

Hi all. I'm trying to write a 8 Queen Problem solving program in C++ as an assignement for an exam. I created a Matrix Board class to represent the chessboard with some functions such as put_Queen or check_Board for invalid positioning. I haven't yet begin to write the solving algorithm, …

Software Development algorithm c++
Member Avatar for mrboolf
0
209
Member Avatar for dlayante

Please correct me if there's something wrong with my codes...It already have SQL Database connection and I successfully display my record from the database.... Please help me...here's so far I have...I need codes for data manipulation adding/edit/delete records....im using C#Windows Application THANK YOU...you're a big help... using System; using System.Collections.Generic; …

Software Development dataset sql windows-server
Member Avatar for Ramy Mahrous
0
118
Member Avatar for hacker9801

If you use the new operator on a class, say [code=c++]class dummy { public: string f; }; int main(int argc, char *argv[]) { dummy *p = new dummy; return 0; }[/code] do you have to use the delete operator on [icode]p[/icode]? (since, apparently, it utilizes new.)

Software Development c++
Member Avatar for hacker9801
0
92
Member Avatar for zoner7

I've always used the Dev C++ compiler; however, I keep hearing how the software has little support. Additionally, I have heard people praise the debugger of Visual C++. So, end result, I'm deciding to switch from one to the other. My only problem now is that I can't make the …

Software Development c++ visual-studio
Member Avatar for zoner7
0
108
Member Avatar for lllllIllIlllI

Hi I have made a program with wxPython and i have this bit of code: [code=python] def getpic(self,event,urlp='http://mirror.bom.gov.au/radar/IDR043.gif?20080427173538'): fc = url.urlretrieve(urlp,filename='Weather.jpg') image_file = 'Weather.jpg' self.bmp = wx.Bitmap(image_file) self.img = wx.StaticBitmap(self.background, wx.ID_ANY, self.bmp, pos = (20, 60)) self.background.SetInitialSize() [/code] This is a bit of my code, not the full thing but …

Software Development python
Member Avatar for lllllIllIlllI
0
570
Member Avatar for raul15791

Hi, I've been given the following task: 1. Read some .h header files from a few different folder in different directories. 2. Extract only the functions in the files and store all of them into a single text file. 3. Repeat the step 1 and 2 again but extract info …

Software Development c++
Member Avatar for raul15791
0
606

The End.