copy

Printing to a UNC to emulate command prompt 'copy'

We have several applications that generate their own PCL and Postscript via C#. When it comes to print we've traditionally allowed for multiple outputs such as IP (LPR or RAW 9100) or local printer using: How to send raw data to a printer by using Visual C# .NET We also send via UNC (\\server\printer_share). The problem with the last...

Why does Perl's File::Copy silently fail on Windows 2008?

I have a Perl script that works on Windows XP. It uses File::Copy's move function to move a directory tree to another place on the same drive. The script fails (silently) on Windows 2008. Nothing moved, nothing deleted. I am using ActiveState Perl 5.10.0 Build 1005 and the File::Copy that comes with it. Anyone know of issues with Activ...

AS3: ByteArray and BitmapData

I'm doing a simple test. I want to write BitmapData into a ByteArray. I'm trying to do this with writeObject() and readObject(). Read object seems to have trouble making sense of the BitmapData. var byteArray : ByteArray = new ByteArray(); var _cache : BitmapData = new BitmapData( 640, 480, true, 0x000000 ); var _blank : BitmapData = ne...

Error due to encryption in the command "cp -R /Users/me/cs_project /Users/cs/"

Problem: to copy a directory tree from the "me" master user to the encrypted harddrive of the "cs"-user: su cs bash-3.2$ cp -R /Users/me/cs_project /Users/cs/ cp: /Users/cs/cs_project: Permission denied cp: /Users/me/cs_project/h_mark: unable to copy extended attributes to /Users/cs/: Permission denied cp: /Users/cs/: No such file or ...

How to copy cell content in dojo grid

Hi there, I have a web page displaying data using dojo datagrid. Sometimes, users need to copy contents from certain cells for further analysis, but since browser's right click event is disabled in dataGrid, what's the best way to copy the contents to the clipboard? Thanks in advance! David ...

Truncated files when copying CSV files using FileSystemObject

I am helping my son write a program to format files to load into another system. I have done this before with no trouble. Now I get a 13 KB comma delimited text file and I am copying it use FSO to another file with a csv extension. For some reason the new file always stops at the same place, about6 records from the end of the file ori...

C# Using Reflection to copy base class properties

I would like to update all properties from MyObject to another using Reflection. The problem I am coming into is that the particular object is inherited from a base class and those base class property values are not updated. The below code copies over top level property values. public void Update(MyObject o) { MyObject copyObject =...

how to use shell script checking last changed time of a file

I want to find if certain files are changed within the last three minutes in order to decide if the cp was successful, and if I should exit or continue the script. How can I do that? Thanks ...

How to programmatically copy a table in SQL Server, without the data?

I need to copy a table I already I have in a SQL server database, but I don't need th edata contained in the source table. The examples I found only involve copying the data. Copy the table structure only, not the data. Source and target tables are in the same database. Target table does not exist yet. Need to do this programmatically...

How to automatically append text to text copied with JavaScript

In JavaScript, how can you select text on a website, copy it (by Control+C, Command+C, or Edit Copy) and have JavaScript append a line or two to the clipboard so when the user pastes, the content they copied is shown as well as the extra line? Also, would this be possible to do only within certain <div>s of the site? If so, how? ...

Copy data from tables in one db to duplicate tables in another db - What's the SQL?

Hi folks I have a situation where i have 20 Access databases. Each has the same 15 tables, but with different data. (The name and schema is identical for each table across the 20 databases). I want to make a new database with the same structure, and populate it with the contents of all of the 20 original databases, so i have one data...

Copy constructor in python

Is there a copy constructor in python ? If not what would I do to achieve something similar ? The situation is that I am using a library and I have extended one of the classes there with extra functionality and I want to be able to convert the objects I get from the library to instances of my own class. ...

iPhone SDK Copy File to Main System

Many thanks to @fabkk2002 who helped me adjust the Helvetica font on my iPhone to fully support Indic glyphs and rendering on my iPhone for an app I am creating. This leaves me with another problem. Now that I have adjusted the font on my phone, how will my users get the full support for the Indic font as well? I do not want to requir...

How do I disable html copying from a webpage, so that only text gets copied?

Is it possible to have JUST TEXT copied when a user copies a url from a webpage to an HTML-enabled application such as Word of Outlook? Perhaps there is something I can do in Javascript? I know how to disable Copy + Paste completely, but I really need to disable HTML copying only. Thank you very much. ...

copy whole shared directory from network

Hi I am trying to copy whole directory tree from server's shared folder to my local machine, I found Best way to copy the entire contents of a directory in C# post and decide to use that but as I guess DirectoryInfo doesn't support network shares, how can I change this code to work with network shares as a source? public static void Co...

Does Scala AnyRef.clone perform a shallow or deep copy?

In Scala, does AnyRef.clone perform a shallow or deep copy? ...

What is the easiest way to deeply clone (copy) a mutable Scala object?

What is the easiest way to deeply clone (copy) a mutable Scala object? ...

Copying emoticon "text" from a richtextbox showing image in wpf

I am looking for a good, clean way to enable copying of text from a richtextbox displaying emoticons. Think of skype, where you can select a chat and it will copy the emoticon images and convert them to their textual representations (smiley image to :) etc). I am using the MVVM pattern. ...

Visual Studio Installer not overwriting files in target application directory

I have a Visual Studio 2008 solution that contains several projects. Most projects in this solution write a .dll when built. My installer project in this solution copies these .dlls to a target application directory. My uninstaller for this solution does not remove these .dlls, even though it should. My installer doesn't overwrite old ...

Change objects in NSUserDefaults without creating and re-setting copies

I've got dictionary stored in NSUserDefaults and I need to add/remove items in this dictionary. It bothers me that to do this I have to create mutable copy of entire dictionary, change one element and replace entire dictionary with new copy. copy = [[defaults objectForKey:@"foo"] mutableCopy]; [copy setObject:… forKey:@"bar"]; [default...