473,657 Members | 2,555 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to send files ?!

viktorijakup
10 New Member
Hi !!!

I have script, which sends file to current directory, but script sends 1 file in 1 runing script.

I need script, which sends several file, (I select and mark files myself) in 1 runing script.

What I must add to this script.

Expand|Select|Wrap|Line Numbers
  1. #!/usr/bin/perl
  2. use warnings;
  3. use strict;
  4. use File::Path;
  5. use Cwd;
  6. use File::Copy;
  7. use File::Spec::Functions;
  8. #hardcoded 
  9. my $FP = 'D:\conv';
  10. my $TP = 'X:\sgml_db';
  11. my ($from_file, $to_file) = ($ARGV[0], $ARGV[0]);
  12. my $cwd = `cd`;
  13. chomp $cwd;
  14. my ($from_dir, $to_dir) = ($cwd, $cwd);
  15. #rename dir part
  16. $to_dir =~ s/^\Q$FP\E/$TP/;
  17. mkpath($to_dir);
  18. copy(catfile($from_dir, $from_file), catfile($to_dir, $to_file)) 
  19.     or die "can't copy file";
  20. exit 0;
  21.  
Thank you !
Sep 12 '08 #1
2 1350
numberwhun
3,509 Recognized Expert Moderator Specialist
How are you supplying the file names you want to copy? However you do, you would just use a loop to cycle through a list of those files, sending them one at a time.

Regards,

Jeff
Sep 12 '08 #2
viktorijakup
10 New Member
Hi !!!

My method of selecting files is simple.

I open folder, select files with "Panel control commands: Ins or Shift + cursor keys" and run script.

Viki
Sep 15 '08 #3

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

Similar topics

1
1909
by: Ruben Duarte | last post by:
Hi, Anybody knows if is posible in Linux with PHP to do upload of several files sending the data before that php script executes. Now in my server you do the upload (with html,form, multipart ...) and first all the files are upload and them the php script is executed. The idea is the next: In the server in my php script I want to proccess each file separated because if the conexion is lost the user don't have to send all the files...
29
3531
by: | last post by:
I did a working code with CDONTS on NT4 Now I am testing is on w2k and it looks like objCDONTS.Send is completely ignored. I think is it ignored because it throws no errors, neither does the rest of the code setting objCDONTS=Server.CreateObject("CDONTS.NewMail") and then manipulating its properties. Do I need to somehow set IIS5 to make objCDONTS.Send work?
0
1959
by: CLarkou | last post by:
My program in Access (Office 97/2000/XP/2003) opens a database (MAIN MENU) with a listing of all databases in a directory. User selects what database wants to open, and program opens it. I am not just reading data from it, I open/run it and forms created in it, can be used by user (MAIN MENU closes). From MAIN MENU I have the following for opening a specific database: SendKeys "%F{DOWN}" 'ALT F SendKeys "{ENTER}" 'Open Window opens
4
1194
by: Wilfried Mestdagh | last post by:
Hello, If I make an application in C# and want so send/share the project source with someone else, which files do I have to send ? (because many files will be generated again if missing, but dont know which ones). -- rgds, Wilfried http://www.mestdagh.biz
1
27242
by: GrantS | last post by:
I need to use a sendkeys key combination to automate the "accept files" that a remote user wants to send to me via Windows messenger. I am using automation to work with Windows Messenger client in a Winforms C# application. I have tried a number of code segment combinations for ALT T combination without success. The combinations might be correct but it might be failing for some other reason. My Attempts:
7
1385
by: rom | last post by:
i know it's not exactly the place to post this question but i didn't find a betrer group. when i send a zipped folder with an asp.net application i cant use it on the destination computer. when i open the solution i cant see the vb.net files. they appear with a yellow ! sign on them.
10
8938
by: Aj Blosser | last post by:
Hey guys, I have a question for you, I have a setup where I'm sending files through the POST to a php web page, I read the file contents, put that file contents as text into the POST string, and send it on it's way. it works perfectly for text files. However, I can't open a word document like a text file and have it give me the result I need. I'm looking for a way to just open a word document and get all the values in it like you would...
14
2282
by: Professor Yonce | last post by:
I have made form for E-Mail. I have entered code but the Import system does not work. It has squiggly line underneath it showing it is not communicating. It Will not build. Public Class Form3Bio1 System.Net.Mail.SmtpClient Imports System.Net.Mail ' This line before ' does not work. I have the rest of code to try if and when I am able to get System working. ' I XXX out certain entrys below just for this publication.
6
6888
by: Harshpandya | last post by:
Hi all, I am working on the form in which you fill out the whole PHP form and e mail that details to someone. It is working fine. But now i want to send the same form to be sent to different people and user should be able choose the check boxes to whom they want to send e mail to. I write some code simple If else conditions but i think i am making some mistakes. Because when i tried - it is not sending them e mails. Here is my code. I...
3
2079
by: Aussie Rules | last post by:
Hi, I have an application that processes files from the users hard disk. The user is able to select what files they want processed from there hard disk in windows explorer. In windows explorer, when you right click on a file you are given the option to 'send to'. I would like to have an option in this 'send to' menu so that the user can 'send to' my application.
0
8403
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8737
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8610
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7345
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5636
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4168
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4327
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2735
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1967
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.