473,406 Members | 2,451 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

How to change drive in windows Perl

parajaganesh
I need to change my current drive from C: to X:. How to achieve this using perl...
Oct 11 '07 #1
6 14155
numberwhun
3,509 Expert Mod 2GB
I need to change my current drive from C: to X:. How to achieve this using perl...
Well, in DOS, you would use the cd command (change directory), right?

Perl has the chdir function for just this occasion.

Regards,

Jeff
Oct 11 '07 #2
Well, in DOS, you would use the cd command (change directory), right?

Perl has the chdir function for just this occasion.

Regards,

Jeff
I have already tried, it is not working in my system...

I have already tried an another method 'cd /d x:', it is also not working...
Oct 12 '07 #3
KevinADC
4,059 Expert 2GB
try this and see what gets printed:

chdir('x:/') or die "Can't change directory to x: $!";

saying "it does not work" is useless information, you have to post any error messages you are getting and the code you are using.
Oct 12 '07 #4
firoj
1
try this and see what gets printed:

chdir('x:/') or die "Can't change directory to x: $!";

saying "it does not work" is useless information, you have to post any error messages you are getting and the code you are using.

Thanks Kevin

Its working for me
Dec 4 '07 #5
KevinADC
4,059 Expert 2GB
Thanks Kevin

Its working for me
?? ?? ??
Dec 4 '07 #6
numberwhun
3,509 Expert Mod 2GB
Thanks Kevin

Its working for me

Unless you changed user names, we weren't aware that you had an issue that this resolved.

To the original poster of this thread, did you get this to work using Kevin's suggestion?

Regards,

Jeff
Dec 4 '07 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: dpackwood | last post by:
Hello, I have two different scripts that do pretty much the same thing. The main perl script is on Windows. It runs and in the middle of it, it then calls out another perl script that then...
6
by: Louise | last post by:
Hi I have written an HTML pages which does not have any colour specifying tags as far I know. When I view this in an Microsoft internet explorer browser it appears with a white background and...
0
by: Goutam Paruchuri | last post by:
Hello all, Anyone has perl DBI working with Postgres 8-beta on Windows. I get the following error when i compile. I have POSTGRES_LIB and POSTGRES_INCLUDE set to the right locations. The...
1
by: Nikhil Mittal | last post by:
How to supress system errors in windows perl In unix it is 2>&1 , what is in windows :o
2
by: rqcoder | last post by:
Is there a way to change a Service's startup type somewhere in the .net framework? I've been messing around with the System.ServiceProcess namespace which allows me to start, stop and pause...
0
by: csburris | last post by:
I am converting some Unix Perl scripts to run on Windows. They check to see if they are interactive by checking /dev/tty. Is there any method to see on Windows whether it is being used by an...
2
by: Talal Itani | last post by:
Hello, I need my application to change the name of a drive, I think this is called volume label. I searched everywhere, but I was unable to find out how. Please help. T.I.
4
by: jonniethecodeprince | last post by:
#This is a program from dummies.com $TheDB = 'edata.txt'; # Open the database file but quit if it doesn't exist open(INDB, $TheDB) or die "The database $TheDB could " . "not be found.\n"; ...
4
by: TyVi3t | last post by:
I have a hard drive that has 2 partitions. C: is logical and G: is primary. I want to make C: the primary. C: currently has the OS installed it. If I delete G: the computer will not boot up. Is...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.