Search Results

Search found 13149 results on 526 pages for 'contains'.

Page 12/526 | < Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >

  • Adding a new column to Table which contains live data

    - by Ardman
    I have a large table consisting of over 60 millions records and I would like to add 2 new columns for data migration purposes. There are indexes on the table and some of them are large. So, by me adding the 2 new columns to the table, will I run the risk of slowing down the database whilst it attempts to add them and maybe time-out? Or will it just work? I know that if I try and rearrange the columns SQL Server will ask me to drop and re-create the table, so I definately don't want this. Is this something everyone is challenged with?

    Read the article

  • Batch file to map a drive when the folder name contains spaces

    - by Santiago
    I am trying to map a drive using a batch file. I have tried: net use m: \Server01\myfolder /USER:mynetwork\Administrator "Mypassword" /persistent:yes It works fine. The problem comes when I try to map a folder with spaces on its name: net use m: \Server01\my folder /USER:mynetwork\Administrator "Mypassword" /persistent:yes I have tried using quotes, using myfold~1 but nothing works. An easy way would be renaming the folder but I have it mapped in more than 300 workstations so is not a very good idea. PLEASE HELP!!!

    Read the article

  • How can I replace a line which contains only -------- by |||

    - by mimou
    I have something like: ------------------------------------------------------------------------ r2 | username | 2011-01-16 16:52:23 +0100 (Sun, 16 Jan 2011) | 1 line Changed paths: D /foo Removed foo ------------------------------------------------------------------------ r1 | username | 2011-01-16 16:51:03 +0100 (Sun, 16 Jan 2011) | 1 line Changed paths: A /foo created foo ------------------------------------------------------------------------ My target is to identify the file added by the "username" in a specific date. Thus, I need to have the combination (username, 16 Jan 2011, A) to insure that it is the right file ands then print foo. My idea is to: delete the white spaces change the newlines into | get rid of the --------------- and replace them with newlines but the problem is that I couldn't replace the ------- since they are mixed with other characters. ------------------------------------------------------------------------ |r2|username|2011-01-1616:52:23+0100(Sun,16Jan2011)|1line|Changedpaths:|D/foo|Removedfoo| ------------------------------------------------------------------------ |r1|username|2011-01-1616:51:03+0100(Sun,16Jan2011)|1line|Changedpaths:|A/foo|createdfoo| ------------------------------------------------------------------------ So I thought it would be a good idea to start by replacing the --------------- by a special character like ||| and then change this character by a newline using awk FS=||| OFS=\n Can anyone help me! thanks

    Read the article

  • Web Url contains Spanish Characters which my NSXMLParser is not parsing

    - by mAc
    I am Parsing Web urls from server and storing them in Strings and then displaying it on Webview. But now when i am parsing Spanish words like http://litofinter.es.milfoil.arvixe.com/litofinter/PDF/Presentación_LITOFINTER_(ES).pdf it is accepting it PDF File Name ++++++ http://litofinter.es.milfoil.arvixe.com/litofinter/PDF/Presentaci PDF File Name ++++++ ón_LITOFINTER_(ES).pdf i.e two different strings... i know i have to make small change that is append the string but i am not able to do it now, can anyone help me out. Here is my code :- - (void)parser:(NSXMLParser *)parser didStartElement:(NSString *)elementName namespaceURI:(NSString *)namespaceURI qualifiedName:(NSString *)qName attributes:(NSDictionary *)attributeDict { currentElement = elementName; if([currentElement isEqualToString:@"category"]) { NSLog(@"Current element in Category:- %@",currentElement); obj = [[Litofinter alloc]init]; obj.productsArray = [[NSMutableArray alloc]init]; } if([currentElement isEqualToString:@"Product"]) { obj.oneObj = [[Products alloc]init]; } } - (void)parser:(NSXMLParser *)parser foundCharacters:(NSString *)string { if([currentElement isEqualToString:@"Logo"]) { obj.cLogo=[NSString stringWithFormat:@"%@",string]; NSLog(@"Logo to be saved in Array :- %@",obj.cLogo); } if([currentElement isEqualToString:@"Name"]) { obj.cName=[NSString stringWithFormat:@"%@",string]; NSLog(@"Name to be saved in Array :- %@",string); } if([currentElement isEqualToString:@"cid"]) { obj.cId=(int)[NSString stringWithFormat:@"%@",string]; NSLog(@"CID to be saved in Array :- %@",string); } if([currentElement isEqualToString:@"pid"]) { //obj.oneObj.id = (int)[NSString stringWithFormat:@"%@",oneBook.id]; obj.oneObj.id = (int)[oneBook.id intValue]; } if([currentElement isEqualToString:@"Title"]) { obj.oneObj.title = [NSString stringWithFormat:@"%@",string]; } if([currentElement isEqualToString:@"Thumbnail"]) { obj.oneObj.thumbnail= [NSString stringWithFormat:@"%@",string]; } // problem occuriing while parsing Spanish characters... if([currentElement isEqualToString:@"pdf"]) { obj.oneObj.pdf = [NSString stringWithFormat:@"%@",string]; NSLog(@"PDF File Name ++++++ %@",string); } } - (void)parser:(NSXMLParser *)parser didEndElement:(NSString *)elementName namespaceURI:(NSString *)namespaceURI qualifiedName:(NSString *)qName { if([elementName isEqualToString:@"category"]) { NSLog(@"Current element in End Element Category:- %@",currentElement); [TableMutableArray addObject:obj]; } if([elementName isEqualToString:@"Product"]) { [obj.productsArray addObject:obj.oneObj]; } currentElement = @""; } I will be thankful to you.

    Read the article

  • Excel - check if row contains ANY value *more than once*

    - by user2536778
    I am doing data analysis and sometimes I need to check and to make sure each row in excel does not have any repeated value. I hope that there is a formula where each time if there's a repeated value in the same row, the value will be highlighted and it doesn't matter what value it is, as long as it's repeated in the same row. I try to search it everywhere but the closest I can find is below question & answer ( which couldn't apply to me as I need a formula that can highlight any value that's repeated and not only zero): I have rows which contain grades for students (numerical values), where the number 0 means they missed a class. I want the row to be highlighted in one color if they have "0" 3 or 4 times, and in another color if they have "0" 5 times or more. =COUNTIF(1:1,0)=5 Anyone can help me? Thanks in advance!

    Read the article

  • Run batch file when argument contains quotes and spaces (from .NET framework)

    - by turtle
    I have a bat file which sets some environment variables, and then executes a command on the command line. I want to replace the hard coded command with one passed in via a parameter. So: :: Set up the required environment SET some_var=a SET another_var=b CALL some.bat :: Now call the command passed into this batch file %1 The problem is that the command is complex, and doesn't escape cleanly. It looks like this: an.exe -p="path with spaces" -t="some text" -f="another path with spaces" I'm trying to call the .bat from a .NET framework app, using: Dim cmd as String = "the cmd" System.Diagnostics.Process.Start( thebat.exe, cmd ) but I can't seem to get the escapes to work correctly. Can someone tell me how the string cmd should be entetered to get the command passed into the bat file as an argument correctly?

    Read the article

  • Formatting a CSV File that contains HTML for Import to Excel

    - by Dave
    I would like to export a CSV file from my application for importing into Excel (or any other spreadsheet that supports CSV files). Anyhow, one of the cells in my table have rich content (i.e. HTML) which can, of course, contain commas as well as other HTML characters and formatting. I realize that Excel "can" handle HTML formatted text, but exporting it as CSV tends to screw up the data for importing. Is there some particular way I can format that particular cell so that imports correctly?

    Read the article

  • Application crashing when talking to oracle unless executable path contains spaces

    - by Lasse V. Karlsen
    We have an x-files problem with our .NET application. Or, rather, hybrid Win32 and .NET application. When it attempts to communicate with Oracle, it just dies. Vanishes. Goes to the big black void in the sky. No event log message, no exception, no nothing. If we simply ask the application to talk to a MS SQL Server instead, which has the effect of replacing the usage of OracleConnection and related classes with SqlConnection and related classes, it works as expected. Today we had a breakthrough. For some reason, a customer had figured out that by placing all the application files in a directory on his desktop, it worked as expected with Oracle as well. Moving the directory down to the root of the drive, or in C:\Temp or, well, around a bit, made the crash reappear. Basically it was 100% reproducable that the application worked if run from directory on desktop, and failed if run from directory in root. Today we figured out that the difference that counted was wether there was a space in the directory name or not. So, these directories would work: C:\Program Files\AppDir\Executable.exe C:\Temp Lemp\AppDir\Executable.exe C:\Documents and Settings\someuser\Desktop\AppDir\Executable.exe whereas these would not: C:\CompanyName\AppDir\Executable.exe C:\Programfiler\AppDir\Executable.exe <-- Program Files in norwegian C:\Temp\AppDir\Executable.exe I'm hoping someone reading this has seen similar behavior and have a "aha, you need to twiddle the frob on the oracle glitz driver configuration" or similar. Anyone? Followup #1: Ok, I've processed the procmon output now, both files from when I hit the button that attempts to open the window that triggers the cascade failure, and I've noticed that they keep track mostly, there's some smallish differences near the top of both files, and they they keep track a long way down. However, when one run fails, the other keeps going and the next few lines of the log output are these: ReadFile C:\oracle\product\10.2.0\db_1\BIN\orageneric10.dll SUCCESS Offset: 274 432, Length: 32 768, I/O Flags: Non-cached, Paging I/O, Synchronous Paging I/O ReadFile C:\oracle\product\10.2.0\db_1\BIN\orageneric10.dll SUCCESS Offset: 233 472, Length: 32 768, I/O Flags: Non-cached, Paging I/O, Synchronous Paging I/O After this, the working run continues to execute, and the other touches the mscorwks.dll files a few times before threads close down and the app closes. Thus, the failed run does not touch the above files. Followup #2: Figured I'd try to upgrade the oracle client drivers, but 10.2.0.1 is apparently the highest version available for Windows 2003 server and XP clients. Followup #3: Well, we've ended up with a black-box solution. Basically we found that the problem is somewhere related to XPO and Oracle. XPO has a system-table it manages, called XPObjectType, with three columns: Oid, TypeName and AssemblyName. Due to how Oracle is configured in the databases we talk to, the column names were OID, TYPENAME and ASSEMBLYNAME. This would ordinarily not be a problem, except that XPO talks to the schema information directly and checks if the table is there with the right column names, and XPO doesn't handle case differences so it sees a XPObjectType table with three unknown columns and none of those it expects. Exactly what XPO does now I don't really know, but if I dropped this table, and recreated it with the right case, using double quotes around all the column names to get the case right, the problem doesn't crop up. Exactly where the space in the folder name comes into this, I still have no idea, but this problem had two tiers: Stop the application from crashing at our customers, short-term solution Fix the bug, long-term solution Right now tier 1 is solved, tier 2 will be put back into the queue for now and prioritized. We're facing some bigger changes to our data tier anyway so this might not be a problem we need to solve, at least if all our Oracle-customers verify that the table-fix actually gets rid of the problem. I'll accept the answer by Dave Markle since though Process Monitor (the big brother of File Monitor) didn't actually pinpoint the problem, I was able to use it to determine that after my breakpoint in user-code where XPO had built up the query for this table, no I/O happened until all the entries for the application closing down was logged, which led me to believe it was this table that was the culprit, or at least influenced the problem somehow. If I manage to get to the real cause of this, I'll update the post.

    Read the article

  • C#: Label contains no text

    - by Vinzcent
    Hey I would like to get the text out of a label. But the label text is set with Javascript. On the page I can see that there is text in the label, but when I debug it shows this: "". So how do I get the text out of a label that is set with Javascript, at least that is what I think is the problem. My code: <asp:TextBox ID="txtCount" runat="server" Width="50px" Font-Names="Georgia, Arial, sans-Serif" ForeColor="#444444"></asp:TextBox> <ajaxToolkit:NumericUpDownExtender ID="NumericUpDownExtender1" runat="server" Minimum="1" TargetButtonDownID="btnDown" TargetButtonUpID="btnUp" TargetControlID="txtCount" Width="20" /> <asp:ImageButton ID="btnUp" runat="server" AlternateText="up" ImageUrl="Images/arrowUp.png" OnClientClick="setAmountUp()" ImageAlign="Top" CausesValidation="False" /> <asp:ImageButton ID="btnDown" runat="server" AlternateText="down" ImageUrl="Images/arrowDown.png" OnClientClick="setAmountDown()" ImageAlign="Bottom" CausesValidation="False" /> <asp:Label ID="lblKorting" runat="server" /> <asp:Label ID="lblAmount" runat="server" /> <asp:Button ID="btnBestel" runat="server" CssClass="btn" Text="Bestel" OnClick="btnBestel_Click1" /> JS function setAmountUp() { var aantal = document.getElementById('<%=txtCount.ClientID%>').value-0; aantal+=1; calculateAmount(aantal); } function setAmountDown() { var aantal = document.getElementById('<%=txtCount.ClientID%>').value-0; if(aantal > 1) aantal -=1; calculateAmount(aantal); } function calculateAmount(aantal) { var prijs = document.getElementById('<%=lblPriceBestel.ClientID%>').innerHTML -0; var totaal = 0; if(aantal < 2) { totaal = prijs * aantal; document.getElementById('<%=lblKorting.ClientID%>').innerHTML = ""; } else if(aantal >= 2 && aantal < 5) { totaal = (prijs * aantal)*0.95; document.getElementById('<%=lblKorting.ClientID%>').innerHTML = "-5%"; } else if(aantal >= 5) { totaal = (prijs * aantal)*0.90; document.getElementById('<%=lblKorting.ClientID%>').innerHTML = "-10%"; } document.getElementById('<%=lblAmount.ClientID%>').innerHTML = totaal; } C# private OrderBO bestelling; protected void btnBestel_Click1(object sender, EventArgs e) { bestelling = new OrderBO(); bestelling.Amount = Convert.ToInt32(lblAmount.Text); //<--- THIS IS "" in the debugger, but on the page 10 }

    Read the article

  • SQLAlchemy Custom Type Which Contains Multiple Columns

    - by Kekoa
    I would like to represent a datatype as a single column in my model, but really the data will be stored in multiple columns in the database. I cannot find any good resources on how to do this in SQLAlchemy. I would like my model to look like this(this is a simplified example using geometry instead of my real problem which is harder to explain): class 3DLine(DeclarativeBase): start_point = Column(my.custom.3DPoint) end_point = Column(my.custom.3DPoint) This way I could assign an object with the (x, y, z) components of the point at once without setting them individually. If I had to separate each component, this could get ugly, especially if each class has several of these composite objects. I would combine the values into one encoded field except that I need to query each value separately at times. I was able to find out how to make custom types using a single column in the documentation. But there's no indication that I can map a single type to multiple columns. I suppose I could accomplish this by using a separate table, and each column would be a foreign key, but in my case I don't think it makes sense to have a one to one mapping for each point to a separate table, and this still does not give the ability to set the related values all at once.

    Read the article

  • javascript split() array contains

    - by Mahesha999
    While learning JavaScript, I did not get why the output when we print the array returned of the Sting.split() method (with regular expression as an argument) is as explained below. var colorString = "red,blue,green,yellow"; var colors = colorString.split(/[^\,]+/); document.write(colors); //this print 7 times comma: ,,,,,,, However when I print individual element of the array colors, it prints an empty string, three commas and an empty string: document.write(colors[0]); //empty string document.write(colors[1]); //, document.write(colors[2]); //, document.write(colors[3]); //, document.write(colors[4]); //empty string document.write(colors[5]); //undefined document.write(colors[6]); //undefined Then, why printing the array directly gives seven commas. Though I think its correct to have three commas in the second output, I did not get why there is a starting (at index 0) and ending empty string (at index 4). Please explain I am screwed up here.

    Read the article

  • How i can create reusable component which contains assets in Flash CS5

    - by Creotiv
    I need to create slideshow for gallery. And one thing that i don't know is how to create reusable components. For example i want to create 3 components ImageLoader, Dock(that consist drom ImageLoaders) and SlideShow(that consists from Dock and ImageLoaders). ImageLoader it is a container which loads image and while it loading showing some animation. Dock it is a container wich have few of ImageLoaders, it used to create Dock of thumbs images to chose. SlideShow it is a container wich have few of ImageLoaders, it used to preload images to ImageLoaders and the change them on mouse click. I need that all of this components was accessible fom action script, so i can create new instances of them. Example code: im1 = new ImageLoader('../im1s.jpg'); im2 = new ImageLoader('../im2s.jpg'); dock = new Dock(new Array(im1,im2)); ss = new SlideSHow(new Array(im1,im2),dock); ss.init(); Will be greatfull for help. P.S. I new in Flash

    Read the article

  • JQuery: Selector that contains some text, but doesn't contain others

    - by BPotocki
    Sorry if this question is mind numbingly easy to answer, but I'm a bit new to JQuery and I have a tight deadline. I am looking for a selector for textbox elements that have this format: id = "FixedName_#" "FixedName" will always be "FixedName", but I only want to find elements where the # is positive. So I would want to find "FixedName_1", and "FixedName_2" for example, but skip over "FixedName_-1" and "FixedName_-2". Thanks!

    Read the article

  • Get the Value of Array that contains A String in Objective-C

    - by jaytrixz
    How can I get the value of an array that has one value which is a string in Objective-C? I'm actually getting confused on how to properly get the string value inside the array I'm accessing. I'm getting the value of an array named "sMessage" that has one value of type NSString "success". This is the response from the API: ({"sMessage":"success"}) I'm trying to get the value by using this code and logs it to the console: NSArray *resultsArray = [json objectForKey:@"sMessage"]; NSString *loginResult = [[resultsArray valueForKey:@"sMessage"] lastObject]; NSLog(@"Result is: %@", loginResult);

    Read the article

  • jQuery .load from another page that contains Javascript

    - by Dave
    I've been using jQuery .load() to load content into a div. The content being .loaded occasionally has a document.ready() function which is called, and works, correctly (i.e. the ready() function is called). However, when I use an element ID in the .load(), such as: .load ("test.php #content"), the Javascript is no longer executed even if I put the script tag inside of the element that is being loaded. Does anyone have a solution to this other than to not use the element ID in the .load()? Thanks in advance. Here is the dynamic content (loadDialogTest.php): <div id="test"> <div> Hello, World! </div> <script type="text/javascript"> $(document).ready (function () { alert ("ready"); }); </script> </div> and here is the page (where the element ID is NOT specified) that loads it (shortened as much as possible while maintaining the form: <head> <script type="text/javascript"> $(document).ready (function () { $("#openDialog").click (function () { $("<div></div>") .load ("loadDialogTest.php") .appendTo ($("#containingDiv")) .dialog ({ autoOpen: 'false', title: 'Test This!', close: function () { $(this).dialog ('destroy').remove (); } }); }); }); </script> </head> <body> <a href="#" id="openDialog">Open it</a> <div id="containingDiv"> </div> </body> If I put #test after the .php file as the div to load, the jQuery ready() function is no longer called.

    Read the article

  • Compiling scalafx for Java 7u7 (that contains JavaFX 2.2) on OS X

    - by akauppi
    The compilation instructions of scalafx says to do: export JAVAFX_HOME=/Path/To/javafx-sdk2.1.0-beta sbt clean compile package make-pom package-src However, with the new packaging of JavaFX as part of the Java JDK itself (i.e. 7u7 for OS X) there no longer seems to be such a 'javafx-sdkx.x.x' folder. The Oracle docs say that JavaFX JDK is placed alongside the main Java JDK (in same folders). So I do: $ export JAVAFX_HOME=/Library/Java/JavaVirtualMachines/jdk1.7.0_07.jdk $ sbt clean [warn] Using project/plugins/ (/Users/asko/Sources/scalafx/project/plugins) for plugin configuration is deprecated. [warn] Put .sbt plugin definitions directly in project/, [warn] .scala plugin definitions in project/project/, [warn] and remove the project/plugins/ directory. [info] Loading project definition from /Users/asko/Sources/scalafx/project/plugins/project [info] Loading project definition from /Users/asko/Sources/scalafx/project/plugins [error] java.lang.NullPointerException [error] Use 'last' for the full log. Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore? Am I doing something wrong or is scalafx not yet compatible with the latest Java release (7u7, JavaFX 2.2). What can I do? http://code.google.com/p/scalafx/ Addendum ..and finally (following Igor's solution below) sbt run launches the colorful circles demo easily (well, if one has a supported GPU that is). Oracle claims that "JavaFX supports graphic hardware acceleration on any Mac OS X system that is Lion or later" but I am inclined to think the NVidia powered Mac Mini I'm using does software rendering. A recent MacBook Air (core i7) is a complete different beast! :)

    Read the article

  • Field contains foreign IDs for different tables

    - by Rich
    I am developing a php/mysql driven facebook game. I am stuck on an element the table design. When a user completes a task I want to trigger any number of events. I was thinking of something like so: tbl_events *event_id - serogate primary ID *task_id - foreign ID of the task just completed *event_type - what type of event e.g is it a facebook stream publish or a message to the user or does it unlock a new element of the game? *event_param - this is where it gets tricky... the event parameter is a problem for two reasons, 1) it will contain different foreign ids... dependent on the event_type and thus it will not be possible to join to x table. Meaning I would have to call two queries. 2) Most events require a single id or text, however some events require multiple parameters - like the facebook stream publish.

    Read the article

  • Check if NSMutableArray contains text from textfield

    - by Polo Swelsen
    I want to check if the text inserted in a textfield is also in my NSMutableArray. So let's say my NSMutableArray has these objects: "Hey, Hello, No, Yes". Then when a user enters the text: "Hello" i want there to appear a UIAlertView. I now have the following: for (int slt = 0; slt < [zouten count]; slt++) { if (zout.text = [zouten objectAtIndex:slt]) { alert = [[UIAlertView alloc]initWithTitle:@"Goedzo!" message:[NSString stringWithFormat:@"Je hebt een zout gevonden"] delegate:self cancelButtonTitle:@"OK" otherButtonTitles:nil]; } } [alert show]; But somehow the message appears with every word. what am i doing wrong?

    Read the article

  • OpToSoapDomComv.TRefCache.FNodes contains references to non-existing XMLNodes

    - by Bascy
    In our D2007 application we are using a Webservice, accessed with a THTTPRIO object. When the TDatamodule containing the THTTPRIO object is Destroyed an access violation occurs. This AV is raised when the TSoapDOMConvert is freed, which in turn executes: TRefCache(RefMap[0].Instance).Free calling destructor TRefCache.Destroy; begin FHREFs.Free; FMHREFs.Free; FNodes := nil; //Causes AV end; FNodes is a TInterfaceList containing one reference to IXMLNodes, but the object seems to have been freed before all this. Does anyone know this problem? How to solve it?

    Read the article

  • c# warn if text box is empty or contains a non-whole number

    - by Jamaul Smith
    In my specific case, I need the value in propertyPriceTextBox to be numeric only, and a whole number. A value also has to be entered, and I can just Messagebox.Show() a warning and that's all I'd need to do. This is what I have so far. private void computeButton_Click(object sender, EventArgs e) { decimal propertyPrice; if ((decimal.TryParse(propertyPriceTextBox.Text, out propertyPrice))) decimal.Parse(propertyPriceTextBox.Text); { if (residentialRadioButton.Checked == true) commisionLabel.Text = (residentialCom * propertyPrice).ToString("c"); if (commercialRadioButton.Checked == true) commisionLabel.Text = (commercialCom * propertyPrice).ToString("c"); if (hillsRadioButton.Checked == true) countySalesTaxTextBox.Text = ( hilssTax * propertyPrice).ToString("c"); if (pascoRadioButton.Checked == true) countySalesTaxTextBox.Text = (pascoTax * propertyPrice).ToString("c"); if (polkRadioButton.Checked == true) countySalesTaxTextBox.Text = (polkTax * propertyPrice).ToString("c"); decimal result; result = (countySalesTaxTextBox.Text + stateSalesTaxTextBox.Text + propertyPriceTextBox.Text + comissionTextBox.Text).ToString("c"); } else (.) MessageBox.Show("Property Price must be a whole number."); }

    Read the article

  • Calling a Function Based on a String Which Contains the Function Name

    - by Phonethics
    var foo1,foo2; switch (fn) { case "fade" : foo1 = "fadeOut"; foo2 = "fadeIn"; break; case "slide" : foo1 = "slideUp"; foo2 = "slideDown"; break; } eval("$('.cls1')." + foo1 + "();"); currentSlideIndex = currentSlideIndex + n; eval("$('.cls1')." + foo2 + "();"); Any better way to achieve this without using eval ? Im not a very big fan of using eval unless absolutely necessary.

    Read the article

  • Determining whether one array contains the contents of another array in ruby

    - by Andrew Grimm
    In ruby, how do I test that one array not only has the elements of another array, but contain them in that particular order? correct_combination = [1, 2, 3, 4, 5] [1, 5, 8, 2, 3, 4, 5].function_name(correct_combination) # => false [8, 10, 1, 2, 3, 4, 5, 9].function_name(correct_combination) # => true I tried using include, but that is used to test whether [1,2,3].include?(2) is true or not.

    Read the article

  • Perl ENV variable contains newline and tab

    - by Michael
    Say I have an environment variable myvar myvar=\tapple\n when the following command will print out this variable perl -e 'print "$ENV{myvar}"' I will literally have \tapple\n, however, I want those control chars to be evaluated and not escaped. How would I achieve it? In the real world $ENV residing in substitution, but I hope the answer will cover that.

    Read the article

  • deleting dynamically allocated object that contains vector in C++ STL

    - by kobac
    I have a class class ChartLine{ protected: vector<Point> line; // points connecting the line CString name; //line name for legend CPen pen; //color, size and style properties of the line }; where Point is a structure struct Point{ CString x; double y; }; In main() I dynamically allocate objects of type ChartLine with new operator. If I use delete afterwards, will default destructor ~ChartLine() properly dealocate (or clear) member ChartLine::line(which is vector btw) or I would have to clear that vector in ~ChartLine() manually? Thanks in advance. Cheers.

    Read the article

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