Search Results

Search found 3361 results on 135 pages for 'david chen'.

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

  • C# File.ReadAllLines not breaking on line feeds

    - by David Dickerson
    Hello, I have an application that I am building that needs to modify a configuration file. My problem is that I am not able to read the file in line by line. I keep geeting the the entire file as a single string. string ConfigTemplate = AEBuildsSPFolderName + "\Template_BuildReleaseScript.Config"; string[] fileSourceLines = File.ReadAllLines(ConfigTemplate, Encoding.Default); --Returns the entire file contents into the first array element. using (StreamReader reader = new StreamReader(ConfigTemplate)) { string line; while ((line = reader.ReadLine()) != null) --Returns the entire file contents into the first line read. Any idea of what I am doing wrong? Thanks, david

    Read the article

  • How to measure the time HTTP requests spend sitting in the accept-queue?

    - by David Jones
    I am using Apache2 on Ubuntu 9.10, and I am trying to tune my configuration for a web application to reduce latency of responses to HTTP requests. During a moderately heavy load on my small server, there are 24 apache2 processes handling requests. Additional requests get queued. Using "netstat", I see 24 connections are ESTABLISHED and 125 connections are TIME_WAIT. I am trying to figure out if that is considered a reasonable backlog. Most requests get serviced in a fraction of a second, so I am assuming requests move through the accept-queue fairly quickly, probably within 1 or 2 seconds, but I would like to be more certain. Can anyone recommend an easy way to measure the time an HTTP request sits in the accept-queue? The suggestions I have come across so far seem to start the clock after the apache2 worker accepts the connection. I'm trying to quantify the accept-queue delay before that. thanks in advance, David Jones

    Read the article

  • JavaScript - How to change a dom node back to an existing Google Map?

    - by David Robertson
    I set a div to a class which shows a spinning animated when the map is loading some data, the question is, how can I set the div back to the map (I don't want to load a new map, but load the existing one, which is assigned to a var 'map')? //map is assigned originally like this: map = new google.maps.Map(document.getElementById('map3'),options); //animated graphic is assigned to map div on load of data: document.getElementById('map3').className = "loading"; but how to get the map back? Thanks for any tips! David

    Read the article

  • help with inline images/mail with cron - php?

    - by David Verhulst
    I've got mailings that need to be sended using cron. When I load the script manualy all works fine. With cron i get broken images. to change the src of my img i used: $body = eregi_replace("managersrc_logo","images/managers/acertainlogo.jpg",$body); Because i thaught that it is importent to use absolute paths i also tried: $body = eregi_replace("managersrc_logo","http://www.site.com/images/managers/acertainlogo.jpg",$body); In that case i even do not see the images when i run the cronscript manualy. Nor the automated cron will display me the images. When i check the source of the mail that is received i always see "cid:encryptedstuff" even if i use absolute paths? Why is that? I just want my absolute paths being printed in the src attribute of the img tag. Who changes my absolute path to cid: ? is it php, phpmailer or outlook itself? Any help someone?.... David

    Read the article

  • MySQL LOAD DATA LOCAL INFILE example in python?

    - by David Perron
    I am looking for a syntax definition, example, sample code, wiki, etc. for executing a LOAD DATA LOCAL INFILE command from python. I believe I can use mysqlimport as well if that is available, so any feedback (and code snippet) on which is the better route, is welcome. A Google search is not turning up much in the way of current info The goal in either case is the same: Automate loading hundreds of files with a known naming convention & date structure, into a single MySQL table. David

    Read the article

  • IntelliSense has forgotten my code snippets!

    - by David
    Hi all I have a stack of code snippets imported into Visual Studio. Just recently, they have stopped displaying in Intellisense. If the keyboard shortcut doesn't bring up anything else on IntelliSense, then I can tab and the code snippet is inserted just fine. However, if the keyboard shortcut for the snippet happens to also bring up other items in IntelliSense, tabbing will select the first of those items, so I actually can't use the code snippet at all! Does anyone have any ideas why IntelliSense would be unable to list my code snippet shortcuts? I started using ReSharper recently, but that wouldn't be the problem surely?! Thanks for your help David

    Read the article

  • Select dynamic string has a different value when referenced in Where clause

    - by David
    I dynamically select a string built using another string. So, if string1='David Banner', then MyDynamicString should be 'DBanne' Select ... , Left( left((select top 1 strval from dbo.SPLIT(string1,' ')) //first word ,1) //first character + (select top 1 strval from dbo.SPLIT(string1,' ') //second word where strval not in (select top 1 strval from dbo.SPLIT(string1,' '))) ,6) //1st character of 1st word, followed by up to 5 characters of second word [MyDynamicString] ,... From table1 Join table2 on table1pkey=table2fkey Where MyDynamicString <> table2.someotherfield I know table2.someotherfield is not equal to the dynamic string. However, when I replace MyDynamicString in the Where clause with the full left(left(etc.. function, it works as expected. Can I not reference this string later in the query? Do I have to build it using the left(left(etc.. function each time in the where clause?

    Read the article

  • T-SQL - how to get around the order by restriction in CTEs

    - by David
    Hi all I have the following CTE. Its purpose is to provide unique Month/Year pairs. Later code will use the CTE to produce a concatenated string list of the Month/Year pairs. ;WITH tblStoredWillsInPeriod AS ( SELECT DISTINCT Kctc.GetMonthAndYearString(DateWillReceived) Month FROM Kctc.StoredWills WHERE DateWillReceived BETWEEN '2010/01/01' AND '2010/03/31' ORDER BY DateWillReceived ) I have omitted the implmementation of the GetMonthAndYearString function as it is trivial. Sadly, it seems T-SQL is always one step ahead. When I run this code, it tells me I'm not allowed to use ORDER BY in a CTE unless I also use TOP (or FOR XML, whatever that is.) If I use TOP, it tells me I can't use it with DISTINCT. Yup, T-SQL has all the answers. Can anyone think of a solution to this problem which is quicker than simply slashing my wrists? I understand that death from blood loss can be surprisingly lingering, and I have deadlines to meet. Thanks for your help. David

    Read the article

  • "The breakpoint will not currently be hit. The source code is different from the original version."

    - by David
    Hi everyone I'm really hoping someone can help me out with this one. When debugging in Visual Studio, sometimes I add a breakpoint but it's hollow and VS says "The breakpoint will not currently be hit. The source code is different from the original version." Obviously this prevents me being able to debug. What on earth does the message mean? What original version? If I've just opened up the solution and not made any changes whatsoever to the code, how can there be an 'original version'? The appearance of this problem just seems totally arbitrary. It's just Visual Studio going 'Na na na na na, I'm not going to debug for you today'. Can anyone give any advice? Ta David

    Read the article

  • Multiple NSURLDownloads with Progress

    - by David Schiefer
    Hello, I'm trying to build a small app which allows downloading of multiple files at the same time while displaying them in a custom NSTableView. This works, i've done this by using an NSEnumerator, but I struggle at getting the progress right. It's calculated correctly, but it's not done individually for every download, instead they're added up. The way I've tried to set the subtitles containing the progress is by loading them into a separate array and then inserting/replacing objects containing the progress, but here I run into another problem - I don't know how to get the index of the object that's being downloaded, so I can't differentiate between the progresses. I hope you understand what I mean :P I've uploaded the source code to my server, I'd be really grateful if someone could have a look and help me out: http://web.me.com/david.schiefer/MyController.m

    Read the article

  • C#: Put member variables into a list.

    - by David
    Hi all Assuming I have a method which accepts an IList or similar thing as a parameter: public void JiggleMyList(IList<string> list)... Is there an easy way that I can pass in string members of a list of objects? I mean, if for example, I have a list of Person objects which expose a string property called FullName, is there a quick way to stuff the FullNames of all the Person objects into the method parameter, or do I have to create a new List and iterate through the Person objects: List<string> fullNames = new List<string>; foreach (Person person in people) { fullNames.Add(person.FullName); } JiggleMyList(fullNames); I come across this all the time, and it would be nice if there was a shortcut. Many thanks David

    Read the article

  • Showing the ProgressDialog while opening the Website

    - by david
    I have to open a website say Facebook page, twitter page and You Tube page in order to share my post there. Now when I click to the item Facebook , it gets redirected to FB to share and same for Twitter and YouTube. I have to show them in my WebView and all this is done perfectly. What I want is to show the Progress Dialog after clicking on the Item till it gets redirected to the FB , Twitter or YouTube. I don know how to show the Progress Bar for redirecting to the Main Website. Can anyone Please help me put Here. Thanks, David Brown

    Read the article

  • Full Width Divs using ScrollTo.js

    - by David Haigh
    This is my first ever post. I am using the ScrollTo jQuery plugin and i have stumbled across a problem... I have 6 rows, each with 6 child divs , I would like each of these child divs to be full width. The plugin works great but I cannot seem to get the child div to be full width (then use ScrollTo to 'slide' to the next div, or to a div on the next row. ) Here is my code: http://jsfiddle.net/RZjrV/ Is it even possible? I have set body - Overflow:hidden to avoid any initial confusion. Thank you all who read this post and even take a minute to think about it. David

    Read the article

  • GET syntax in xpath

    - by David Doria
    I am trying to use a parameter that I pass to the page in an xpath query. This works properly (hard coded): <?php $xml = simplexml_load_file("bookstore.xml"); $res = $xml->xpath("/bookstore/book[title = 'Everyday Italian']"); echo $res[0]->author ?> but I pass the parameter with: bookdetails.php?title="Everyday Italian" and then do: <?php $xml = simplexml_load_file("bookstore.xml"); $res = $xml->xpath("/bookstore/book[title = $_GET['title']]"); echo $res[0]->author ?> I get a 500 error. Any thoughts? Thanks, David

    Read the article

  • Pushing a variable onto a vector, value at that point in vector changes when the variable does.

    - by David Andrews
    I have a programming problem =) std::vector<char*> Names; if(MyPacket.ID == 3) {Names.push_back(MyPacket.Buffer);} I push the recieved buffer onto a vector like so, but when the buffer changes so does the value of the variable at that point in the vector. So say I sent and pushed a buffer containing 'Simon' onto the vector that would be fine so at point [0] on the vector would be the word Simon. but then when I recieve a new buffer it overwrites position [0] even though the packets ID is different, a breakpoint within the if statement is not reached with this new buffer. I really hope i'm explaining this well enough, I tried asking a friends advice and he pointed me towards this site. Any help appreciated David Andrews

    Read the article

  • C#: Hook up all events from object in single statement.

    - by David
    In my domain layer all domain objects emit events (of type InvalidDomainObjectEventHandler) to indicate invalid state when the IsValid property is called. On an aspx codebehind, I have to manually wire up the events for the domain object like this: _purchaseOrder.AmountIsNull += new DomainObject.InvalidDomainObjectEventHandler(HandleDomainObjectEvent); _purchaseOrder.NoReason += new DomainObject.InvalidDomainObjectEventHandler(HandleDomainObjectEvent); _purchaseOrder.NoSupplier += new DomainObject.InvalidDomainObjectEventHandler(HandleDomainObjectEvent); _purchaseOrder.BothNewAndExistingSupplier += new DomainObject.InvalidDomainObjectEventHandler(HandleDomainObjectEvent); Note that the same method is called in each case since the InvalidDomainobjectEventArgs class contains the message to display. Is there any way I can write a single statement to wire up all events of type InvalidDomainObjectEventHandler in one go? Thanks David

    Read the article

  • python lxml problem

    - by David ???
    I'm trying to print/save a certain element's HTML from a web-page. I've retrieved the requested element's XPath from firebug. All I wish is to save this element to a file. I don't seem to succeed in doing so. (tried the XPath with and without a /text() at the end) I would appreciate any help, or past experience. 10x, David import urllib2,StringIO from lxml import etree url='http://www.tutiempo.net/en/Climate/Londres_Heathrow_Airport/12-2009/37720.htm' seite = urllib2.urlopen(url) html = seite.read() seite.close() parser = etree.HTMLParser() tree = etree.parse(StringIO.StringIO(html), parser) xpath = "/html/body/table/tbody/tr/td[2]/div/table/tbody/tr[6]/td/table/tbody/tr/td[3]/table/tbody/tr[3]/td/table/tbody/tr/td/table/tbody/tr/td/table/tbody/text()" elem = tree.xpath(xpath) print elem[0].strip().encode("utf-8")

    Read the article

  • Summing the results of Case queries in SQL

    - by David Stelfox
    I think this is a relatively straightforward question but I have spent the afternoon looking for an answer and cannot yet find it. So... I have a view with a country column and a number column. I want to make any number less than 10 'other' and then sum the 'other's into one value. For example, AR 10 AT 7 AU 11 BB 2 BE 23 BY 1 CL 2 I used CASE as follows: select country = case when number < 10 then 'Other' else country end, number from ... This replaces the countries values with less than 10 in the number column to other but I can't work out how to sum them. I want to end up with a table/view which looks like this: AR 10 AU 11 BE 23 Other 12 Any help is greatly appreciated. Cheers, David

    Read the article

  • Silverlight Cream for November 26, 2011 -- #1175

    - by Dave Campbell
    In this Issue: Michael Washington, Manas Patnaik, Jeff Blankenburg, Doug Mair, Jon Galloway, Richard Bartholomew, Peter Bromberg, Joel Reyes, Zeben Chen, Navneet Gupta, and Cathy Sullivan. Above the Fold: Silverlight: "Using ASP.NET PageMethods With Silverlight" Peter Bromberg WP7: "Leveraging Background Services and Agents in Windows Phone 7 (Mango)" Jon Galloway Metro/WinRT/Windows8: "Debugging Contracts using Windows Simulator" Cathy Sullivan LightSwitch: "LightSwitch: It Is About The Money (It Is Always About The Money)" Michael Washington Shoutouts: Michael Palermo's latest Desert Mountain Developers is up Michael Washington's latest Visual Studio #LightSwitch Daily is up From SilverlightCream.com:LightSwitch: It Is About The Money (It Is Always About The Money)Michael Washington has a very nice post up about LightSwitch apps in general and his opinion about the future use... based on what he and I have been up to, I tend to agree on all counts!Accessing Controls from DataGrid ColumnHeader – SilverlightManas Patnaik's latest post is about using the VisualTreeHelper class to iterate through the visual tree to find the controls you need ... including sample code31 Days of Mango | Day #18: Using Sample DataJeff Blankenburg's Day 18 in his 31-Day Mango quest is on Sample Data using Expression Blend, and he begins with great links to his other Blend posts followed by a nice sample data tutorial and source31 Days of Mango | Day #19: Tilt EffectsDoug Mair returns to the reigns of Jeff's 31-Days series with number 19 which is all about Tilt Effects ... as seen in the Phone application when you select a user... Doug shows how to add this effect to your appLeveraging Background Services and Agents in Windows Phone 7 (Mango)Jon Galloway has a WP7 post up discussing Background Services and how they all fit together... he's got a great diagram of that as an overview then really nice discussion of each followed up by his slides from DevConnections, and codeNetflix on Windows 8This one isn't C#/XAML, but Richard Bartholomew has a Netflix on Windows 8 app running that bears noticeUsing ASP.NET PageMethods With SilverlightPeter Bromberg has a post up demonstrating calling PageMethods from a Silverlight app using the ScriptManager controlAWESOME Windows Phone Power ToolJoel Reyes announced the release of a full-featured tool for side-loading apps to your WP7 device... available at codeplexMicrosoft Windows Simulator Rotation and Resolution EmulationZeben Chen discusses the Windows 8 Simulator a bit deeper with this code-laden post showing how to look at roation and orientation-aware apps and resolution.First look at Windows SimulatorNavneet Gupta has a great into post to using the simulator in VS2011 for Windows 8 apps. Four things you really need this for: Touch Emulation, Rotation, Different target resolutions, and ContractsDebugging Contracts using Windows SimulatorCathy Sullivan shows how to debug W8 Contracts in VS2011... why you ask? because when you hit one in the debugger, the target app disappears.. but enter the simulator... check it outStay in the 'Light!Twitter SilverlightNews | Twitter WynApse | WynApse.com | Tagged Posts | SilverlightCreamJoin me @ SilverlightCream | Phoenix Silverlight User GroupTechnorati Tags:Silverlight    Silverlight 3    Silverlight 4    Windows PhoneMIX10

    Read the article

  • Google I/O 2012 - Advancing Accessibility for the Web

    Google I/O 2012 - Advancing Accessibility for the Web Rachel Shearer, Dominic Mazzoni, Charles Chen This session will help you learn through code samples and real world examples how to design and test your web apps for complete accessibility coverage. We will review APIs such as the Text-to-speech (TTS) API, tools like ChromeVox and ChromeShades and how Google products implement solutions today for users with disabilities. For all I/O 2012 sessions, go to developers.google.com From: GoogleDevelopers Views: 61 3 ratings Time: 55:25 More in Science & Technology

    Read the article

  • Meet the WebCenter Product Marketing Team!

    - by Kellsey Ruppel
    As we wrap up this week recapping all the great things that happened at Oracle OpenWorld, we thought we'd share with our community the faces behind this blog and the Oracle WebCenter Product Marketing team! With the majority of the team working remotely, OpenWorld is the one time we are all together for an entire week. L to R: Lance Shaw (WebCenter Content), Christie Flanagan (WebCenter Sites), Peggy Chen (leads WebCenter product marketing), Kellsey Ruppel (WebCenter Portal & Oracle Social Network), & Michael Snow (WebCenter Suite).

    Read the article

  • Raiders of the Lost iPhone

    <b>MacNewsWorld:</b> "Will Gizmodo's Jason Chen land in the cooler for his part in leaking Apple's next-gen iPhone to the world? Or did Silicon Valley's High Tech Task Force violate legal protections established to shield journalists when they raided the editor's home?"

    Read the article

  • How to Evict a Failed Node and Add it Back to SQL Server 2005 Cluster

    Adding and removing nodes in SQL Server Clusters is not so difficult, and instructions on how to do so abound on the internet. However, mismanagement when adding/removing nodes can quickly become a 'gotcha' that wastes time. Bo Chen offers insight into some of those scenarios that are not normally covered in the standard online documents.

    Read the article

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