64,152 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for monkey_king

I'm trying to get myself acquainted with memory allocation and deallocation while writing a program that will actually be usefull for me. The program is a simple datareader, that tries to read a matrix from file. The "main" program which works is 'int get_lex(char *in,char *delims,char ***returnvals)' This will essential …

Member Avatar for monkey_king
0
131
Member Avatar for javaAddict

Hi, I am trying to use this method: [URL="http://www.cs.indiana.edu/cgi-pub/oleykin/website/OpenCVHelp/ref/OpenCVRef_CxCore.htm#decl_cvCheckArr"]cvCheckArr[/URL] As a parameter I pass an IplImage and it compiles, but when I tried to run got this error: "Unsupported format in function: cvCheckArr .cxmathfuncs.cpp " I checked the above file and found from the code that it tries to convert …

0
75
Member Avatar for osirion666

int test = numbers.length; if (numbers[i] = test) { } i want to find the last array in numbers then do something with it for example out put it the above code is my attepmtp at it however i am doingd something wrong and cant for the life of me …

Member Avatar for peter_budo
0
97
Member Avatar for madtorahtut

Hello! I am rather new to c, and I am having a parsing problem. What I am trying to accomplish: I have a file filled with assignment statements such as: [CODE]var1=5 var2=80[/CODE]...etc. I want to parse through the file and then do a check to see if the variables exist …

Member Avatar for Narue
0
97
Member Avatar for asp_see

I am very new to this.. I have used a repeater control and it fetches about 100 records from the database. Inside the repeater control, I am having 4 columns and in one column, I hav used one dropdown list as [code=asp.net] <asp:DropDownList ID="st" Runat="server" AutoPostBack=true OnSelectedIndexChanged="go_change" CssClass=rtd Runat=server> <asp:ListItem …

Member Avatar for asp_see
0
183
Member Avatar for HUPextreme

hi there, i'm quite the beginner at c++, just got to my last project for my course to do. The project asks me to create a family tree using linked list. It says the tree and its components should be templated so it can have a family tree of any …

Member Avatar for HUPextreme
0
860
Member Avatar for lamiv007

Hello, My brother asked me to create an application where he can save all his data and retrieve at any time, which does all the calculation. A friend of mine suggested PHP and MySQL would be a better option. I know HTML and CSS but very little of PHP. As …

Member Avatar for ithelp
0
93
Member Avatar for Bob Jacobs

OK so I have created by VB application I have created my setup files. I have zipped them up with winrar, selecting .Zip as the format. I have put the zipped up file on my ISP, and I have a web page with a button linking to the zipped up …

Member Avatar for Bob Jacobs
0
116
Member Avatar for socksy

I installed it, and I'm trying to follow the tutorial but it won't work right. I made the test file, but when I type "python test.py" in command prompt it doesn't work. What am I doing wrong?

Member Avatar for socksy
0
164
Member Avatar for firehazrd0

I'm a toal noob to programming. i just bought a C++ book and im trying to develop some very simple programs. I'm using dev C++. I'm stuck on this one, its having an issue linking. here is my code: [code=cplusplus] #include <iostream> #include <math.h> #include <stdlib.h> #include <time.h> using namespace …

Member Avatar for firehazrd0
-1
103
Member Avatar for billymcguffin

hello, i was wondering if there is a way to automatically crop a picture, or only show a specific part of it with javascript. i dont know if this is important or not, but i want the cropped picture to fill the div its in, no matter what size the …

Member Avatar for essential
0
104
Member Avatar for jesseb07

hey, got a quick question regarding template classes. I've made several data structures that I've found to be very useful (using template classes) but it's getting tiresome making a new explicit specialization every time I implement it in a new way. Such as if I want to do this in …

Member Avatar for jesseb07
0
131
Member Avatar for waldchr

I need to know a way to open a notepad document from one of my programs without opening a console window. The calling program is a standard window, so it would look bad if a console widow opened. There are a couple of things you should be aware of as …

Member Avatar for waldchr
0
213
Member Avatar for Usura

anyone know why this wont work? [CODE] fstream f; f.open("a.dat", ios::in | ios::out | ios::binary); [/CODE] it doesnt create a.dat... also how would i switch f from read state to write state?

Member Avatar for amrith92
0
117
Member Avatar for alias120

I am having a lot of trouble getting this program to work properly. No compilation errors, but this is the output i get when i compile; init: deps-jar: Compiling 1 source file to /home/alias120/NetBeansProjects/createFile/build/classes compile: run: Checking to see if file already exists... true You produced the following file contents: …

Member Avatar for alias120
0
82
Member Avatar for GDICommander

Hi, everyone! I'm having problems with the implantation of a free camera in a 3D world. For now, I'm using the A/D/W/S keys to make the camera go right, left, forward and backward. The problem is that I don't see the effects of the forward and backward movements. Even with …

Member Avatar for MattEvans
0
2K
Member Avatar for scru

Do I do it like: [code=C] wchar_t *str = L"12345"; [/code] because that doesn't seem to be working.

Member Avatar for scru
-1
159
Member Avatar for genieuk

Hi, I am not sure what i am doing wrong. I got my code (below) basically it is to resend user activation email if they for some reason or other did not get it first time etc. It sends the email and everything etc... what i need to do it …

Member Avatar for genieuk
0
121
Member Avatar for csurage

I have a problem I'm trying to write to a list box but everytime I do the program states : Unhandled exception at 0x5c560a97 (msvcr90d.dll) in Dialog_Box.exe: 0xC0000005: Access violation reading location 0x00070000. when I take out SetWindowText(); the program is fine. here is a copy of my code: [code=cplusplus] …

Member Avatar for amrith92
0
1K
Member Avatar for Venom Rush

Hi there I'm trying to cycle through entries inside a MySQL db and create numbered variables inside a for loop. Currently it doesn't seem to be working. Here's an example of what I'm trying to do: [CODE=php] $i = 0; while($row = mysql_fetch_row($result)) { $i++; $variable.$i = $row[0]; } echo …

Member Avatar for Venom Rush
0
130
Member Avatar for ShadowScripter

Hi, I remember from when I learned PHP, how easy and fun OOP was, and how to call member functions in conjuction (after eachother) on the same line, like this: [CODE=PHP] MyClass->Foo()->Bar()->Pancakes("flour etc"); [/CODE] To be able to do that, all you needed to do was make a return holding …

Member Avatar for ShadowScripter
0
100
Member Avatar for Daria Shmaria

In an assignment involving cyclic shift hash codes, the instructions include the following code: [code] int hashCode(const char* p, int len) { unsigned int h = 0; for (int i = 0; i < len; i++) { h = (h << 5)|(h >> 27); h += (unsigned int)p[i]; } return …

Member Avatar for Daria Shmaria
0
718
Member Avatar for rizillion
Member Avatar for genieuk

Hi, Hoping someone can help me. I done a search on Google but must not be using correct search term as cannot find anything. Basically how can i make sure a page is only accessed via a certain link? I have a page that user clicks on that opens a …

Member Avatar for diafol
0
92
Member Avatar for Zibo

Hello. I've got simple JFrame and into that I put JPanel (object of subclass of JPanel class). I want to check, what's this panel's size from inside of this panel class, but every method (getSize, getBounds) returns [0,0]. If I call getSize method from JFrame class, then it's fine, but …

Member Avatar for Zibo
0
191
Member Avatar for DimaYasny

Hi all, I was searching for an IDE that is capable of Python GUI drawing, much like MSVS can draw GUI windows without actually having to code them manually. Atm I use NetBeans 6.5 for Python, but I can switch. Yeah, I'd prefer a Linux based IDE of course :) …

Member Avatar for DimaYasny
1
1K
Member Avatar for aashishn86

Hi!! i need to write a function that counts the number of names seperated by a '/' for example if i write aashish/ankush in a field the number returned should be 2 thanks....

Member Avatar for mail2saion
0
325
Member Avatar for ShadowScripter

Contrary to what the title implies, my real problem lie in returning a vector pointer, and then use it. Here's what I tried: [CODE=cpp] #include <vector> #include <string> #include <cstring> //? Needed? #define R_OK 0 #define R_ERROR 1 using namespace std; vector<string>* tester(){ vector<string> v; v.push_back("Lolzer"); vector<string> *ptr = &v; …

Member Avatar for ShadowScripter
0
94
Member Avatar for kylcrow

I have a project due in an hour, and I am stuck on it. My project is to write some functions for a maze. ( Live regions, Dead Regions, and if it is possible to exit). The point of the project is to understand graphs and specifically depth first search. …

Member Avatar for Ancient Dragon
0
101
Member Avatar for deepglue555

string pin, checks, list; checks = whitecheck(kingsq); pin = whitepin(kingsq); list = whitelist(checks, pin, wkbool, wqbool, enpassant) i wrote a chess program in VB6 and have finished converting it to C++. however everytime pin or checks is not a null string it throws a GPF. how can i pass the …

Member Avatar for deepglue555
0
266
Member Avatar for Liszt

If you have done a program in VC++ 2008, what is the procedure to do a release and a "Finished" program of this. In the "Form1 Property Pages", I have under General choosed: Configuration: [I]Release[/I] Platform: [I]Active(Win32)[/I]Output Directory: C:\ Intermediate Directory: [I]C:\[/I] When I now compile the application using F7, …

Member Avatar for Liszt
0
179
Member Avatar for Stefano Mtangoo

After pondering and wondering, I have decided to go for wxWidgets. Here is my first trial application. After running a test app from zetcode.com in my Code::Blocks & wxWidgets and I confirmed that it is fine! Then I tried to write my own app as shown below but I ran …

Member Avatar for Stefano Mtangoo
0
170
Member Avatar for bunnyboy

So, i wrote stack, which is using vector strategy in case of being too small. The code compiles well and works until the resize function is called to resize the size of array. Tnx for any help solving this error. [CODE=cplusplus]#ifndef STACK_H #define STACK_H const int DEFAULT_SIZE = 10; template …

Member Avatar for bunnyboy
0
112
Member Avatar for newcook88

how do i create a set method to get the fstream input file. in need to be able to define the file location in the main method. [CODE]class a { private: ifstream fileOne; ofstream report1; public: void setinput(std::ifstream& in); void setoutput(std::ofstream& out); }; [/CODE] how can i code these set …

Member Avatar for ArkM
0
182
Member Avatar for jtltgl

i have a delimited file it has name|address|address2|phone number/n i found this code snippet of code which i modfied to almost do what i want. the problem is i want to only count the delimited char which is '|" and '\n' but the program is counting the char instead. here …

Member Avatar for jtltgl
0
132
Member Avatar for losh177

I'm having problems reading taking an input using cin.getlin [CODE][LIST=1] [*]cout << "Enter record: "; [*]cin.getline(title, 100); [*]csis << "Enter record title: " << title << endl; [*]rec->setTitle(title); [*]cout << "Enter performer: "; [*]cin.getline(name, 100); [*]csis << "Enter performer: " << name << endl; [*]rec->setPerformer(name); [/LIST][/CODE] The program jumps to …

Member Avatar for tux4life
0
165
Member Avatar for icedece

Hi i've created an animation for a game where a set of blocks moves from left to right across the screen automatically through the use of a timer. However when i set the interval of the timer below 150 the image starts to flicker as it's moving. I've read that …

Member Avatar for vb5prgrmr
0
119
Member Avatar for payamrastogi

Hi, I'm using C#.net 3.0. I have use the frameGrabber class to grab the frames from the video file and to convert the frames into bitmap format.The code is giving error in the "foreach (FrameGrabber.Frame f in fg)line of the code" highlighting "in" giving error---"InvalidCastException was unhandled by user"(Unable to …

Member Avatar for Diamonddrake
0
210
Member Avatar for Pacman21

Okay.. Lets say I have ten labels and I want a random number between one through ten in each label.. But in the labels I dont want to have duplicates so that way in labels 1 through 10 they will have an integer between 1 and 10.. But randomized..

Member Avatar for vb5prgrmr
0
196
Member Avatar for Zandermander

Hello, I'm making a little app that runs through a Richtextbox and makes it turn string "[BK]" red. But I can't get it to make all of the "[BK]"'s red. i found this little piece of code, but I can't get it to work, it looks like it should though. …

Member Avatar for Teme64
0
628
Member Avatar for rizillion

[code=cplusplus] #include <iostream> #include<string> using namespace std; int main() { string str1="Amusement Park"; string str2="going to"; string str3="the"; string str; cout<<str2+''+str3+''+str1<<endl; cout<<str1.length()<<endl; cout<<str1.find('p')<<endl; cout<<str1.subtr(1,5)<<endl; str="ABCDEFGHIJK"; cout<<str<<endl; cout<<str<<endl; cout<<str.length()<<endl; str[0]='a'; str[2]='d'; cout<<str<<endl; return 0; }[/code]

Member Avatar for neigyl_noval
0
99
Member Avatar for billymcguffin

Hello, I was wondering if you can extract an item from a rss file and display it in a div. like extract the title and put it in an h3 tag, extract the description and put it in a paragraph, and have the link below, and all automatic, so you …

Member Avatar for essential
0
535
Member Avatar for billymcguffin

sorry about the bad title, but this is a code that takes a string, defined in an array, and converts it to the next string in the array by replacing letters one at a time. it works fine, but i want some modifications. code: [CODE]function scroll(message_loop) { var messages = …

Member Avatar for billymcguffin
0
89
Member Avatar for daviddoria

If I have /home/doriad/Scripts/Python/ and inside I have a bunch of folders, ie Geometry, Math, Other, etc that each contain scripts (.py files), is there a way I can just add /home/doriad/Scripts/Python to PYTHONPATH and then somehow [code] from Geometry/Spherical import * [/code] rather than having to add every subdirectory …

Member Avatar for vegaseat
0
2K
Member Avatar for jen140

Hello all. I have a small problem . How can I, in c#, windows forms aplication,ComboBox, use AutoComplete. Lets imagine that i have 5 items in the ComboBox that are : Abcd Abcdd Acc Accd Add If i start writing "ab" it will only display items that starts with "ab" …

Member Avatar for Ramy Mahrous
0
326
Member Avatar for FallenPaladin

HI, I am trying to construct a regEx pattern to match a UK tax code. The pattern i have created is "^(/BR{1}/|/D0{1}/|/NT{1}/)|^(([Kk]{1}[1-9]{1}[0-9]{2,3})|([1-9]{1}[0-9]{2,3}[LPTYlpty]{1}))" I thought this would match the codes as BR or D0 or NT or K followed by 3 or 4 digits or 3 or 4 digits followed by …

Member Avatar for FallenPaladin
0
1K
Member Avatar for csurage

Hi, I was creating a Gui for one of my classes and I hit a major bump. I am trying to take words from a text file and just display it in the text box. I know how to read files, what I don't know is how to change the …

Member Avatar for csurage
0
254
Member Avatar for redmaverick

I have to generate html files from .java files. I tried generating from eclipse but was stumped. there are just 4 files. Can somebody help me out. Send me a pm please!!!

Member Avatar for redmaverick
0
118
Member Avatar for kvprajapati

I have two integer numbers. I want to find which number is greater than other one without using relational operators.

Member Avatar for Dave Sinkula
0
184
Member Avatar for losh177

Hi, do not know how possible is this but here it goes, i'm trying to declare an array once a program is running. This is how i'm thinking: [CODE][LIST=1] [*]int size; [*]cout << "Enter size of array: "; [*]cin >> size; [*]Holding *holdLib[size]; //this is a base class pointer array …

Member Avatar for losh177
0
123

The End.