User forums > Using Code::Blocks
Program that worked in Win XP doesn't work on Win 8.1
peter:
I bought a new computer with Windows 8.1 and downloaded codeblocks (codeblocks-13.12mingw-setup.exe). A program that I wrote with codeblocks on Win XP now doesn't work. It starts but somewhere along the line it stops and gives the following error: Process terminated with status 255.
The standard Hello World program does work.
How can I solve this?
Thanks,
Peter
Vuki:
It's impossible to tell without knowing your code. Windows 8 is much more restrictive in user access rights than XP. Maybe you run a program which tries to write to a restricted directory.
Jenna:
Where is the relation to C::B ?
Note Code::Blocks is not a compiler "just" an IDE.
If there is no relation, this thread violates our forum rules.
peter:
Since it worked on XP and doesn't on Windows 8 I assume it has to do with the installation of codeblocks right? Maybe there is some setting that I missed. If not, I apologise for posting here. Where do I then go?
For what it's worth, the code of the file where it stops is
--- Code: ---#include "Data.h"
#include <string>
#include <iostream>
#include <fstream>
using namespace std;
size_t Data::getLines(string map, string name, string lines[])
{
size_t i = 0;
string fileName = map + "-" + name + ".txt"; // here it stops
ifstream teksten(fileName.c_str());
while (!teksten.eof())
{
getline(teksten, lines[i]);
i++;
}
teksten.close();
return i;
}
--- End code ---
stahta01:
Please read the rules and FAQs or you will be banned!
http://forums.codeblocks.org/index.php/topic,9996.0.html
http://wiki.codeblocks.org/index.php?title=FAQ
Tim S.
Navigation
[0] Message Index
[#] Next page
Go to full version