Click here to Skip to main content
15,867,308 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have program which is written in c++ (borland c++ 4.5)
it has used fnmerge function which need "dir.h" header file.

I want to used this code in visiual studio (vc++). how i can add dir.h file to vc++

fnmerge(Infilename, Drive, Dir, Current_file->input_filename, Extension);
fnmerge(Outfilename,Drive,Dir,Current_file->event_filename,Out_extension);


is there any alternative to fnmerge() function? i can hard code filename and drive.

Thank you.
Posted
Comments
Sergey Alexandrovich Kryukov 11-Jun-13 16:15pm    
It looks like a Borland/Embarcadero-specific thing. You can write this simple function by yourself or find the source code on the Web...
—SA

Please see my comment to the question. It looks like some really old stuff. You can find something like this function or some replacement for it, such as:
http://www8.cs.umu.se/~isak/snippets/pmerge.c[^].

—SA
 
Share this answer
 
Comments
Espen Harlinn 11-Jun-13 19:13pm    
5'ed!
Sergey Alexandrovich Kryukov 11-Jun-13 19:40pm    
Thank you, Espen.
—SA
peoria123 12-Jun-13 9:49am    
Thank you !!
Sergey Alexandrovich Kryukov 12-Jun-13 14:42pm    
You are very welcome.
Good luck, call again.
—SA
you can use _makepath[^].
 
Share this answer
 
Comments
Espen Harlinn 11-Jun-13 19:13pm    
5'ed!
Sergey Alexandrovich Kryukov 11-Jun-13 19:40pm    
True, a 5.
—SA
peoria123 12-Jun-13 9:48am    
Thank you !!
Windows provides similar functionality, and more - have a look at the Shell Path Handling Functions[^]

Best regards
Espen Harlinn
 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 11-Jun-13 19:41pm    
Another variant, even if it's not quite cross-platform, a 5.
—SA
Espen Harlinn 12-Jun-13 15:42pm    
Thank you, Sergey :-D

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900