I want to delete all files in RECYCLER.

Don't want give all disks, a directories, search all files here and delete their. I want get a API command "Empty RECYCLER.". How i do that?

Sergey:
Try the attached example.  Roberto has already laid it out for you.  You need to add shell32.lib to your project, #include windows.h and shellapi.h in your .c file, and call SHEmptyRecycleBin().
From your previous posts, it sounds like you already have the Windows SDK/Win32 API installed, but if this wasn't done correctly or completely, you'll have problems.  Also make sure that you're using the SDK that came with CVI and not one that came with some other product like Visual Studio.
Here's all the code, but I also included the .c and .prj files to make it easier.
#include <windows.h>
#include <userint.h>
#include <shellapi.h>
main()
 HRESULT emptyResult;
 emptyResult = SHEmptyRecycleBin(NULL, NULL, 0);
 if (emptyResult != S_OK)
  MessagePopup ("Recycle Bin Error", "Error emptying recycle bin");
Attachments:
EmptyRecycle.c ‏1 KB
EmptyRecycle.zip ‏2 KB

Similar Messages

  • I have an old mac and want to delete all files before i sell

    i have an old mac and want to delete all files before i sell

    Check out
    http://www.mactalk.com.au/content/preparing-your-old-mac-sale-1127/
    or
    http://hivelogic.com/articles/how-to-prepare-a-mac-for-sale/
    Dennis

  • I have a problem with my mac  i have too many  archives and programs and i want to delete all files and start at the begin my mac with out do format

    i have a problem with my mac  i have too many  archives and programs and i want to delete all files and start at the begin my mac with out do format

    I do not recommend reformatting your harddrive and reloading your software.  This is a Windows thing. On an older mac it may be difficult to find all your software again.
    Best to have greater than 2gig of free space.  Many posters to these forums state that you need much more free space: 5 gig to 10 gig or 10 percent of you hd size.
    (0)
    Be careful when deleting files. A lot of people have trashed their system when deleting things. Place things in trash. Reboot & run your applications. Empty trash.
    Go after large files that you have created & know what they are.  Do not delete small files that are in a folder you do not know what the folder is for. Anything that is less than a megabyte is a small file these days.
    (1)
    Run
    OmniDiskSweeper
    "The simple, fast way to save disk space"
    OmniDiskSweeper is now free!
    http://www.omnigroup.com/applications/omnidisksweeper/download/
    This will give you a list of files and folders sorted by size. Go after things you know that are big.
    (2)
    These pages have some hints on freeing up space:
    http://thexlab.com/faqs/freeingspace.html
    http://www.macmaps.com/diskfull.html
    (3)
    Buy an external firewire harddrive.
    For a PPC computer, I recommend a firewire drive.
    Has everything interface:
    FireWire 800/400 + USB2, + eSATA 'Quad Interface'
    save a little money interface:
    FireWire 400 + USB 2.0
    This web page lists both external harddrive types. You may need to scroll to the right to see both.
    http://eshop.macsales.com/shop/firewire/1394/USB/EliteAL/eSATA_FW800_FW400_USB
    (4)
    Buy a flash card.

  • I need free space in my hard disk-- i want to delete all files. i want to leave my mac book like the first time.. what must to do ?

    i want delete all files and leave my mac book pro like the first time. i have system 10.7.5 , i have lot of files and need memory.. what must to do ?

    Install or Reinstall Mavericks or Mountain Lion from Scratch
    Be sure you backup your files to an external drive or second internal drive because the following procedure will remove everything from the hard drive.
    OS X Mavericks- Erase and reinstall OS X
    OS X Mountain Lion- Erase and reinstall OS X
    OS X Lion- Erase and reinstall Mac OS X
    Note: You will need an active Internet connection. I suggest using Ethernet if possible
                because it is three times faster than wireless.

  • HT201250 I'm using Time Machine. Its Full. Deleting older backups as it goes. My desktop Mini is full. I want to delete all files on my computer. How will this affect Time Machine?

    I'm really wanting to make room on my Mac Mini. I have about 70 gb left.  I'm not sure what to do. I'm using Time Machine to regularly backup my computer and its already full and deleting older backups.  I used to, in the past before Time Machine, just drag and drop files into an external hard drive and empty the file from my computer.  Should I follow a similar procedure here? If I have time machine backup up, and I remove all my files from the computer, will Time Machine begin to backup a "clean" machine onto the external drive and begin deleting past backups? What would be the best way to approach my backups, remove all my files from my computer since a variation of them are already on time machine, and not lose viable backups? Thank you.

    If you erase the hard disk and you install a new Mac OS X copy, Time Machine will start a new backup and will stop using all backups you made in the past.
    One option you have is to reinstall Mac OS X and restore a Time Machine backup, but restoring only some files: for example, instead of restoring everything, restore only your user files, and not your applications, so you will have more free space. Also, doing this, Time Machine will continue backing up to your old backup, because Time Machine will detect that you have "the same computer with the same files and the same Mac OS X version", but it's not.
    If you have more questions about Time Machine, see this site > http://pondini.org

  • I want to delete all my files so I can give this computer to a friend

    I want to delete all files on my G-5 so I can give it to a friend.

    Well, they would be the best way as they would allow you to return the computer to an "as-shipped" condition.
    If you were diligent in keeping all your personal files in your User account, you can create a new admin account in the name of your friend, make sure it it working, then delete your original acct.
    That would leave the program software intact as long as it is in the path Macintosh Hard Drive > Applications and not Macintosh Hard Drive > Users > [your username] > Applications. Anything inside your current User acct will be unavailable to a new user even if you don't delete that acct (unless you give him the password)

  • Deleting all files prior to sale of my iMac

    I am selling my 2009 iMac abd want to9 delete all files prior to giving to the new owner.  I have tried DiskUtility but the formet etc and security buttons are greyed out. Please help.

    Throw away any files which may contain sensitive information, securely empty the Trash, and then run the Disk Utility when booted to a Mac OS X install DVD(if it originally shipped with 10.6.8 or earlier) or the computer's recovery partition.
    (80427)

  • I have QT Pro 7.6.6 and want to delete all audio (5 tracks) from a selected in-out section of a .mov file. Then, add new audio. How do I do that?

    I have QT Pro 7.6.6 and want to delete all audio (5 tracks) from a selected in-out section of a .mov file. Then, add new audio. How do I do that?

    If I 1) knew TeX well enough to fix it, and 2) could get the guy to answer the phone or email so as to give me the sourcecode or to fix it himself, I wouldn't have bothered figuring out that the thing could be fixed one page at a time by a) getting a copy of acrobat pro, b) figuring out how to turn on all of the extra toolkits, c) finding the edit object button in randomly named toolkit, d) right clicking on the chapter title and selecting the e) ever so obvious "delete clip" menu selection.
    At this point I would absolutely love to never have to touch an adobe product again in my life, but my hand has been dealt and if I'm going to print the manual for a software library that we've spent a cumulative $70,000 for, I have to figure this out and I really don't want to have to hit [Page Down], [Ctrl] + [A], Right click, delete clip for >700 pages.
    I felt certain that once I'd figured out how to shift the pages down using ghostscript so first two lines of each page weren't getting cut off in the printer non-printable region, and finally figured out this that a relatively simple scripting solution would be immediately apparant.  I mean, there are APIs for both applescript and javascript, but I'm mystified by how to get to the edit object feature from within them, much less how to tell that feature to delete clips for everything on a page.

  • How do I delete a prior month(s) or entire year(s) in iCal on my iMac (using version 4.0.4 (1395.7)?  Want to delete all months in 2009

    I checked what was previous asked in deleting months from iCal; however, that question pertained to removing events from a month and not necessarily deleting the entire month.  I have three years of calendars (January - December x three) in my iCal and want to delete all months for 2009 and 2010; however, I can't seem to find a way to delete.  I checked preferences/advanced under iCal but no mention of deleting previous months/years.

    Greetings Judith,
    Before making any attempts at deleting calendar data, backup what you have just in case:
    Click on each calendar on the left hand side of iCal one at a time highlighting it's name and then going to File Export > Export and saving the resulting calendar file to a logical location for safekeeping.
    iCal has an automated function located in iCal > Preferences > Advanced > Delete events "X" days after they have passed.  By typing in a value for days you can tell iCal to delete all events before that time frame.
    Example:
    Today is 4-16-2012.
    If I wanted to delete all events prior to 1 year ago (4-16-2011) I would type in "365" for the number of days.
    Once you type in the number of days you want kept in iCal, close the preferences and then quit iCal.
    Re-open iCal and check to see if the events are gone.  If not you may want to leave it open for several minutes and then quit again.
    Once the events are removed go back to  iCal > Preferences > Advanced > Delete events "X" days after they have passed and make sure the check mark is removed to prevent future deletion.
    Hope that helps.

  • Can I delete all files and users (including admin account) without re-installing SL?

    I have a 1st generation Macbook Air, running Snow Leopard 10.6.8.  Just bought myself a new MBA, want to sell the old one (privately, not soliciting here).
    The original install disks were Leopard.  I bought a family pack SL and upgraded the MBA at that point.  Earlier this year I sold my old Mac Mini (when I upgraded) and included the SL install disks with that sale (stupid of me).
    Now I want to sell the old MBA.  Ideally, I'd have a clean install on SL on it, minus all previous files and accounts.  I've done that before when selling old computers, reformatted / erased the HD, then reinstalled the OS.  But I don't have the SL disk anymore, and I don't really want to pay for it just to prep this notebook for sale.
    AFAICT, my options are:
    wipe the HD and reinstall Leopard (the only OSX disks I have).  Whoever buys it from me would need to upgrade to SL themselves, and from there to Lion if they want.
    somehow try to delete all files and users without touching the current install of SL.  I'm not terribly worried about security of what little information is on the MBA (nothing important to me), so I don't mind trashing files and then emptying trash instead of wiping the HD block by block. 
    Any ideas for how to do #2?  I can trash all files/folders under /user, uninstall all applications and delete their folders from Library, uninstall all browsers except Safari and wipe the history from that...
    Is there other stuff I should be deleting?  plist files, maybe?  I'm leery of messing around too much and disrupting the install of the underlying OS.
    Can I also delete the admin account (or rename it "admin" with a generic default password?)?
    Any other suggestions?  Thanks.

    Trashing files you have created is relatively easy. Getting rid of an account is a bit harder. Trashing the .plist files, etc., that may contain personal info is a lot harder, and there is always the risk that you will miss something.
    Best, and easiest, and customary, is to do option #1 - wipe the drive and re-install the original OS from the original disk set. The receiver of the machine can then decide which OS they want to upgrade it to, and purchse accordingly.
    The original disk set for that machine should be included with it when it is sold.

  • Deleting all files in the Unix directory

    I was trying to create a DB in Unix. I had to remove all the files in the udump directory and I saw that there were files in thousands. I was trying to find a command to remove all of them to make the directory empty, so that I could create the udump file for Database creation. However, I couldn't find a command to remove all of them at once. I tried to google but evey website speaks about just these commands..
    rm filename
    or
    rm -r * directory_name
    This doesn't solve my problem as these commands are deleting one file at a time and not all the files at once within the directory. Can someone tell me the solution?

    Hi,
    First go to the directory where you want to delete all the files and folders. then
    rm -fr directory_name
    rm -r is not neccessary that it will delete the files and folder.
    thx
    pradeep

  • I want to delete all transparent pixels, how can I? CS6

    I would like to delete all transparent pixels surrounding my irregularly (non-square) image.  The TRIM function only trims to a square surrounding my image and not to the edge of the image itself.  Is there a work around for this?  I have looked around and haven't found one. 
    Thanks,
    JB

    Image have rectangular area they have a width and height boundaries as do layer.  Not all of the rectangular area need to have content or be fully opaque,  However the image boundary is a rectangle.  Some file formats are like a Photoshop Background layer do not support empty area or even transparency so those file formats only contain image that are rectangles and have no transparency. Some file formats support transparency and empty areas so those images can be any shape and contain transparency still the image boundary is rectangular. Then there is the GIF file format an oddball format. It only supports 256 Colors. Pixels are mapped to one of the 256 colors selected for the image.  If you want Transparency in a gif  the number of colors is reduced by 1 to 255  the 256 color now indicate no content its not real transparency it just a no color pixel in other words off or no content.
    So if you have areas that are 100% transparent there is nothing to delete the area is empty.  If you have pixels that contain some transparency and you delete those pixels you delete details are you sure you want to delete all pixels that contain transparency? You will loose things like drop shadows

  • I want to delete all music not Syncing, iTune want to delete everything

    I want to delete all music in my iPhone to gain space as I do not use it for listening music anyway.
    My old computer was stolen and now when I plug my iPhone in itune and try syncing ZERO music it say it will erease everything.
    I fear it will remove my Apps, apps data, photo and most importantly I fear it will change the order of my icons.
    I do not have ticked anything but "Sync music" will it delete all music or EVERYTHING ?
    Someone told me I should use WinSCP to delete the file manually,
    Any help would be greatly apreciated.

    I believe MediMonkey will do that. It requires iTunes to be installed, but you don't need to open iTunes or anything.
    http://www.mediamonkey.com/information/free/
    It is free but only available for PC and not for mac.
    I used to use it when I had a PC, and I think you can just select all the iPhone music on it and delete it.

  • Delete all files in a directory not working for some files

    I have a requirement like wants to delete all the files in a directory. (These files got generated through some other program.)
    Problem is file.delete() is returning false for some of the files..
    (donno the reason .. could be bcoz of file closing issues/locking issues.)
    Looking for a solution where i can delete a file forcefully irrespective of whether the file is opened or not.
    Thanks
    Srini

    are you on windows? if so, it's almost impossible to delete something another process has open.

  • I want to delete all music on my i-Phone and reload what I want...have tried to do it manually on i-Tunes and by just selecting specific songs, but nothing comes off my phone.

    I want to delete all music on my i-Phone and reload what I want...have tried to do it manually on i-Tunes and by just selecting specific songs, but nothing comes off my phone.

    You might want a more Mac-centric version of that post which is directed more at Windows users.
    iTunes will only give you the option to copy your iTunes Store purchases directly from an iPod to the computer, you'll find details in this article: Copying iTunes Store purchases from your iPod or iPhone to a computer
    For everything else (music from CDs, other downloads and including iTunes purchased songs and in some cases, videos and games) there are a number of third party utilities that you can use to retrieve the music files and playlists from your iPod. I use Senuti but have a look at the web pages and documentation for the others too. You can read reviews and comparisons of some of them here (you'll find that they have varying degrees of functionality and some will transfer movies, videos, photos and games as well):
    Wired News - Rescue Your Stranded Tunes
    Comparison of iPod managers
    A selection of iPod to iTunes utilities:
    Senuti Mac Only (iPod Touch & iPhone compatible)
    expod Mac Only (iPod Touch & iPhone compatible)
    PodView Mac Only
    PodWorks Mac Only
    TuneAid Mac only (iPhone and iPod Touch compatible)
    YamiPod Mac & Windows
    iPod Music Liberator Mac & Windows (iPhone and iPod Touch compatible)
    iPodRip Mac & Windows (iPhone and iPod Touch compatible)
    iPod Music Liberator Mac & Windows (iPhone and iPod Touch compatible)
    iGadget Mac & Windows (iPhone and iPod Touch compatible)
    Floola Mac & Windows
    Music Rescue Mac & Windows (iPhone and iPod Touch compatible)
    iRepo Mac & Windows (iPhone and iPod Touch compatible)
    iPod Access Mac & Windows (iPhone and iPod Touch compatible)
    TouchCopy Mac & Windows (iPhone and iPod Touch compatible)
    There's also a manual method of copying songs from your iPod to a Mac or PC. The procedure is a bit involved and won't recover playlists but if you're interested it's available on page 2 at this link: Copying Content from your iPod to your Computer - The Definitive Guide

Maybe you are looking for

  • How to stop ActionEvent for a button

    Hi, I have a button "Start". On clicking the button, it will ask with a prompt "You really want to start" with Yes and No button. On clicking Yes button, the "Start" button is changed to "Cancel Stat..." and start running a process. If want to stop t

  • Quorum location for Failover cluster file share witness

    So, I've done quite a bit of searching for what I'm about to propose and I've been able to find nothing. I currently have a multi site failover cluster hosting separate 2-node SQL clusters at each site connected through an Availability Group.  For th

  • PB won't restart or shut down

    After upgrading to 10.4, I can’t shut down or restart using Apple Menu choices. When I try, all programs quit as expected but then the screen just displays the desktop background without any icons, pointer, etc. I have to do a forced shut down. All c

  • Indexing without load document into DB

    Hi, i'm indexing some document in this way. - I load the array of byte representing the document in a BLOB field called text - create index from the field text Everything is OK. Now the question is, how can I index my document without load them in a

  • Encapsulation dot1q any second any on me3600x

    Hi, we recieve a number of downstream hand-offs that are delivered as SVID/CVID ccts.  There are mixture of data, and VOIP subscribers, the only way to tell the different type of subscribers is that the all voip services are marked as cos 4.  All dat