How to see if a file exists with a different extension
Hello, all! I am trying to write a program that will check to see if a file with a different extension exists for the file that was inputed. That was really confusing, so how a bout an example? Lets say the user inputed (from a command prompt in win32):
I want my program to check an see if a file with the name data.dat exists and if it does pass both names as an argument to another program. For example:
otherprog data.txt data.dat
Is there any easy way to go about this? Keep in mind that I am relatively new to programming, so try to keep it simple :) . Thanks!