Search Results

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

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

  • Copying contents of a module

    - by Hulk
    If there exists an old data of a model say , query=Emp.objects.filter(pk=profile.id) Is there a easier way to copy the same values into the same model again.. Now that the id will be different so.. I have this requirement. Thanks..

    Read the article

  • Problem copying files through xcopy using VBScript

    - by sushant
    I am using VBScript to copy files using xcopy. The problem is that the folder path has to be entered by the user. Assuming I put that path in a variable, say h, how do I use this variable in the xcopy command? Here is the code I tried: Dim WshShell, oExec, g, h h = "D:\newfolder" g = "xcopy $h D:\y\ /E" Set WshShell = CreateObject("WScript.Shell") Set oExec = WshShell.Exec(g) I also tried &h but it did not work. Could anyone help me work out the correct syntax? Any help is appreciated.

    Read the article

  • Install driver and copying files before Installation runs

    - by Kazoom
    I have created installation package for my project, but before or after installation is complete i need to install some drivers and copy some files to target machine, before my software can run. Is it possible for me to do all this action in the MSI installer setup project of visual studio 2005. One option i have explored is using autoITscript, is there a better approach than that? i feel able to do the whole thing in visual studio would be an ideal way? any suggestions? Thanks

    Read the article

  • File copying issue while converting to LPCTSTR

    - by sijith
    // Convert to a wchar_t* size_t origsize = strlen(toChar) + 1; const size_t newsize = 100; size_t convertedChars = 0; wchar_t wcstring[newsize]; mbstowcs_s(&convertedChars, wcstring, origsize, toChar, _TRUNCATE); wcscat_s(wcstring, L"\\*.*\0"); wcout << wcstring << endl; // C:\Documents and Settings\softnotions\Desktop\Release\*.* SHFILEOPSTRUCT sf; memset(&sf,0,sizeof(sf)); sf.hwnd = 0; sf.wFunc = FO_COPY; //sf.pFrom =wcstring; /* when giving wcstring i am not getting answer */ sf.pFrom = L"C:\\Documents and Settings\\softnotions\\Desktop\\Release\\*.*\0"; wcout << sf.pFrom <<endl; // C:\Documents and Settings\softnotions\Desktop\Release\*.* Both wcstring and sf.pFrom are same then y not gettng answer when assigning sf.pFrom =wcstring;

    Read the article

  • Sitecore - Rich Text Editor field is not saving information but instead just copying old information

    - by Younes
    We are using Sitecore.NET 5.3.1 (rev. 071114) and we found out a problem. When we are trying to change information in a Rich Text Editor field on the Master database and save the information, this information is not stored and instead the old information appears back into the RTE field. I have been trying this on the Web database on which this is not happening. However, changing this information on the web database feels useless because a publish will just change every information that does not correspond to the data in the Master database in which i just can't edit this field. So I'm having big trouble at this point since this is for one of our bigger customers and they really want this fixxed asap. We (Estate Internet) already have had an open ticket for this problem, but never got the solution. Hope that someone here knows what the problem may be.

    Read the article

  • NSString copy not copying?

    - by Scotty Allen
    NSString *myString = @"sample string"; NSString *newString = [NSString stringWithString: myString]; If I set a breakpoint after these two lines, the pointer for myString is the same as the pointer for newString. WTF? Isn't NSString copy supposed to return a pointer to a new object? Or am I missing something fundamental about how copy is supposed to work?

    Read the article

  • Confused about copying Arrays in Objective-C

    - by Sheehan Alam
    Lets say I have an array X that contains [A,B,C,D,nil]; and I have a second array Y that contains [E,F,G,H,I,J,nil]; If I execute the following: //Append y to x [x addObjectsFromArray:y]; //Empty y and copy x [y removeAllObjects]; y = [x mutableCopy]; What is the value of y? is it?: [A,B,C,D,E,F,G,H,I,J,nil] Am I performing the copy correctly?

    Read the article

  • copying the request header from request object to urlConnection object

    - by Bunny Rabbit
    protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { // TODO Auto-generated method stub URL url = new URL("http://localhost:8080/testy/Out"); HttpURLConnection connection = (HttpURLConnection) url.openConnection(); connection.setDoOutput(true); connection.setRequestMethod("POST"); PrintWriter out=response.getWriter(); for(Enumeration e=request.getHeaderNames();e.hasMoreElements();){ Object o=e.nextElement(); String value=request.getHeader(o.toString()); out.println(o+"--is--"+value+"<br>"); connection.setRequestProperty((String) o, value); } connection.connect(); } i wrote the above code in a servlet to post form so some alternate locations than this servlet,but its not working.is it okay to use connection.setRequestProperty to set the header fields to what they are in the incoming request to servlet.

    Read the article

  • Black background while copying image from Firefox

    - by Eduardo Mauro
    An image is copied from Firefox into the Clipboard. My program gets it from clipboard and saves as a JPEG image. For some reason the image is saved with a black background. If I open the same URL in IE and copy the image into the Clipboard, the image is saved correctly by my program. I am using Delphi 7. I also tried to copy the image from Firefox into Microsoft Paint and again the black background. Does anyone has a tip in how to handle such problem.

    Read the article

  • copying link id to an input field

    - by zurna
    The code works fine when links are images. But I have a problem when there are flash movies. Another page opens with undefined in the address bar when it needs to copy the link id to imagesID input box. <script type="text/javascript"> var $input = $("#imagesID"); // <-- your input field $('a.thumb').click(function() { var value = $input.val(); var id = $(this).attr('id'); if (value.match(id)) { value = value.replace(id + ';', ''); } else { value += id + ';'; } $input.val(value); }); </script> <ul class="thumbs"> <li> <a class="thumb" id="62"> <img src="/FLPM/media/images/2A9L1V2X_sm.jpg" alt="Dock" id="62" class="floatLeft" /> </a> <br /> <a href="?Process=&IMAGEID=62" class="thumb"><span class="floatLeft">DELETE</span></a> </li> <li> <a class="thumb" id="61"> <img src="/FLPM/media/images/0E7Q9Z0C_sm.jpg" alt="Desert Landscape" id="61" class="floatLeft" /> </a> <br /> <a href="?Process=&IMAGEID=61" class="thumb"><span class="floatLeft">DELETE</span></a> </li> <li> <a class="thumb" id="60"> <img src="/FLPM/media/images/8R5D7M8O_sm.jpg" alt="Creek" id="60" class="floatLeft" /> </a> <br /> <a href="?Process=&IMAGEID=60" class="thumb"><span class="floatLeft">DELETE</span></a> </li> <li> <a class="thumb" id="59"> <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://active.macromedia.com/flash4/cabs/swflash.cab#version=4,0,0,0" id="59" width="150" height="100" style="float:left; border:5px solid #CCCCCC; margin:5px 10px 10px 0;"> <param name="scale" value="exactfit"> <param name="AllowScriptAccess" value="always" /> <embed name="name" src="http://www.refinethetaste.com/FLPM/media/flashes/7P4A6K7M.swf" quality="high" scale="exactfit" width="150" height="100" type="application/x-shockwave-flash" AllowScriptAccess="always" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi? P1_Prod_Version=ShockwaveFlash"> </embed> </object> </a> <br /> <a href="?Process=&IMAGEID=59" class="thumb"><span class="floatLeft">DELETE</span></a> </li> </ul>

    Read the article

  • Copying data across tabs

    - by Guillermo
    Hello, I got two different forms in two different tabs. One has data from our system and the other one is an interface of another, external, system in wich we need to copy data into (XML or API integration not an option here) The this is that, having open both forms - in two different tabs - i need a greasemonkey script or something similar that allows my to copy data from one form to the other (using the getValue method in Javascript). The problem right now is that I cannot figure out how to reference with a greasemonkey script one particular tab or window (to rad data from or write data to). Do you think it would be possible to do what I'm thinking to do? THANKS

    Read the article

  • Copy folders when copying list items from source to destination

    - by iHeartDucks
    Hi, This is my code to copy files in a list from source to destination. Using the code below I am only able to copy files but not folders. Any ideas on how can I copy the folders and the files within those folders? using (SPSite objSite = new SPSite(URL)) { using (SPWeb objWeb = objSite.OpenWeb()) { SPList objSourceList = null; SPList objDestinationList = null; try { objSourceList = objWeb.Lists["Source"]; } catch(Exception ex) { Console.WriteLine("Error opening source list"); Console.WriteLine(ex.Message); } try { objDestinationList = objWeb.Lists["Destination"]; } catch (Exception ex) { Console.WriteLine("Error opening destination list"); Console.WriteLine(ex.Message); } string ItemURL = string.Empty; if (objSourceList != null && objDestinationList != null) { foreach (SPListItem objSourceItem in objSourceList.Items) { ItemURL = string.Format(@"{0}/Destination/{1}", objDestinationList.ParentWeb.Url, objSourceItem.Name); objSourceItem.CopyTo(ItemURL); objSourceItem.UnlinkFromCopySource(); } } } } Thanks

    Read the article

  • copying a jar file in Apache Ant

    - by synchronicity
    I need to copy a jar file from one directory to another when my project is built. Placing the statement: <copy file="${test.dir}/MyFirstTest.jar" todir="${share.path}"/> works fine when the project is built alone, but if I clean and build the project I get a warning informing me that the ${test.dir}/ directory hasn't been created yet. If I'm understanding properly I should be able to create a 'target' and specify a dependency for this operation but I'm unsure of what dependency to specify. What series of statements do I need to use to ensure this copy will occur whether I clean and build or just build the project? Please let me know if any further clarification is needed. FYI I am using Netbeans 6.8 to build my project.

    Read the article

  • How to troubleshoot dependencies not copying.

    - by AngryHacker
    I have an EXE project A, which references a class library project B (all in the same solution). Project B has a reference to about 10 3rd party DLLs (from DevExpress). All the referenced assemblies have Copy Local set to true. When I build the entire solution, the resulting DLL from project B is copied into the bin/debug of project A. However, none of the dependencies of project B get copied. I looked in the Output window during compile and all looks good. There aren't any errors. How do I troubleshoot this?

    Read the article

  • Extension Method for copying properties form object to another, with first attempt

    - by James
    Hi All, Im trying to write an extension method that I can use to copy values from one object property to another object of a different type, as long as the property names and types match exactly. This is what I have: public static T CopyFrom<T>(this T toObject, object fromObject) { var fromObjectType = fromObject.GetType(); var fromProperties = fromObjectType.GetProperties(); foreach (PropertyInfo toProperty in toObject.GetType().GetProperties()) { PropertyInfo fromProperty = fromObjectType.GetProperty(toProperty.Name); if (fromProperty != null) // match found { // check types var fromType = fromProperty.PropertyType.UnderlyingSystemType; var toType = toProperty.PropertyType.UnderlyingSystemType; if (toType.IsAssignableFrom(fromType)) { toProperty.SetValue(toObject, fromProperty.GetValue(fromObject, null), null); } } } return toObject; } This is working great for non boxed types, but Nullable<T> returns false when I call toType.IsAssignableFrom(fromType) because its type is Nullable<T> and is not the underlying type T. I read here that GetType() should unbox the Nullable<T> so it returns T but if I call that on PropertyInfo.PropertyType I get ReflectedMemberInfo and not the type T im looking for. I think im missing something obvious here, so I thought I would throw it open to SO to get some advice. Anyone have any ideas? Thanks, Jamee

    Read the article

  • copying a struct with a struct member to another struct

    - by user1839295
    is the following code correct? typedef struct { int x; int y; } OTHERSTRUCT; struct DATATYPE { char a; OTHERSTRUCT b; } // ... // now we reserve two structs struct DATATYPE structA; struct DATATYPE structB; // ... probably fill insome values // now we copy structA to structB structA = structB; Are both structs now completely identical? Even the "struct in the struct"? Thanks!

    Read the article

  • Copying a directory that is version controlled

    - by ibz
    I am curious whether it is OK to copy a directory that is under version control and start working on both copies. I know it can be different from one VCS to another, but I intentionally don't specify any VCS since I am curious about different cases. I was talking to a coworker recently about doing it in SVN. I think it should be OK, but I am still not 100% sure, since I don't know what exactly SVN is storing in the working copy. However, if we talk about the DVCS world, things might be even more unclear, since every working copy is a repository by itself. Being faced with doing this in bzr now, I decided to ask the question. Later edit: Some people asked why I would want to do that. Here is the whole story: In the case of SVN it was because being out of the office, the connection to the SVN server was really slow, so me and my coworker decided to check out the sources only once and make a local copy. That's what we did and it worked OK, but I am still wondering whether it is guaranteed to work, or it just happened. In the bzr case, I am planning to move the "main" repo to another server. So I was thinking to just copy it there and start considering that the main repo. I guess the safest is to make a clone though.

    Read the article

  • Best practice for copying private instance vars with NSCopying

    - by Ben
    I might be missing something obvious here, but I'm implementing NSCopying on one of my objects. That object has private instance variables that are not exposed via getters, as they shouldn't be used outside the object. In my implementation of copyWithZone:, I need alloc/init the new instance, but also set up its state to match the current instance. I can obviously access current private state from inside copyWithZone:, but I can't set it into the new object, because there are no accessors for that state. Is there a standard way around this while still keeping data privacy intact? Thanks.

    Read the article

  • MS Excel - Copying columns from multiple worksheets into a single worksheet based on some condition

    - by SpikETidE
    Hi everyone... Consider i have 4 workbooks with the following structure... 1. Main.xlsx Name Jan Feb Mar A B C 2. Jan.xlsx Name Jan A 3.3 B 6.4 C 5.3 3. Feb.xlsx Name Feb A 1.3 B 3.4 C 5.5 4. Mar.xlsx Name Mar A 1.3 B 3.4 C 5.5 I need to combine them like 1. Main.xlsx Name Jan Feb Mar A 3.3 1.3 1.3 B 6.4 3.4 3.4 C 5.3 5.5 5.5 And i need to automate the process... Can someone enlighten me about the possible options that i have to do this...? Thanks for your time....

    Read the article

  • Excel VBAa: Sum invoice by client id with copying result to new worksheet

    - by Melkior
    Hi, i have strange problem doing reporting: i have numerous clients with different issued invoices. Problem comes to the point when there are invoices in minus and plus: Column A consists of client unique IDs, Column B invoice number, column C invoice amount A | B | C 0010019991 | 1800149471 | 162.00 0010019991 | 1800136388 | 162.00 0010019991 | 1600008004 | -36.00 0010021791 | 1800132148 | 162.00 0010021791 | 1800145436 | 162.00 0010021791 | 1600007737 | -12.00 0014066147 | 1800119068 | 1,684.80 0014066147 | 1800123702 | 1,684.80 0014066147 | 1600007980 | -1,300.80 0014066147 | 1600007719 | -1,286.40 I need to remove rows with negative invoices in a way that amount is summed with invoices which are not with negative amount. So that final result would look like: A | B | C 0010019991 | 1800149471 | 126.00 0010019991 | 1800136388 | 162.00 0010021791 | 1800132148 | 150.00 0010021791 | 1800145436 | 162.00 0014066147 | 1800123702 | 782.40

    Read the article

  • rake test not copying development postgres db with sequences

    - by Robert Crida
    I am trying to develop a rails application on postgresql using a sequence to increment a field instead of a default ruby approach based on validates_uniqueness_of. This has proved challenging for a number of reasons: 1. This is a migration of an existing table, not a new table or column 2. Using parameter :default = "nextval('seq')" didn't work because it tries to set it in parenthesis 3. Eventually got migration working in 2 steps: change_column :work_commencement_orders, :wco_number_suffix, :integer, :null => false#, :options => "set default nextval('wco_number_suffix_seq')" execute %{ ALTER TABLE work_commencement_orders ALTER COLUMN wco_number_suffix SET DEFAULT nextval('wco_number_suffix_seq'); } Now this would appear to have done the correct thing in the development database and the schema looks like: wco_number_suffix | integer | not null default nextval('wco_number_suffix_seq'::regclass) However, the tests are failing with PGError: ERROR: null value in column "wco_number_suffix" violates not-null constraint : INSERT INTO "work_commencement_orders" ("expense_account_id", "created_at", "process_id", "vo2_issued_on", "wco_template", "updated_at", "notes", "process_type", "vo_number", "vo_issued_on", "vo2_number", "wco_type_id", "created_by", "contractor_id", "old_wco_type", "master_wco_number", "deadline", "updated_by", "detail", "elective_id", "authorization_batch_id", "delivery_lat", "delivery_long", "operational", "state", "issued_on", "delivery_detail") VALUES(226, '2010-05-31 07:02:16.764215', 728, NULL, E'Default', '2010-05-31 07:02:16.764215', NULL, E'Procurement::Process', NULL, NULL, NULL, 226, NULL, 276, NULL, E'MWCO-213', '2010-06-14 07:02:16.756952', NULL, E'Name 4597', 220, NULL, NULL, NULL, 'f', E'pending', NULL, E'728 Test Road; Test Town; 1234; Test Land') RETURNING "id" The explanation can be found when you inspect the schema of the test database: wco_number_suffix | integer | not null So what happened to the default? I tried adding task: template: smmt_ops_development to the database.yml file which has the effect of issuing create database smmt_ops_test template = "smmt_ops_development" encoding = 'utf8' I have verified that if I issue this then it does in fact copy the default nextval. So clearly rails is doing something after that to suppress it again. Any suggestions as to how to fix this? Thanks Robert

    Read the article

  • Copying one form's values to another form using JQuery

    - by rsturim
    I have a "shipping" form that I want to offer users the ability to copy their input values over to their "billing" form by simply checking a checkbox. I've coded up a solution that works -- but, I'm sort of new to jQuery and wanted some criticism on how I went about achieving this. Is this well done -- any refactorings you'd recommend? Any advice would be much appreciated! The Script <script type="text/javascript"> $(function() { $("#copy").click(function() { if($(this).is(":checked")){ var $allShippingInputs = $(":input:not(input[type=submit])", "form#shipping"); $allShippingInputs.each(function() { var billingInput = "#" + this.name.replace("ship", "bill"); $(billingInput).val($(this).val()); }) //console.log("checked"); } else { $(':input','#billing') .not(':button, :submit, :reset, :hidden') .val('') .removeAttr('checked') .removeAttr('selected'); //console.log("not checked") } }); }); </script> The Form <div> <form action="" method="get" name="shipping" id="shipping"> <fieldset> <legend>Shipping</legend> <ul> <li> <label for="ship_first_name">First Name:</label> <input type="text" name="ship_first_name" id="ship_first_name" value="John" size="" /> </li> <li> <label for="ship_last_name">Last Name:</label> <input type="text" name="ship_last_name" id="ship_last_name" value="Smith" size="" /> </li> <li> <label for="ship_state">State:</label> <select name="ship_state" id="ship_state"> <option value="RI">Rhode Island</option> <option value="VT" selected="selected">Vermont</option> <option value="CT">Connecticut</option> </select> </li> <li> <label for="ship_zip_code">Zip Code</label> <input type="text" name="ship_zip_code" id="ship_zip_code" value="05401" size="8" /> </li> <li> <input type="submit" name="" /> </li> </ul> </fieldset> </form> </div> <div> <form action="" method="get" name="billing" id="billing"> <fieldset> <legend>Billing</legend> <ul> <li> <input type="checkbox" name="copy" id="copy" /> <label for="copy">Same of my shipping</label> </li> <li> <label for="bill_first_name">First Name:</label> <input type="text" name="bill_first_name" id="bill_first_name" value="" size="" /> </li> <li> <label for="bill_last_name">Last Name:</label> <input type="text" name="bill_last_name" id="bill_last_name" value="" size="" /> </li> <li> <label for="bill_state">State:</label> <select name="bill_state" id="bill_state"> <option>-- Choose State --</option> <option value="RI">Rhode Island</option> <option value="VT">Vermont</option> <option value="CT">Connecticut</option> </select> </li> <li> <label for="bill_zip_code">Zip Code</label> <input type="text" name="bill_zip_code" id="bill_zip_code" value="" size="8" /> </li> <li> <input type="submit" name="" /> </li> </ul> </fieldset> </form> </div>

    Read the article

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