IFolder.move() gives exception on windows machine [message #516543] |
Wed, 24 February 2010 06:37  |
Eclipse User |
|
|
|
Hi, I am trying to move a resource (IFolder) from one location to another location inside the project through IFolder.move() API as follows:
dataFolder.move(project.getLocation(), true, null);
The problem I am getting is, I am running it on the Windows platform and the first parameter IPath resolves to the file system path as: 'C:/workspace/project'. And move() gives me CoreException as : ":" is an invalid character in path.
Has anyone faced this similar issue?
[Updated on: Wed, 24 February 2010 07:31] by Moderator
|
|
|
|
|
Re: IFolder.move() gives exception on windows machine [message #516854 is a reply to message #516772] |
Thu, 25 February 2010 06:24  |
Eclipse User |
|
|
|
Ibrahim,
A workspace relative path is of the form /<project-name>. You're the
one doing the moving so you need to specify where to move it in the
workspace. Note that I've been taking about getFullPath, not about
getProjectRelativePath.
Ibrahim wrote:
> Hi, can u guide me how to get the Project relative path?
> to me IProject.getProjectRelativePath() is not giving the path I
> expected.
|
|
|
Powered by
FUDForum. Page generated in 0.05914 seconds