![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Feb 2005
Posts: 25
Rep Power: 0
![]() |
#include <dirent.h>
Im using MSVC++ 6.0 in WinXP... Do I need to download "dirent.h" from somewhere and if I do, where should I put it? Right now I've downloaded it and put it in the same folder as my program.
error C2065: 'scandir' : undeclared identifier error C2065: 'alphasort' : undeclared identifier error C2601: 'find' : local function definitions are illegal These are the 3 errors I'm getting. Last edited by Siphon; Feb 1st, 2005 at 11:54 AM. |
|
|
|
|
|
#2 |
|
Programming Guru
![]() |
add it to the references in an option somewhere in MSVC++ then it shoud be fine.
|
|
|
|
|
|
#3 |
|
Newbie
Join Date: Feb 2005
Posts: 25
Rep Power: 0
![]() |
Can't find "References" anywhere, found a place where you can set the directories of include-files
But nothing else. |
|
|
|
|
|
#4 |
|
Newbie
Join Date: Feb 2005
Posts: 25
Rep Power: 0
![]() |
I put the dirent.h-file in the same directory as all my other header-files (iostream etc) that MSVC had made itself... Still doesn't work... Still get these errors:
error C2065: 'scandir' : undeclared identifier error C2065: 'alphasort' : undeclared identifier error C2601: 'find' : local function definitions are illegal P.S. I also got a .lib file when I downloaded the .h file... I have no clue what to do with lib files. I just put it with the .h file. |
|
|
|
|
|
#5 |
|
I eat cake for breakfast.
![]() ![]() ![]() ![]() Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9
![]() |
Ah... just drag the lib (library) file into the project viewer. It should show up under all the folders. While the header file contains all the info about the functions you're using, the library file contains the functions themselves.
|
|
|
|
|
|
#6 |
|
Newbie
Join Date: Feb 2005
Posts: 25
Rep Power: 0
![]() |
Hehe.. Project Viewer? Is that the editting window or the one to the left where all the files are seen?
|
|
|
|
|
|
#7 |
|
Newbie
Join Date: Feb 2005
Posts: 25
Rep Power: 0
![]() |
Tried to drag it to the left window where all the files are seen... All that happened was that alot of numbers and letters showed up in the right window...
oO... I'm puzzled. |
|
|
|
|
|
#8 |
|
I eat cake for breakfast.
![]() ![]() ![]() ![]() Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9
![]() |
That's odd. Try dragging it onto the project name. Sorry for not being clear earlier. Alternatively, you can edit the linker directives to include it, though that's a lot more difficult.
|
|
|
|
|
|
#9 |
|
Newbie
Join Date: Feb 2005
Posts: 25
Rep Power: 0
![]() |
Nothing... All that comes up is a hex-list like:
0000010 21 3C ... . . . .. <some form of semi-understandable coding text> 0000020 . . . ... . . . <ditto> 00000... ................. <dittotwo> 00000... ................. <...> 00000a0 .................. 00000b0 ................ That's how it looks. |
|
|
|
|
|
#10 |
|
Newbie
Join Date: Feb 2005
Posts: 25
Rep Power: 0
![]() |
Managed to add it to the Source Files/Header Files by using 'Add files to folder' ... But doesn't work in either folder... btw, where should "dirent.h" be? With MSVC++'s other include files (iostream etc) or in my projects folder, and should it be included with < .... > or " .... " ?
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|