Hi,
I need to copy the list of drives present in the computer to an array e.g
string drives[i] ;
Where i is the list of drives How can I do it?
What I did until now is I have referred Google and found that GetlogicaldriveStrings but it is quite difficult to copy it into my string I know strcpy will not help here but How can I do it? Kindly help me with this
Thank you
Hi Thank you for your answer.But how can I use it because the output is like this C :\D:\E:\ If I want to use the C drive for some iteration how can I use this? could you please teach me to do this using an string array so that I use it. It is quiet difficult to figure out your solution because I don't know why you have used 256 as a buffer value could you please explain this too
I want to do some iteration with the directories so to add further locations (more specifically paths in my computer) To my work string is good since exact drive is unknown my loop will recursively add things to each drive... How can I do this I referred Google and found that there is no standard way of doing this since C ++ lacks its concept in directories the best way is to use boost library
Yes I installed boost on my Visual studio 2015 but boost is quiet like a new language to be learnt
Could you please teach me to get the drives in an array like this
This may look that I have posted in the wrong forum but I am unsure that GetLogicalDriveStrings is related to Windows so I posted here. Sorry if I am wrong
string drive[i]; i is an integer value so that I can increment the value and do my iteration manually.