Search Results

Search found 2397 results on 96 pages for 'copying'.

Page 62/96 | < Previous Page | 58 59 60 61 62 63 64 65 66 67 68 69  | Next Page >

  • Cannot execute cut-n-paste VBScripts

    - by IcedDante
    I have been going mad trying to figure out why my scripts weren't working, until I started copying and pasting sample source code directly from a few websites only to have it fail there as well. I am getting the following error in my VBScripts: C:\temp\vbs\script.vbs(19, 53) Microsoft VBScript compilation error: Expected statement' For a line of code that looks like this: wdoc.Application.Selection.Find.Execute Replace:=wdReplaceAll This is interfacing with Microsft Word in Office 2007 to conduct a search and replace. Index 53 point directly to the := part of the assignment. Since this type of syntax doesn't work on my machine and I am using it from several websites, I was wondering if the cscript.exe I use is out of date. Am I not calling cscript properly?

    Read the article

  • failed to open stream: HTTP request failed! HTTP/1.1 400 Bad Request

    - by muralikalpana
    I am accessing images from another website. I am getting "failed to open stream: HTTP request failed! HTTP/1.1 400 Bad Request " error when copying 'some(not all)' images. here is my code. $img=$_GET['img']; //another website url $file=$img; function getFileextension($file) { return end(explode(".", $file)); } $fileext=getFileextension($file); if($fileext=='jpg' || $fileext=='gif' || $fileext=='jpeg' || $fileext=='png' || $fileext=='x-png' || $fileext=='pjpeg'){ if($img!=''){ $rand_variable1=rand(10000,100000); $node_online_name1=$rand_variable1."image.".$fileext; $s=copy($img,"images/".$node_online_name1); }

    Read the article

  • javax.servlet import cannot be resolved after moving web servlet

    - by Michael Kjörling
    I have written a small web servlet to run under Tomcat, using Eclipse Helios. In its old, non-source-controlled location, everything was fine, but now I need to add this to our source control system. Moving the old files out of the way, creating a new workspace, setting up the server connection and copying and importing the existing projects into the new workspace all worked fine once I figured out how to do it, but I can't get the servlet to build. Instead, I get a whole bunch of cannot be resolved to a type errors talking about various servlet class types; HttpServlet, HttpServletRequest, ServletException, etc. Another error that is almost certainly related is The import javax.servlet cannot be resolved. I am obviously missing something very basic, but I'm new to this (and not having the terminology really down pat probably doesn't help me Google for an answer). Any suggestions as to what I might be missing would be greatly appreciated.

    Read the article

  • How to store images efficiently (memory-wise) while still being able to process them

    - by Sheeo
    I'm working on a silverlight project where users get to create their own Collages. The problem When loading images into memory, I'm using BitmapImage so that they can be displayed directly with the Image control--but they're locked in afterwards. So I've tried storing them seperately aswell, but that just sucks up huge amounts of RAM. So in short, is there a class that'll let me store JPEG images, be able to show them with the image control, and still be able to export it afterwards? All this needs to be efficient--i.e. I'd rather not want any copying to ARGB arrays or use the WriteableBitmap to copy them over. I require to work with large collections of images, up to 300 at most. Any help apreciated!

    Read the article

  • How can I use BeanUtils copyProperties to copy from boolean to Boolean?

    - by carrier
    BeanUtils copyProperties, out of the box, doesn't seem to handle copying from Boolean object properties to boolean primitive properties. I figured I could create and register a converter to handle this, but that just didn't seem to work. So, how can I use BeanUtils to copy the properties from class Source to class Destination where: public class Destination { private boolean property; public boolean isProperty() { return property; } public void setProperty(boolean property) { this.property = property; } } public class Source{ private Boolean property; public Boolean getProperty() { return property; } public void setProperty(Boolean property) { this.property = property; } }

    Read the article

  • Detect template presence at compilation time

    - by doublep
    GCC up to 4.5 doesn't have standard C++0x type trait template has_nothrow_move_constructor. I could use it in my package for optimization, but I don't want to rule out one of the common compilers and don't want to overload configuration with symbols like HAVE_STD_HAS_NOTHROW_MOVE_CONSTRUCTOR. Is it somehow possible to use that template if present and just fall back to copying if not present without using any predefined configuration symbols? I also don't want to depend on Boost, since my library is small and doesn't need Boost for any other reasons. In pseudocode, I need something like: template <typename type> struct has_nothrow_move_constructor_robust : public integral_constant <bool, /* if possible */ has_nothrow_move_constructor <type>::value /* otherwise */ false> { }; Since move constructors are only for C++0x anyway, I don't mind using other C++0x features for the above definition, if at all possible.

    Read the article

  • What is the fastest way to copy content of DVD to hard disc using Linux

    - by Ritesh
    I have gone through some of the links Which talks about fastest way of copying files in windows using FILE_FLAG_NO_BUFFERING and FILE_FLAG_OVERLAPPED . It also talks about how request made for read and write opeartions with BUFFER SIZE as 256KB and 128KB are faster than 1Mb .The link for that is :- Explanation for tiny reads (overlapped, buffered) outperforming large contiguous reads? I am also loking for a Similar method in linux Which allows me to copy the content of my DVD to Hard Disc in a fast Way . So I wanted to know Is there some file operation flags in Linux which would provide me the best result or Which way of Copy in Linux is the best ? My codes are all in c++.

    Read the article

  • Elegant way for a recursive C++ template to do something different with the leaf class?

    - by Costas
    I have a C++ class template that makes an Array of pointers. This also gets typedefed to make Arrays of Arrays and so on: typedef Array<Elem> ElemArray; typedef Array<ElemArray> ElemArrayArray; typedef Array<ElemArrayArray> ElemArrayArrayArray; I would like to be able to set one leaf node from another by copying the pointer so they both refer to the same Elem. But I also want to be able to set one Array (or Array of Arrays etc) from another. In this case I don't want to copy the pointers, I want to keep the arrays seperate and descend into each one until I get to the leaf node, at where I finally copy the pointers. I have code that does this (below). When you set something in an Array it calls a CopyIn method to do the copying. But because this is templated it also has to call the CopyIn method on the leaf class, which means I have to add a dummy method to every leaf class that just returns false. I have also tried adding a flag to the template to tell it whether it contains Arrays or not, and so whether to call the CopyIn method. This works fine - the CopyIn method of the leaf nodes never gets called, but it still has to be there for the compile to work! Is there a better way to do this? #include <stdio.h> class Elem { public: Elem(int v) : mI(v) {} void Print() { printf("%d\n",mI); } bool CopyIn(Elem *v) { return false; } int mI; }; template < typename T > class Array { public: Array(int size) : mB(0), mN(size) { mB = new T* [size]; for (int i=0; i<mN; i++) mB[i] = new T(mN); } ~Array() { for (int i=0; i<mN; i++) delete mB[i]; delete [] mB; } T* Get(int i) { return mB[i]; } void Set(int i, T* v) { if (! mB[i]->CopyIn(v) ) { // its not an array, so copy the pointer mB[i] = v; } } bool CopyIn(Array<T>* v) { for (int i=0; i<mN; i++) { if (v && i < v->mN ) { if ( ! mB[i]->CopyIn( v->mB[i] )) { // its not an array, so copy the pointer mB[i] = v->mB[i]; } } else { mB[i] = 0; } } return true; // we did the copy, no need to copy pointer } void Print() { for (int i=0; i<mN; i++) { printf("[%d] ",i); mB[i]->Print(); } } private: T **mB; int mN; }; typedef Array<Elem> ElemArray; typedef Array<ElemArray> ElemArrayArray; typedef Array<ElemArrayArray> ElemArrayArrayArray; int main () { ElemArrayArrayArray* a = new ElemArrayArrayArray(2); ElemArrayArrayArray* b = new ElemArrayArrayArray(3); // In this case I need to copy the pointer to the Elem into the ElemArrayArray a->Get(0)->Get(0)->Set(0, b->Get(0)->Get(0)->Get(0)); // in this case I need go down through a and b until I get the to Elems // so I can copy the pointers a->Set(1,b->Get(2)); b->Get(0)->Get(0)->Get(0)->mI = 42; // this will also set a[0,0,0] b->Get(2)->Get(1)->Get(1)->mI = 96; // this will also set a[1,1,1] // should be 42,2, 2,2, 3,3, 3,96 a->Print(); }

    Read the article

  • SVN is not recognizing the changed files

    - by Tom Brito
    I had made changes in a folder called "branch", and now that its working I want to move all the src folder to the folder "trunk". But by copying src from local branch, pasting on local trunk and commiting the SVN commits nothing. Its like nothing had changed. Any idea how to commit this? Related question: http://stackoverflow.com/questions/206183/how-can-i-force-subversion-to-commit-an-unchanged-file (Would work for me, but I know nothing about properties, exactly which one could I change and with which value to not crash something?)

    Read the article

  • Deploying backing bean with composite component in separate jar

    - by Checkoff
    I have some difficulties deploying my web app on JBoss AS 6.1. My current Project is separated into the main web app (controller/managed beans & web frontend using JSF 2 facelets) and one jar with the composite components + backing beans. But when I try to access the page I got an error that the specified component type could not be instantiated. Copying the backing bean into the main web app solves the problem, but this isn't what I want. So is there anything to pay attention to? The backing bean looks like @FacesComponent(value = "elementBase") public class ElementBase extends UINamingContainer { ... } and the composite components interface <composite:interface componentType="elementBase"> ... some attributes </composite:interface> The structure of the jar is the following -- META-INF |-- resources | |-- components | |-- elementBase.xhtml -- com |-- example | |-- ElementBase.class I've also tried to add faces-config.xml within META-INF folder, with the component type, but the component type was still not found.

    Read the article

  • Hibernate Updating an existing entity with a new object

    - by DD
    Hi, Assume I have an entity Foo in the DB. I am parsing some files and creating new Foo objects and would like to check if the parsed Foo object exists in the DB (using a unique attribute). If it exists already update it otherwise save as a new object. What is the best approach? Could I simply set the id and version in the new Foo object? Or would I be better off loading the Foo object from the DB and copying over the properties from the parsed file? Thanks.

    Read the article

  • Python: mysqldb install error

    - by Grenko
    So i've been pulling my hair out trying to install the mysqldb package. When i run the build i get a long transcript of errors, heres just part of it, i would posit it all but its huge list of errors [rv@med240-183 MySQL-python-1.2.3c1]$ sudo python setup.py build [sudo] password for rv: running build running build_py copying MySQLdb/release.py -> build/lib.linux-i686-2.6/MySQLdb running build_ext building '_mysql' extension gcc -pthread -fno-strict-aliasing -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i586 -mtune=generic -fasynchronous-unwind-tables -D_GNU_SOURCE -fPIC -fPIC -Dversion_info=(1,2,3,'gamma',1) -D__version__=1.2.3c1 -I/usr/include/mysql -I/usr/include/python2.6 -c _mysql.c -o build/temp.linux-i686-2.6/_mysql.o -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -fasynchronous-unwind-tables -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fno-strict-aliasing -fwrapv -fPIC -DUNIV_LINUX _mysql.c:36:23: error: my_config.h: No such file or directory _mysql.c:38:19: error: mysql.h: No such file or directory Any ideas?

    Read the article

  • Three20 Library Cannot find its own headers Xcode iPhone

    - by DieLaughing
    import "Three20/Three20.h" Fails. Go download it and build a sample app. If that works, then make a new app from the templates provided, then watch as it fails spectacularly to find the right HEADER_SEARCH_PATH. 1) I've gone to the info page for the TARGET and not the PROJECT (Well, I tried both) and tried a bunch of different paths for the HEADER_SEARCH_PATH field. 2) I've tried dragging and dropping the dependent files from the finder and COPYING or just referencing both fails. (RANT: WTF?! Really? I wish public code libraries saved me time ONCE in my life.)

    Read the article

  • Painless way to install a new version of R?

    - by Shane
    Andrew Gelman recently lamented the lack of an easy upgrade process for R (probably more relevant on Windows that Linux). Does anyone have a good trick for doing the upgrade, from installing the software to copying all the settings/packages over? This suggestion was contained in the comments and is what I've been using recently. First you install the new version, then run this in the old verion: #--run in the old version of R setwd("C:/Temp/") packages <- installed.packages()[,"Package"] save(packages, file="Rpackages") Followed by this in the new version: #--run in the new version setwd("C:/Temp/") load("Rpackages") for (p in setdiff(packages, installed.packages()[,"Package"])) install.packages(p)

    Read the article

  • Emacs with CEDET changes copy/paste to include trailing spaces?

    - by Paul D.
    I just started trying out CEDET today, which I really like, but it seems to do something completely worthless with respect to copying/pasting. If I highlight some stuff and copy it, when it gets pasted back the newlines are eliminated and there is just a ton of trailing whitespace on each line. This is really worthless. All I have in my .emacs right now for CEDET is the following: (load-file "~/.emacs.d/cedet-1.0pre7/common/cedet.el") (require 'semantic-ia) (require 'semantic-gcc) (semantic-load-enable-code-helpers) Does anybody know how to turn this off? I can't find anything about this except that the CEDET main page says it has "magic copy & paste".

    Read the article

  • asp.net 3.5 on windows 2000

    - by SiC
    Hi, I am trying to get an ASP.net 3.5 site to run on a windows 2000 machine (not my idea!!!) but am having some problems. I have been working through copying required dlls from C:\Program Files\Reference Assemblies\Microsoft\Framework\v3.5 into my app bin directory. This succesfully got me past the "assembly not found" errors. However, I am now getting the error: "Compiler executable file csc.exe cannot be found". Does anyone know how I can fix this? It is primarily LINQ functionality I am looking to utilise. Many thanks!!

    Read the article

  • Sending a 'copy' command in cocoa

    - by Ben Packard
    Is there any way to send a copy (command-c) instruction without using a cgEvent to mimic the keystrokes? I don't have access to the text field in the application I want to take text from, so need to replicate manually copying to the clipboard, and there seemss to be a bug with cgevent posting. According the Quartz documentation, to type a capital Z I should use: CGEventRef event1, event2, event3, event4; event1 = CGEventCreateKeyboardEvent (NULL, (CGKeyCode)56, true); event2 = CGEventCreateKeyboardEvent (NULL, (CGKeyCode)6, true); event3 = CGEventCreateKeyboardEvent (NULL, (CGKeyCode)6, false); event4 = CGEventCreateKeyboardEvent (NULL, (CGKeyCode)56, false); However, if I attach this set of instuctions to an NSTimer, it only works the first time it is fired. example output: ZzzZzzzzZZzzZ (vs expected ZZZZZZZZZ). How else might I send a copy command to the active window?

    Read the article

  • Use LINQ to SQL results inside SQL Server stored procedure

    - by ifwdev
    Note: I'm not trying to call a SQL Server stored proc using a L2SQL datacontext. I use LINQPad for some fairly complex "reporting" that takes L2SQL output saved to an Array and is processed further. For example, it's usually much easier to do multiple levels of grouping with LINQ to Objects instead of trying to optimize a T-SQL query to run in a reasonable amount of time. What would be the easiest way to take the end result of one of these "applications" and use that in a SQL Server 2008 stored proc? The idea is to use the data for a Reporting Services Report, rather than copying and pasting into Excel (manual labor). The reports need to be accessible on the report server (not using the Report Server control in an application). I could output CSV and read that somehow via command line exec, but that seems like a hack. Thanks for your help.

    Read the article

  • Inline function and calling cost in C

    - by Eonil
    I'm making a vector/matrix library. (GCC, ARM NEON, iPhone) typedef struct{ float v[4]; } Vector; typedef struct{ Vector v[4]; } Matrix; I passed struct data as pointer to avoid performance degrade from data copying when calling function. So I thought designed function like this: void makeTranslation(const Vector* factor, Matrix* restrict result); But, if function is inline, is there any reason to pass values as pointer for performance? Do those variables copied too? How about register and caches? inline Matrix makeTranslation(Vector factor) __attribute__ ((always_inline)); How do you think about calling costs of each cases?

    Read the article

  • Can I Import an updated structure into a MySQL table without losing its current content?

    - by Udi Wertheimer
    We use MySQL tables to which we add new fields from time to time as our product evolves. I'm looking for a way to export the structure of the table from one copy of the db, to another, without erasing the contents of the table I'm importing to. For example say I have copies A and B of a table, and I add fields X,Y,Z to table A. Is there a way to copy the changed structure (fields X,Y,Z) to table B while keeping its content intact? I tried to use mysqldump, but it seems I can only copy the whole table with its content, overriding the old one, or I can use the "-d" flag to avoid copying data (dumping structure only), but this will create an empty table when imported, again overriding old data. Is there any way to do what I need with mysqldump, or some other tool?

    Read the article

  • HTA value update freezes when file copy starts

    - by Matt Hamende
    Creating an HTA that will automate the installation of several applications it starts by checking for the existence of certain files then copies a large folder to local from a flash drive if it doesn't exist, I have a textbox I'm using to update the current status of the script, but it just seems to freeze and never updates, I haven't had any luck with any of the artificial sleep functions either. here's the segment If Not objFSO.FileExists(Office10Dir) Then MsgBox("Excel is missing") BasicTextBox.Value = "Office14 Not Detected, Copying Source Files to Local" Dim objFS, objFolder Dim OfficeTemp OfficeTemp = "C:\OfficeTemp" Set objFS = CreateObject("Scripting.FileSystemObject") Set objFolder = objFS.CreateFolder(OfficeTemp) objFS.CopyFolder "OfficeTemp", "C:\OfficeTemp" BasicTextBox.Value = "Local Temp Directory Created" ELSE MsgBox("Excel is Installed") END IF All i see is the "Local Temp Directory Created" message once file copy is complete

    Read the article

  • Is there any "modern" text editor with command-line?

    - by Pedro Morte Rolo
    A command line in a text editor is a wonderful feature. It allows the user to explore the editor's functionality and learn it's shortcuts in a textual way. It's much faster than using the mouse, and it is much easier to memorise "shortcuts" this way. Emacs and VI provide this, though, emacs and vi are not "modern". By "modern", I mean one that is original built to cope with the modern de-facto standards of selecting, copying, pasting, cutting, undoing, redoing and auto-completing. Cream/vi or EmacsCUE are not valid options, since there are loads of things built over them that conflict with the mentioned stuff. Is there any alternative? (I do not intend to use the "modern" term as derrogatory. I love both Emacs and VI, but I hate their keyboard shortcut baggage.) (please do not advertise Vim and Emacs, that's not answering the question. I am asking for alternatives)

    Read the article

  • Me As Child Type In General Function

    - by Steven
    I have a MustInherit Parent class with two Child classes which Inherit from the Parent. How can I use (or Cast) Me in a Parent function as the the child type of that instance? EDIT: My actual goal is to be able to serialize (BinaryFormatter.Serialize(Stream, Object)) either of my child classes. However, "repeating the code" in each child "seems" wrong. EDIT2: This is my Serialize function. Where should I implement this function? Copying and pasting to each child doesn't seem right, but casting the parent to a child doesn't seem right either. Public Function Serialize() As Byte() Dim bFmt As New BinaryFormatter() Dim mStr As New MemoryStream() bFmt.Serialize(mStr, Me) Return mStr.ToArray() End Function

    Read the article

  • How can I copy an XmlNode from one XmlDocument to another?

    - by Chris Wenham
    I'm building a tool that authors/edits XML files, and I want to be able to populate it with template fragments defined in another XML file. For example, the tool has an "Add FooBarBaz Element" button that adds a element to the new document being created, and I want to add FooBarBaz by copying it from a template. Or let's say this is my template file: <Templates> <FooBarBaz Attribute="Value"> <ChildElement/> </FooBarBaz> </Templates> I can then grab a template fragment with .GetElementsByTagName("FooBarBaz"), and I'd like to be able to inject it into the new document with something like .AppendChild(templateNode). But the problem is that an XmlNode cannot be copied from one XmlDocument to another, even if you use .Clone() or .CloneNode(), because AppendChild() throws an exception saying that the template element belongs to another context. Is there an easy way to copy a System.Xml.XmlNode between System.Xml.XmlDocuments?

    Read the article

  • Use branching in TFS for 32 bit and 64 bit version of a software?

    - by Malkier
    Hi everyone, we are in the process of porting a 32bit application, which uses the Outlook Redemption DLL to a 64 bit version, since redemption has recently been released as a 64 bit version as well. We'd like to maintain two versions of the application, one for 32 and one for 64 bit. What is the best way to organize these projects under team foundation server source control? Would I create a branch of the existing 32 bit version? Copying the whole project seems sub-optimal since it would duplicate all the business logic code. Any suggestions?

    Read the article

< Previous Page | 58 59 60 61 62 63 64 65 66 67 68 69  | Next Page >