Search Results

Search found 75611 results on 3025 pages for 'file copy'.

Page 10/3025 | < Previous Page | 6 7 8 9 10 11 12 13 14 15 16 17  | Next Page >

  • c++ STL vector is not acccepting the copy constructor

    - by prabhakaran
    I wrote a code ( c++,visual studio 2010) which is having a vector, even I though copy const is declared, but is still showing that copy const is not declared Here the code #include<iostream> #include<vector> using namespace std; class A { public: A(){cout << "Default A is acting" << endl ;} A(A &a){cout << "Copy Constructor of A is acting" << endl ;} }; int main() { A a; A b=a; vector<A> nothing; nothing.push_back(a); int n; cin >> n; } The error I got is Error 1 error C2558: class 'A' : no copy constructor available or copy constructor is declared 'explicit' c:\program files\microsoft visual studio 10.0\vc\include\xmemory 48 1 delete Anybody please help me

    Read the article

  • Recover backup copy of a ubuntu linux installation on a usb stick using dd

    - by user10826
    Hi, I installed Ubuntu 10.04 on a usb stick in persistent install mode. So I could boot the laptop or my desktop computer with the stick, at boot time. Once I needed the 8GB stick for another purposes so I thought about coyping it to my desktop doing from mac os x: dd if=/dev/disks3s of=/Users/jack/Desktop/usb_copy Now I am trying to do the opposite, after having used the stick, which was formatted to NTFS, just doing dd if=/Users/jack/Desktop/usb_copy of=/dev/disks3s but although I can see that almost of the files are there, I can not boot again. IT is also strange the the file permissions are kind of strange, something like _user What can I do ? Thanks

    Read the article

  • Flat File Connection Manager in SSIS package shows "Valid File Name Must be Selected"

    - by Traples
    (Flat File Location) Samba Share | Windows Share (SSIS) _______________________________ | | XP 32bit | Works | Works | | 2003 Serv 32bit | Works | Works | | Vista 64bit | ERROR | Works | | Win 7 64bit | ERROR | Works | | 2008 Serv 64bit | ERROR | Works I created an SSIS package in VS 2008 that parses a flat file from a shared folder and puts the records into a SQL Server db. I recently installed Windows 7 and VS 2008 on a new workstation. When I import the package from TFS and open it, I get the error Validation error. Parse and Import Catalog Flat File: MySSISPackage: The file name "\\shared\flatfile.txt" specified in the connection was not valid. When I open the Flat File Connection Manager Editor, there is an error stating: A valid file name must be selected I can browse to and select the file from inside the editor, but I cannot change any properties, or move away from the General tab because of this error. If I go back to my laptop (Windows XP), where the package was first created, there is no error. Both workstations are on the same domain, and I'm logging in using the same credentials. Any ideas as to why I would receive this error from one workstation and not another? UPDATE: If I take the .dtsx package from the running workstation and load it into SSIS on the server, I get the following errors when it tries to run: Error: The file name "\\shared\flatfile.txt" specified in the connection was not valid. and... Error: Connection "MySSISPackage" failed validation. and... Error: The file name property is not valid. The file name is a device or contains invalid characters. UPDATE 2: a) The Shared folder I'm trying to pull the flat file from is a Samba share on a Unix box. b) If I access the file using SSIS on any 64-bit platform (Windows 7 64-bit, Vista 64-bit, Windows Server 2008) I get the error "A valid file name must be selected." c) Accessing the file using SSIS from 32-bit environments (Windows XP 32-bit, Windows Server 2003 32-bit) there is no problem. d) If I move the file to a shared folder on a Windows server, 64-bit SSIS recognizes the file.

    Read the article

  • How to specify file permission when putting a file using OpenSSH sftp command

    - by Adi Roiban
    I am using various SFTP clients for uploading files to an SFTP server and I have a problem with default permission used when putting files. When requesting to put a file, SFTP client like WinSCP or Filezilla will send the SSH_OPEN command without requesting any explicit file permission. On the other side, it looks like the OpenSSH sftp command on Linux (Red Hat and Ubuntu) is pending the SSH_OPEN command together with the '640' mode. How can I configure the OpenSSH command to not explictly set the file mode or how can I configure it to send a mode, other than 640? Many thanks! Update: I checked the OpenSSH sftp client source code and it looks like OpenSSH sftp will always tries to preserve file mode even if -P is not set: http://www.koders.com/c/fidD3B20680F615B33ACCB42398FAAFEE1C007DF942.aspx?s=rsa#L986 To solve this problem I used Putty SFTP client.

    Read the article

  • File and Printer Sharing, in 10.0.0.x

    - by bubbles2
    Hi, I have a strange problem: When I assign addresses of the form 10.0.0.x to my computers, file sharing (smb) does not work. When I assign them addresse of the form 192.168.1.x it works... OS is XP SP3, for subnetmasks i tried both 255.255.255.0 and 255.0.0.0 Any ideas what I can do? [EDIT] I forgot to add: pinging doesn't work either

    Read the article

  • Shared block device file system (cluster file system without networking)

    - by fungs
    Is there any file system that can be mounted multiple times and supports concurrent file access for Linux? Basically I want something like a cluster file system but without the need to have a running network for a distributed lock manager. That can be very handy in connection with virtual machines that can share data with the host or another VM without the need to create a network link. This I want to avoid to keep the network architecture secure (virtual machine in DMZ) but share large files. No need to scale it up, just two machines that mount the same block device. Shouldn't it be possible to have file locking information right on the disk?

    Read the article

  • CMD Command to create folder for each file and move file into folder

    - by Tom
    I need a command that can be run from the command line to create a folder for each file (based on the file-name) in a directory and then move the file into the newly created folders. Example : Starting Folder: Dog.jpg Cat.jpg The following command works great at creating a folder for each filename in the current working directory. for %i in (*) do md "%~ni" Result Folder: \Dog\ \Cat\ Dog.jpg Cat.jpg I need to take this one step further and move the file into the folder. What I want to achieve is: \Dog\Dog.jpg \Cat\Cat.jpg Can someone help me with one command to do all of this?

    Read the article

  • Windows Server 08 R2 file share File locking, OSX clients

    - by Keith Loughnane
    I've spent the last two weeks banging my head against this wall. I think I'm starting to understand the problem though. I manage a design company and they have 5 macs (OSX 10.5/.6/.7) connected over SMB to a Windows 2008 R2 file server, another machine functions as Domain Controller (that might not matter). All the macs can connect ok, no issues finding the server or logging in. For the most part things are ok. The problem is files locking up. I thought it was a permissions issue at first but it seems to be file locking. The users open a file; .ind, .pdf etc the file opens, the software reads it and closes it. That's fine, but the folder above the folder locks, it can't be moved and it can't be renamed. Eg: /Working/Project01/Imagefiles/image.pdf /Finished/ The user opens image.pdf, closes it and wants to move the whole Project01 folder into Finished. It gives a username/pass dialogue and then does nothing, no error, or just does nothing. Trying to rename gives a dialogue that says you don't have permission. It looks like it's looking for permission locally, which is why I spent about a week looking at that. Eventually I found that Finder on the macs seems to be keeping the folders open. I can work around it by Killing finder, remounting the shared drive or closing the file through the server manager but this just proves the theory it's not a solution. Has anyone dealt with this problem?

    Read the article

  • CMD file time not always matching windows explorer file time

    - by skyrail
    I have a set of file I need to set the created, modified and last access date to exif date taken value, after a copy between 2 folders (might be fat32 on memory card or ntfs on fixed or usb disk). When I copy a file, the date and time switch to the current date. Then I change all 3 dates manually, either with change attributes in windows explorer or far manager on the command line. To make it faster I wrote a batch script getting original file dates (with php and function stat), building a batch script that invoke nircmd setfiletime for each file. Then I apply this batch to the copied version. The operation is relatively fast and reliable. Unfortunately, a bunch of files have last access and created time different in cmd and windows explorer (1H difference). Very strangely, it happens with dates between november and february, which make the operation unreliable. Why is this happening, and how can I fix it?

    Read the article

  • Outlook 2010 + Move IMAP PST file = Outlook data file cannot be accessed

    - by GWB
    I set up a new IMAP account in Outlook 2010. It works but creates IMAP PST file in C:\Users\User\AppData\Local\Microsoft\Outlook. I want the file on my data drive in D:\Users\User\Documents\Outlook Files (the same folder where outlook automatically creates the local Outlook PST. I followed the instructions here to move the IMAP PST. Testing the account (send/receive) works fine, but if I try to manually send an email I get error 0x8004010F Outlook data file cannot be accessed. I've tried repairing the PST using SCANPST (it always finds errors), and deleting and recreating the account but I get the same error. If I move the PST file back, it works again, but this is not ideal. Note: I don't think this is a duplicate of this question as the cause is different and the solution does not help.

    Read the article

  • How to copy file using NSIS ?

    - by Xinus
    I want to copy war file to tomcat web-app directory using NSIS setup. I have successfully installed tomcat and jdk using following script !define PRODUCT_NAME "App Deploy" !define PRODUCT_VERSION "1.0" !define PRODUCT_PUBLISHER "ZippySoft" SetCompressor lzma ;!include "UserManagement.nsh" ; MUI 1.67 compatible ------ !include "MUI.nsh" ; MUI Settings !define MUI_ABORTWARNING ;!define MUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\modern-install.ico" ; Welcome page !insertmacro MUI_PAGE_WELCOME ; Components page !insertmacro MUI_PAGE_COMPONENTS ; Instfiles page !insertmacro MUI_PAGE_INSTFILES ; Finish page !insertmacro MUI_PAGE_FINISH ; Language files !insertmacro MUI_LANGUAGE "English" ; Reserve files !insertmacro MUI_RESERVEFILE_INSTALLOPTIONS ; MUI end ------ Name "${PRODUCT_NAME} ${PRODUCT_VERSION}" OutFile "AppDeploy.exe" InstallDir "$PROGRAMFILES\App Deploy" ShowInstDetails show ;Section -SETTINGS ; SetOutPath "$INSTDIR" ; SetOverwrite ifnewer ;SectionEnd ;Section "JDK" SEC01 ; File "Prerequisites\jdk-1_5_0_15-windows-i586-p.exe" ; ExecWait "$INSTDIR\jdk-1_5_0_15-windows-i586-p.exe" ;SectionEnd ;System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("name", "value").r0' ;StrCmp $0 0 error ; ExecWait ProgThatReadsEnv.exe ; Goto done ;error: ; MessageBox MB_OK "Can't set environment variable" ;done: ;Section "Tomcat" SEC02 ; File "Prerequisites\apache-tomcat-6.0.16.exe" ; ExecWait "$INSTDIR\apache-tomcat-6.0.16.exe" ;SectionEnd Section "Data Submission Tool" SEC03 File "Prerequisites\DataSubmissionToolFinal.war" CopyFiles `$INSTDIR\DataSubmissionToolFinal.war` `c:\DataSubmissionToolFinal.war` StrCpy $0 "$INSTDIR\DataSubmissionToolFinal.war" ;Path of copy file from StrCpy $1 "c:\DataSubmissionToolFinal.war" ;Path of copy file to StrCpy $2 1 ; only 0 or 1, set 0 to overwrite file if it already exists System::Call 'kernel32::CopyFile(t r0, t r1, b r2) l' Pop $0 ; pops a bool. if overwrite is off and there is a file then error will be 1 SectionEnd There are no script errors but war file is not getting copied to c drive . How to do it? Also is it possible to identify path to JDK and Tomcat installation using NSIS ? Sorry if the question is too obvious, I am quite new to NSIS..

    Read the article

  • close file with fopen() but file still in use

    - by Marco
    Hi all, I've got a problem with deleting/overwriting a file using my program which is also being used(read) by my program. The problem seems to be that because of the fact my program is reading data from the file (output.txt) it puts the file in a 'in use' state which makes it impossible to delete or overwrite the file. I don't understand why the file stays 'in use' because I close the file after use with fclose(); this is my code: bool bBool = true while(bBool){ //Run myprogram.exe tot generate (a new) output.txt //Create file pointer and open file FILE* pInputFile = NULL; pInputFile = fopen("output.txt", "r"); // //then I do some reading using fscanf() // //And when I'm done reading I close the file using fclose() fclose(pInputFile); //The next step is deleting the output.txt if( remove( "output.txt" ) == -1 ){ //ERROR }else{ //Succesfull } } I use fclose() to close the file but the file remains in use by my program until my program is totally shut down. What is the solution to free the file so it can be deleted/overwrited? In reality my code isn't a loop without an end ; ) Thanks in advance! Marco

    Read the article

  • Java Copy/Paste org.w3c.dom.Node between two running copies of the same program

    - by Jay
    I have a program that shows a tree representation of an XML file. Using a number of sources online I have Copy/Paste within a single instance of the program working. I am using the system Clipboard. What I need though is to be able to copy a node from one instance of the program and paste to a different instance of the same program. I have tried a number of different options, all resulting in the same behavior. When pasting from within the same application the clipboardContent contains a "transferable" object with the correct data along with an isLocal set to "true". When I perform the copy and then attempt the paste from another instance of the same program running the clipboardContent contains a "flavorsToData" HashMap and "flavors" values, the check for isDataFlavorSupported fails (never hits my custom class that represents the new flavor). I have tried using different values for the requestor object in the getContents() call. Likewise I have tried a few different ClipboardOwners for the setContent() call. Neither seem to change the behavior in any way. I am sorely tempted to convert the node that is being copied back into a textual XML format, and then on the paste convert back to the DOM model, but would rather not if possible. This class is used to define the DataFlavor and transferable object: import java.awt.datatransfer.*; import org.w3c.dom.Node; public class NodeCopyPaste implements Transferable { static public DataFlavor NodeFlavor; private DataFlavor [] supportedFlavors = {NodeFlavor}; public Node aNode; public NodeCopyPaste (Node paraNode) { aNode = paraNode; try { NodeFlavor = new DataFlavor (Class.forName ("org.w3c.dom.Node"), "Node"); } catch (ClassNotFoundException e) { e.printStackTrace (); } } public synchronized DataFlavor [] getTransferDataFlavors () { return (supportedFlavors); } public boolean isDataFlavorSupported (DataFlavor nodeFlavor) { return (nodeFlavor.equals (NodeFlavor)); } public synchronized Object getTransferData (DataFlavor nFlavor) throws UnsupportedFlavorException { if (nFlavor.equals (NodeFlavor)) return (this); else throw new UnsupportedFlavorException (nFlavor); } public void lostOwnership (Clipboard parClipboard, Transferable parTransferable) { } } I define a Clipboard object from the main application screen and then tie in copy and paste handlers for the mouse clicks: During initialization I assign the system clipboard: clippy = Toolkit.getDefaultToolkit().getSystemClipboard(); Copy Handler Node copyNode = ((CLIInfo) node.getUserObject()).DOMNode.cloneNode(true); NodeCopyPaste contents = new NodeCopyPaste(copyNode); clippy.setContents (contents, null); Paste Handler Transferable clipboardContent = clippy.getContents (null); Node clonedNode = null; if ((clipboardContent != null) && (clipboardContent.isDataFlavorSupported (NodeCopyPaste.NodeFlavor))) { try { NodeCopyPaste tempNCP = (NodeCopyPaste) clipboardContent.getTransferData (NodeCopyPaste.NodeFlavor); clonedNode = tempNCP.aNode.cloneNode(true); } catch (Exception e) { e.printStackTrace (); } Thanks!

    Read the article

  • Windows 7 ssh file server.

    - by Siriss
    Hello all- I have looked at the other posts, but have not quite found an answer I have a question about windows file sharing over SSH. I have copssh installed and it is working for Remote desktop connections. I have port 22 forwarded on my router etc. I connect from a Mac or Putty with this address: ssh -l copsshusername 3391:localhost:3389 [external ip] That works fine. I would like to configure Windows 7 to allow my ssh account that I use to login, access to certain shared folders. I have documents and videos and things that I would like to be able to download externally. I have done this before on Linux and a long time ago on XP, but I cannot figure out what I am missing on Windows 7. There is a designated SSH user that copssh uses to run the service and that I use to to login as. I have googled and googled and have not found a solution that does everything I need that is why I am turning here for ideas. I hope I am explaining this correctly. Thank you very much for your help!

    Read the article

  • I need to copy only selected files and folders in PHP

    - by OM The Eternity
    I am using the following code, in which initially i am taking the difference of two folder structure and then the out put needs to be copied to other folder. here is the code below.. $source = '/var/www/html/copy1'; $mirror = '/var/www/html/copy2'; function scan_dir_recursive($dir, $rel = null) { $all_paths = array(); $new_paths = scandir($dir); foreach ($new_paths as $path) { if ($path == '.' || $path == '..') { continue; } if ($rel === null) { $path_with_rel = $path; } else { $path_with_rel = $rel . DIRECTORY_SEPARATOR . $path; } $full_path = $dir . DIRECTORY_SEPARATOR . $path; $all_paths[] = $path_with_rel; if (is_dir($full_path)) { $all_paths = array_merge( $all_paths, scan_dir_recursive($full_path, $path_with_rel) ); } } return $all_paths; } $diff_paths = array_diff( scan_dir_recursive($mirror), scan_dir_recursive($source) ); /*$diff_path = array_diff($mirror,$original);*/ echo "<pre>Difference ";print_r($diff_paths); foreach($diff_paths as $path) { echo $source1 = "var/www/html/copy2/".$path; echo "<br>"; $des = "var/www/html/copy1/".$path; copy_recursive_dirs($source1, $des); } function copy_recursive_dirs($dirsource, $dirdest) { $dir_handle=opendir($dirsource); mkdir($dirdest,0777); while(false!==($file=readdir($dir_handle))) {/*echo "<pre>"; print_r($file);*/ if($file!="." && $file!="..") { if(is_dir($dirsource.DIRECTORY_SEPARATOR.$file)) { //Copy the file at the same level in the destination folder copy_recursive_dirs($dirsource.DIRECTORY_SEPARATOR.$file, $dirdest.DIRECTORY_SEPARATOR.$file); } else{ //Copy the dir at the same lavel in the destination folder copy ($dirsource.DIRECTORY_SEPARATOR.$file, $dirdest.DIRECTORY_SEPARATOR.$file); } } } closedir($dir_handle); return true; } Whenever I execute the script I get the difference output but do not get the other copy on second folder as per code... Pls help me in rectifying...

    Read the article

  • Force copy files off CRC error filled hard drive

    - by TheLakersHighlights
    So I got a dying Western Digital hard drive here and I have a new Western Digital hard drive to transfer all the data to. I have the new HDD hooked up by a SATA to USB. I want to transfer all the pictures, etc to the new HDD. I am unable to because of the CRC error. I have ran chkdsk /f /r and it didnt work because the drive is just simply dying. What tool will let me bypass CRC and continue on with the copying? OS: Vista Home Prem. 32bit

    Read the article

  • Unable to copy files previously extracted from archives created on a Mac, even after claiming ownership

    - by Maxim Zaslavsky
    I reinstalled Windows on my computer today, and backed up my music to a USB drive. Now, I'm trying to copy the files onto my fresh Windows partition, but I'm unable to copy files that I obtained within my previous Windows installation from zip archives created on Macs. When I try to copy those previously-extracted files, I get an error saying that I need permission from S-1-5-21-...-1000 (a bizarre long ID). The first thing I tried was to take ownership of the files by setting my new user account as the owner, but that resulted in errors saying that I need permission from myself! Some Googling suggested adding antivirus suggestions, so I excluded the relevant folders from Microsoft Security Essentials, but the issue persists. For what it's worth, it seems that some program (so far I've only installed Chrome, Microsoft Security Essentials, and the latest Windows updates) created an empty folder named 601c8c7f0e0c03f725 at the root of my external USB hard drive. What gives?

    Read the article

  • Copy large files to multiple machines on a LAN

    - by Jonathan Callen
    I have a few large files that I need to copy from one Linux machine to about 20 other Linux machines, all on the same LAN as quickly as is feasible. What tools/methods would be best for copying these files, noting that this is not going to be a one-time copy. These machines will never be connected to the Internet, and security is not an issue. Update: The reason for my asking this is because (as I understand it) we are currently using scp in serial to copy the files to each of the machines and I have been informed that this is "too slow" and a faster alternative is being sought. According to what I have been told, attempting to parallelize the scp calls simply slows it down further due to hard drive seeks.

    Read the article

  • Automatically copy files to USB drive when connected

    - by Daphna
    I am looking for a solution for copying all the files from a specific directory on the hard drive, to a specific directory on a USB memory device, once this device is connected. I have a program that downloads podcast episodes for me. I would like these files to be automatically moved (or at least copied) to my mp3 player once I connect it to the computer. I have both windows xp and linux machines, so a solution for any of them will work for me.

    Read the article

< Previous Page | 6 7 8 9 10 11 12 13 14 15 16 17  | Next Page >