Daily Archives

Articles indexed Tuesday May 4 2010

Page 14/117 | < Previous Page | 10 11 12 13 14 15 16 17 18 19 20 21  | Next Page >

  • C/C++ include file order/best practices

    - by aaa
    Hello. Is there recommended order in which include files should be specified? For example, the system files, STL, Boost, go before of after local include files? is there a particular reason to choose one or another? Thanks

    Read the article

  • Yank file name / path of current buffer in Vim

    - by Dave Tapley
    Assuming the current buffer is a file open for edit, so :e does not display E32: No file name. I would like to yank one or all of: The file name exactly as show on the status line, e.g. ~\myfile.txt A full path to the file, e.g. c:\foo\bar\myfile.txt Just the file name, e.g. myfile.txt

    Read the article

  • Controlling new features in Spring/Apache tomcat

    - by HeretoLearn
    Is there a good way to manage roll out of new software in Spring/Tomcat configuration. The problem I am trying to address is being able to rollback newly deployed software provided there are no hard dependencies on other moving pieces. For example changed the guts of an algorithm and now want to deploy the new software with the new change off by default and then turning it on on one of the web servers. An obvious way is to build a session object which has a map of key-value pairs(property,bool) which is populated from a db on a session startup and then the value is persisted for that session. This is so that if the value is reverted back existing sessions which started with the original value retain the original value and giving application consistency. Is there a more obvious inbuilt mechanism to do this?

    Read the article

  • split a database web application - good idea or bad idea?

    - by Khou
    Is it a bad idea to split up a application and the database? Application1 uses database1 on ServerX Application2 uses database2 on ServerY Both application communicates over web service API, they are apart of the same application, one application is used to manage user's profile/personal data, while the other application is used to manages user's financial data. Or should just put them together and just use 1 database on the same server?

    Read the article

  • When I use facebook connect how much access do I have to the user's friends?

    - by user220755
    So, if you sign in using facebook on my website, how much access do I have to your friends? I am asking this question because I want for example to know if a user asks me a question about his/her friend, I can go through their Facebook status messages for example and tell them the answer depending on parsing information but do I have access to the user's friends information or no? (And how can I do that if it is possible in another way)

    Read the article

  • gzip several files and pipe them into one input

    - by Daniel
    I have this program that takes one argument for the source file and then it parse it. I have several files gzipped that I would like to parse, but since it only takes one input, I'm wondering if there is a way to create one huge file using gzip and then pipe it into the only one input.

    Read the article

  • ImportError: No module named optparse in jython

    - by jeet
    getting Traceback (most recent call last): File "C:\projects\myproject\convert.py", line 139, in import optparse ImportError: No module named optparse. when executing it using jython. Same module works fine when i execute it through python. I am usinng window7 operating system. The same modle works fine on windows XP machine with both python and Jython.

    Read the article

  • Storage sizing for virtual machines

    - by njo
    I am currently doing research to determine the consolidation ratio my company could expect should we start using a virtualization platform. I find myself continually running into a dead end when researching how to translate observed performance (weeks of perfmon data) to hdd array requirements for a virtualization server. I am familiar with the concept of IOPs, but they seem to be an overly simplistic measurement that fails to take into account cache, write combining, etc. Is there a seminal work on storage array performance analysis that I'm missing? This seems like an area where hearsay and 'black magic' have taken over for cold, hard fact.

    Read the article

  • Windows 7 - Stuck at splash screen on cold boot only

    - by Suhan
    Hey guys, Wondering if anyone has any ideas on what's causing my pc to lockup at the splash screen on bootup for 1-3minutes. This ONLY happens on the first power up, subsequent reboots run fine. Running on a Falcon II SSD I did the customary move of files to another drive when i first formatted the ssd. The slow first boot only started happening recently. Thanks in advance!

    Read the article

  • How to assign the array key a value, when the key name is itself a variable

    - by Matrym
    How do I identify an item in a hash array if the key of the array is only known within a variable? For example: var key = "myKey"; var array = {myKey: 1, anotherKey: 2}; alert(array.key); Also, how would I assign a value to that key, having identified it with the variable? This is, of course, assuming that I must use the variable key to identify which item in the array to alert. Thanks in advance!

    Read the article

  • What would be jQuery equivalent of this sf hover suckerfish code?

    - by metal-gear-solid
    What would be jQuery equivalent of this sf hover suckerfish code? <script> sfHover = function() { var sfEls = document.getElementById("navbar").getElementsByTagName("li"); for (var i=0; i<sfEls.length; i++) { sfEls[i].onmouseover=function() { this.className+=" hover"; } sfEls[i].onmouseout=function() { this.className=this.className.replace(new RegExp(" hover\\b"), ""); } } } if (window.attachEvent) window.attachEvent("onload", sfHover); </script>

    Read the article

  • ASP: using existing Crystal Report with date parameter

    - by eric3141
    I have an existing Crystal Report done in Crystal Reports version 9. I need to display it via an ASP website created in Visual Studio 2008. I have put the Crystal data source and viewer controls on the design page and configured the controls to use the crystal report but cannot seem to figure out how to pass a date to the report which uses it as an input parameter for a SQL Server 2005 stored procedure. I have tried putting a calendar control on the design page but don't know how to use it to pass the date parameter. Thanks in advance for any help. Eric

    Read the article

  • Code Analysis Error: Declare types in namespaces

    - by George
    Is VS2010, I analyzed my code and got this error: Warning 64 CA1050 : Microsoft.Design : 'ApplicationVariables' should be declared inside a namespace. C:\My\Code\BESI\BESI\App_Code\ApplicationVariables.vb 10 C:\...\BESI\ Here is some reference info on the error. Essentially, I tried to create a class to be used to access data in the Application object in a typed way. The warning message said unless I put my (ApplicationVariables) class in a Namespace, that I wouldn't be able to use it. But I am using it, so what gives? Also, here is a link to another StackOverflow article that talks about how to disable this warning in VS2008, but how would you disable it for 2010? There is no GlobalSuppressions.vb file for VS2010. Here is the code it is complaining a bout: Public Class ApplicationVariables 'Shared Sub New() 'End Sub 'New Public Shared Property PaymentMethods() As PaymentMethods Get Return CType(HttpContext.Current.Application.Item("PaymentMethods"), PaymentMethods) End Get Set(ByVal value As PaymentMethods) HttpContext.Current.Application.Item("PaymentMethods") = value End Set End Property 'Etc, Etc... End Class

    Read the article

  • How do I setup a WCF Data Service with an ADO.NET Entity Entity Model in another assembly?

    - by lsb
    Hi! I have an ASP.NET 4.0 website that has an Entity Data Model hooked up to WCF Data Service. When the Service and Model are in the same assembly everything works. Unfortunately, when I move the Model to another "shared" assembly (and change the namespace) the service compiles but throws a 500 error when launched in a browser. The reason I want to have the Model in a common assembly (lets call it RiaTest.Shared) is that I want share common validation code between the client and service (by checking "Reuse types in referenced assemblies" in the Advanced tab of the Add Service Reference dialog). Anyway, I've spent a couple of hours on this to no avail so any help in the regard would be appreciated...

    Read the article

  • L'Hadopi serait "prête à entrer en fonction" selon ses membres, pourtant son organisation ne semble

    Mise à jour du 04.05.2010 par Katleen L'Hadopi serait "prête à entrer en fonction" selon ses membres, pourtant son organisation ne semble pas l'être Hier soir s'est tenue une conférence de presse sur les avancées du dispositif de l'Hadopi. Ses responsables le présentent comme "prêt à entrer en fonction". Pourtant, quelques points essentiels ne sont pas réglés. Déjà, les premiers e-mails d'avertissement seront envoyés d'ici à fin juin, et non fin avril comme il devait en être initialement. En plus, 4 décrets d'applications manquent encore à l'appel. Ils sont indispensables pour que la loi puisse entrer en vigueur, et on les attend toujours... Au...

    Read the article

  • PowerShell: How to find and uninstall a MS Office Update

    - by Hank
    I've been hunting for a clean way to uninstall an MSOffice security update on a large number of workstations. I've found some awkward solutions, but nothing as clean or general like using PowerShell and get-wmiobject with Win32_QuickFixEngineering and the .Uninstall method on the resulting object. [Apparently, Win32_QuickFixEngineering only refers to Windows patches. See: http://social.technet.microsoft.com/Forums/en/winserverpowershell/thread/93cc0731-5a99-4698-b1d4-8476b3140aa3 ] Question 1: Is there no way to use get-wmiobject to find MSOffice updates? There are so many classes and namespaces, I have to wonder. This particualar Office update (KB978382) can be found in the registry here (for Office Ultimate): HKLM\Software\Microsoft\Windows\CurrentVersion\Uninstall\{91120000-002E-0000-0000-0000000FF1CE}_ULTIMATER_{6DE3DABF-0203-426B-B330-7287D1003E86} which kindly shows the uninstall command of: msiexec /package {91120000-002E-0000-0000-0000000FF1CE} /uninstall {6DE3DABF-0203-426B-B330-7287D1003E86} and the last GUID seems constant between different versions of Office. I've also found the update like this: $wu = new-object -com "Microsoft.Update.Searcher" $wu.QueryHistory(0,$wu.GetTotalHistoryCount()) | where {$_.Title -match "KB978382"} I like this search because it doesn't require any poking around in the registry, but: Question 2: If I've found it like this, what can I do with the found information to facilitate the Uninstall? Thanks

    Read the article

  • Why is XML Deserilzation not throwing exceptions when it should.

    - by chobo2
    Hi Here is some dummy xml and dummy xml schema I made. schema <?xml version="1.0" encoding="utf-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.domain.com" xmlns="http://www.domain.com" elementFormDefault="qualified"> <xs:element name="vehicles"> <xs:complexType> <xs:sequence> <xs:element name="owner" minOccurs="1" maxOccurs="1"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:minLength value="2" /> <xs:maxLength value="8" /> </xs:restriction> </xs:simpleType> </xs:element> <xs:element name="Car" minOccurs="1" maxOccurs="1"> <xs:complexType> <xs:sequence> <xs:element name="Information" type="CarInfo" minOccurs="0" maxOccurs="unbounded" /> </xs:sequence> </xs:complexType> </xs:element> <xs:element name="Truck"> <xs:complexType> <xs:sequence> <xs:element name="Information" type="CarInfo" minOccurs="0" maxOccurs="unbounded"/> </xs:sequence> </xs:complexType> </xs:element> <xs:element name="SUV"> <xs:complexType> <xs:sequence> <xs:element name="Information" type="CarInfo" minOccurs="0" maxOccurs="unbounded" /> </xs:sequence> </xs:complexType> </xs:element> </xs:sequence> </xs:complexType> </xs:element> <xs:complexType name="CarInfo"> <xs:sequence> <xs:element name="CarName"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:minLength value="1"/> <xs:maxLength value="50"/> </xs:restriction> </xs:simpleType> </xs:element> <xs:element name="CarPassword"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:minLength value="6"/> <xs:maxLength value="50"/> </xs:restriction> </xs:simpleType> </xs:element> <xs:element name="CarEmail"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:pattern value="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"/> </xs:restriction> </xs:simpleType> </xs:element> </xs:sequence> </xs:complexType> </xs:schema> xml sample <?xml version="1.0" encoding="utf-8" ?> <vehicles> <owner>Car</owner> <Car> <Information> <CarName>Bob</CarName> <CarPassword>123456</CarPassword> <CarEmail>[email protected]</CarEmail> </Information> <Information> <CarName>Bob2</CarName> <CarPassword>123456</CarPassword> <CarEmail>[email protected]</CarEmail> </Information> </Car> <Truck> <Information> <CarName>Jim</CarName> <CarPassword>123456</CarPassword> <CarEmail>[email protected]</CarEmail> </Information> <Information> <CarName>Jim2</CarName> <CarPassword>123456</CarPassword> <CarEmail>[email protected]</CarEmail> </Information> </Truck> <SUV> <Information> <CarName>Jane</CarName> <CarPassword>123456</CarPassword> <CarEmail>[email protected]</CarEmail> </Information> <Information> <CarName>Jane</CarName> <CarPassword>123456</CarPassword> <CarEmail>[email protected]</CarEmail> </Information> </SUV> </vehicles> Serialization Class using System; using System.Collections.Generic; using System.Xml; using System.Xml.Serialization; [XmlRoot("vehicles")] public class MyClass { public MyClass() { Cars = new List<Information>(); Trucks = new List<Information>(); SUVs = new List<Information>(); } [XmlElement(ElementName = "owner")] public string Owner { get; set; } [XmlElement("Car")] public List<Information> Cars { get; set; } [XmlElement("Truck")] public List<Information> Trucks { get; set; } [XmlElement("SUV")] public List<Information> SUVs { get; set; } } public class CarInfo { public CarInfo() { Info = new List<Information>(); } [XmlElement("Information")] public List<Information> Info { get; set; } } public class Information { [XmlElement(ElementName = "CarName")] public string CarName { get; set; } [XmlElement("CarPassword")] public string CarPassword { get; set; } [XmlElement("CarEmail")] public string CarEmail { get; set; } } Now I think this should all validate. If not assume it is write as my real file does work and this is what this dummy one is based off. Now my problem is this. I want to enforce as much as I can from my schema. Such as the "owner" tag must be the first element and should show up one time and only one time ( minOccurs="1" maxOccurs="1"). Right now I can remove the owner element from my dummy xml file and deseriliaze it and it will go on it's happy way and convert it to object and will just put that property as null. I don't want that I want it to throw an exception or something saying this does match what was expected. I don't want to have to validate things like that once deserialized. Same goes for the <car></car> tag I want that to appear always even if there is no information yet I can remove that too and it will be happy with that. So what tags do I have to add to make my serialization class know that these things are required and if they are not found throw an exception.

    Read the article

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