Hi all,
I regularly encrypt my datasets using Boxcryptor. Sometimes i'm trying to import something encrypted by somebody else and Stata returns the error "filename.csv not found". This is less than helpful, and I then go down the path of checking my path (pwd, set trace on, etc), and then checking the file exists in the place I tell Stata it is.
I'm looking for a way for Stata to identify why a file cannot be found, and specifically if it is because of the encryption. I'm thinking of something like
The above code would be incorrect in any situation where I have simply named the file incorrectly or the path is wrong, etc. Does anyone here have knowledge of Boxcryptor / encryption more generally, and whether Stata's use, import delimited, and import excel commands capture information specific to file encryption?
I regularly encrypt my datasets using Boxcryptor. Sometimes i'm trying to import something encrypted by somebody else and Stata returns the error "filename.csv not found". This is less than helpful, and I then go down the path of checking my path (pwd, set trace on, etc), and then checking the file exists in the place I tell Stata it is.
I'm looking for a way for Stata to identify why a file cannot be found, and specifically if it is because of the encryption. I'm thinking of something like
Code:
capture import delimited .... if _rc!=0{ di in red "This file is encrypted and you do not have access" }
Comment