Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C++
Hello sir/madam,
 
I am trying to delete a file using function DeleteFile. Preview pane is ON and the file is selected in windows explorer. When I call DeleteFile on this file, how could I get its status that file preview is seen in preview pane? Also how could I remove its preview and delete the file? I am new to c++ coding with windows. Please Suggest me functions to get preview status of a directory and to get whether a file is selected.
 
Thanks and regards,
Vishal V.
Posted 13-Dec-12 2:04am
Edited 13-Dec-12 20:05pm
v2
Comments
jibesh at 14-Dec-12 1:55am
   
what is the error you are getting when Delete file is called? can you paste the error you got

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

declare a global variable with boolean type and default value set to false.
Now when PreviewPane Is On and file is selected,set "True" to that global variable.
Then when u try to delete that file,check true/false for that variable,if true (means file is in pane and windows explorer) then delete otherwise not
  Permalink  
v2
Comments
vishal9483 at 14-Dec-12 0:44am
   
Thanks for your reply. I am completely new to this type of coding. How could I get the PreviewPane status and file selection status using cpp code?
01010RAJ at 14-Dec-12 0:59am
   
sorry yaar,i don't know it with C++,otherwise i will write complete code.So i suggested u only logic.I thought u know about PreviewPane and windows Explorer in context of c++.So Update ur question again.
vishal9483 at 14-Dec-12 1:06am
   
I have updated my que. I am behind this from a long time. And not able to get a solution. :(.

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

  Print Answers RSS
0 Zoltán Zörgő 380
1 Sergey Alexandrovich Kryukov 185
2 OriginalGriff 150
3 Mika Wendelius 83
4 Peter Leow 80
0 Sergey Alexandrovich Kryukov 8,373
1 OriginalGriff 6,466
2 Peter Leow 3,567
3 Zoltán Zörgő 3,316
4 Richard MacCutchan 2,397


Advertise | Privacy | Mobile
Web03 | 2.8.150123.1 | Last Updated 14 Dec 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100