Solved

Move the folder and the contents...

Posted on 2009-04-02
2
250 Views
Last Modified: 2012-05-06
Hi,
In my VB6 application I'm generating a folder and some files within the folder in the following directory:
C:\temp\BI_2009040216002345_0001.
Now I wanted to move that BI_2009040216002345_0001 to C:\DestinationDirectory.
Once I done that delete the BI_2009040216002345_0001folder and all its contents. All this will be happening on two different machine but in the same network.
How do i achieve this in VB6?

Thanks in advance!


0
Comment
Question by:ube100
2 Comments
 
LVL 76

Expert Comment

by:GrahamSkan
ID: 24054273
You can move Folders with the Name Statement.

This will do it on one system.

Name "C:\temp\BI_2009040216002345_0001" as "C:\BI_2009040216002345_0001\BI_2009040216002345_0001"

You will have to use the folder Share name or Mapped drive letters for a folder that is not on the current system.

Name "C:\temp\BI_2009040216002345_0001" as "\\MyShare\BI_2009040216002345_0001\BI_2009040216002345_0001"

 or

Name "C:\temp\BI_2009040216002345_0001" as "K:\BI_2009040216002345_0001\BI_2009040216002345_0001"
Name "C:\temp\BI_2009040216002345_0001" as "C:\BI_2009040216002345_0001\BI_2009040216002345_0001"

Open in new window

0
 

Accepted Solution

by:
ube100 earned 0 total points
ID: 24066107
Pls close this call as I have found the sloution myself.
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question