199,114 Archived Topics
Remove Filter ![]() | |
I'm very new to C and am working on a card game. I've got my cards and shuffle down, but I want each card to have a name. I made my cards inside an array of structs: [code] struct card { int value; int suits; int points; char name[20]; }; … ![]() | |
Hello everyone, I know this forum is more about asm86 but I thought maybe someone knows enough about assembly in general or had some expirience in asm51 as well and can help me with my questions(wich are simple), I needed a 16bit(word) counter and I didn't have appropriate register for … | |
Please can someone tell me the difference between a struct and an enumeration? | |
I want to say thanks in advance for any help. I have searched the many cfdirectory results and can not get what I need. I am doing a simple CFDIRECTORY tag. See below. [icode]<cfdirectory directory="MyDirectory\Statements\" action="list" name="Get_Statements" filter="*.pdf" recurse="no">[/icode] Then I am making a query of the directory list. [code=coldfusion]<cfquery … | |
Hello, I have a site hosted on a free hosting service and I'm using freedns.afraid.org to direct my domain there. The URL forwarding is done by ways of a frameset with my site in a frame. On my site is a javascript that manipulates the location string for some AJAX … | |
Hello, i'm drawing a rectangle in my onpaint method, which id like to rotate around a certain point (mouse movement would rotate it - basically, one end of the rectangle would be static, the other would be change with mouse movement). Ive tried to look it up myself, but no … | |
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 … ![]() | |
hey is it possible to create a pointer that points a struct value, like [CODE] struct person{ int name; int age; }; person me; person *ptr = me.name; [/CODE] any suggestions on how to do this? | |
Can anybody help me create a crystal report by merging two different tables in just a single report. I usually do it using the wizard of crystal report yet, I don't arrive with the format that I wanted to happen. The report looks like a report from a table plus … | |
[code=php]<?php $query1 = "SELECT `asc_prods.name` FROM `asc_prods` LEFT JOIN `democart` ON `asc_prods.pid` = `democart.tip`;"; $result1 = mysql_db_query($query); while($row1 = mysql_fetch_array($result1)) { echo "<td> {$row1[0]} </td>"; } ?>[/code] I've got the above code, the problem I have with it is that I need to get the value returned by the statement … | |
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 … | |
why does "Array out of bounds exception" error occur when tryin to complie | |
Hi everyone, I am using a mail function in my contactus form. But for some id it is sending infromation of contac us form but some time it is not sending like on my gmail id i am not getting mail. what is the reason behind this. I have tried … | |
Hi, I am really, really new to VB .NET and cant get my head around loops, can someone suggest something to add to the end of my code. Description of Program/Events. I would like to come up with a number generator that takes the Total number (for this example I'll … | |
Hi everyone, Here I will keep you updated on my first java project that I do, excepting the school projects. The main Idea is to make a new window where calculations are done by [B]multiple inputs and outputs[/B]. At school I already learned to make windows, fields and buttons, but … | |
http://server185.jnet.be/$sitepreview/chirolonderzeel.be/kalender.aspx Error: Configuration Error Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately. Parser Error Message: Could not load file or assembly 'System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' or one of its … | |
Hello, I had uploaded my website to [url]www.x10filehosting.com[/url]. When i try to open my website i am getting this error. [ATTACH]10140[/ATTACH] | |
I need to write a simpe calc. program to add, mutiply, subtract and divide. I want to have two textboxes that I enter numbers in and when I click a button, +,-,/ or * a third text box will display the result. Rather than declaring my variables inside each instance … | |
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.... | |
hi, what is the use of server.mappath(). what is the return value of this method. Thanks in advance. | |
I have to read a bin file in perl/tk. I have been able to read and open the file, but the read in file only has every other line from the original file. I am using following to open the file. my @contents; open(FILE,"example_data4.bin") or die"cant open file: $!"; @contents … | |
Hi, How to send email notification when particular tests fails. Any input is appreciated. Regards, rAnA | |
Hi, I am creating script to execute a command. for example my directory is /home/rana/script/ and then i want to execute ./abc.sh file from there i am using following command system("cd $output_directory") ; system("./abc.sh"); where my output directory is /home/rana/script/ but i am unable to execute ./abc.sh clean build-all file … | |
I just learned how to use py2exe to turn a helloworld.py script into a helloworld.exe script. But when I do it for something more complicated, I get an error. The exe is created, but when I run it I get an error: C:\Documents and Settings\Gulshan\My Documents\Python Scripts\dist>snake.exe snake.exe:85: RuntimeWarning: use … | |
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; … | |
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. … | |
Is it possible to get a single key press without having the user press enter? So, say if you were writing a game, say an RPG, to high WASD to move. Ie: [code=python]x = getkey() if x = "w" # blah blah blah if x = "a" # blah blah … | |
I am writing a counter that is created on the fly using GD::Image. I am running into a problem with setting a cookie to ensure that the same user is not counted more than once, as I wish to only count unique hits. The problem is setting the cookie. I … | |
I'm developing in c++ but yet need to use FILE * from c (I know fstream option) I want to read line by line [code] string str; char* line; while(!feof(file) && FIleLength(file)>0 && fgets(line, 1024, file)) { str=line; str.append("hi"); fputs(str.c_str(),file) } [/code] I have a few concerns: 1) What if … | |
Hi! I'm new to this forum and joined as i had some doubts regarding c++. I've been studying c++ at school for about 8 months now and now we've been given a project to complete. Here's the topic: [url]http://www.cbse-sample-papers.blogspot.com/2008/09/computer-science-project-c-class-xii.html[/url] I've decided to make a Manager mode sort of a program … | |
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 … | |
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, … | |
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 … | |
For the moment I am getting the computers name with this code, but perheps there could be others and better ways to get a computers unique "ID". I am searching for a way to identify a computer so a software can recognice that computer in order to work. The very … | |
I use in my code (c++) CopyFile and DeleteFIle do these fumctions throw exceptions? do I need to surround them with try and catch?:) | |
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 … | |
hi everyone .. i have just finished developing a web application i hope to put on the www very soon. however my application has various folders that i dont want the public to access directly through a URL for example the images, config and includes folder which contain database and … | |
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 … | |
Ok so I'm having difficulty understanding how to Take a regular expression and turn it into a finite state machine.. so heres a problem similar to the one I need to solve.. Say I have a machine that takes £1 coins, dispenses beer(£1) and water(£2) so the values for a … | |
Can someone please help. I have a dataset that is populated with a csv or a tab seperated txt. I get the datset fine but when I try to insert into a table in sql with bulkinsert I am getting an exception. The table does not allow nulls in the … | |
Hello , I recently bought a Facebook app form a person on digital point and I just found out the bank.php file has an error in it, I don't know where but when you put a - in front of a withdrawal amount it will give you the amount of … ![]() | |
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 … | |
hi, In my array arr={10,20,30,40} i want to display output like 10 20 30 40 10+20 10+30 10+40 20+30 20+40 30+40 10+20+30 10+20+40 20+30+40 10+20+30+40 How to display output like this?? how to do this please help me?? | |
After being told using scanf and printf instead of cout and cin because they are treated like a function instead like cout and cin being treated as a object thus equaling faster code generation so I am relearning as a i go Can you not use a string in printf … | |
Hi, i've only been learning c++ for a couple days now, so im fairly new to it. :p. After I read the basic tutorials and got somewhat used to the c++ environment, I attempted to create a calculator and after trying to solve all of my errors, it became very … | |
Hi, What I actually want to do is really quite simple,that is, convert all the data(of short type)in a file to their abstract values respectively.But I did not accomplish it. Here my code is listed:[CODE] #include <iostream> #include <cmath> #include <fstream> using namespace std; int main() { char *in_name = … | |
[code=python]fout = open( 'tf2 file test.txt', 'r' ) fout.seek(0) items = [] for index, line in enumerate( fout.readlines( ) ): val = line.split('=').strip() items.append(val) for item in items: print item [/code] For some reason it's telling me that strip is undefined? | |
hey ive got 2 different classes and each class has its own struct with the same type of data... would i be able to create a function that returns the whole sturct from one class to the other? ive got something basically like this class A{ private: struct student{ int … ![]() | |
Any one help me plzzzz..... i have an assignment...... that is ______*********_______ Write a program that takes an equation as a string and does the following: Solve 8 parts to achieve 100% 1 - 5 are compulsory. Input: 2x^2+3x+4=0 1) read a quadratic equation 2) print its coefficients (coefficients range … | |
I want to retrieve a image stored in MS Access database as an OLE object. while using a OledbDatareader and getValue method, its returning me a byte array. how can i use this array to display my picture as it is in a picturebox on a form. private void pictureBox1_Click(object … |
The End.