text
stringlengths
8
267k
meta
dict
Q: SQL Backups in Compressed Folder We are looking for a free solution to compress our SQL Server backups for SQL Server 2005. I am aware of SQL Safe freeware edition, but I was wondering what others thought of storing backup files in compressed folders to achieve the desired result. This would allow us to use the na...
{ "language": "en", "url": "https://stackoverflow.com/questions/303324", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How do you open an InfoPath 2007 file programmatically from a service? I am trying to open an InfoPath 2007 file programmatically from a Windows service, but I get the following error: System.Runtime.InteropServices.COMException (0x80043000): InfoPath cannot open the following file: C:\path\datafile.xml. Not...
{ "language": "en", "url": "https://stackoverflow.com/questions/303325", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Transferring website I have made some changes to a site and need to re-host it as the current host is ceasing to exist. My client has received the following from the current host: "The best thing to tell them is that, due to the fact that we are withdrawing our service completely, we would look to fully transfer th...
{ "language": "en", "url": "https://stackoverflow.com/questions/303336", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: Web caching when retrieving lists of documents We have a need to leverage client side resources for lists containing tasks. The client needs to: * *be notified of updates to the list *be able to re-order/filter the list (requesting an update from the server with tasks that the client does not know of/have in cac...
{ "language": "en", "url": "https://stackoverflow.com/questions/303338", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: C# Process.Start, how to prevent re-use of existing application? I am coding a feature in a program where users can edit documents stored in a database, it saves the document to a temporary folder then uses Process.Start to launch the document into the editing application, let's say Microsoft Word for example. Then ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303339", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: C#, For Loops, and speed test... Exact same loop faster second time around? public Int64 ReturnDifferenceA() { User[] arrayList; Int64 firstTicks; IList<User> userList; Int64 secondTicks; System.Diagnostics.Stopwatch watch; userList = Enumerable .Range(0, 1000) .Select(curren...
{ "language": "en", "url": "https://stackoverflow.com/questions/303343", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: How do you set the current directory of a debugged process? I have an application that is sensitive to the directory it gets invoked from — it loads some files using relative paths. When I start the program through a debugger, how can I control what the initial current directory will be? I'd prefer to avoid adding s...
{ "language": "en", "url": "https://stackoverflow.com/questions/303350", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: What tool is the equivalent of Maven in TFS (or MS-land)? My company is moving from svn (and open source products) to TFS (and MS products). We've used maven in the past for packaging-up pre-built components into release-ready packages. Is there a tool in TFS or MS-Land as powerful as maven to do this? I've looked...
{ "language": "en", "url": "https://stackoverflow.com/questions/303357", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: Is there a better StringCollection editor for use in PropertyGrids? I'm making heavy use of PropertySheets in my application framework's configuration editor. I like them a lot because it's pretty easy to work with them (once you learn how) and make the editing bulletproof. One of the things that I'm storing in my ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303360", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: what's the easiest way to generate xml in c++? I've used boost serialization but this doesn't appear to allow me to generate xml that conforms to a particular schema -- it seems it's purpose was to just to persist a class's state. Platform: linux What do you guys use to generate NOT parse xml? So far I'm going down ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303371", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "17" }
Q: Need help styling a TabNavigator in Flex I have a tab navigator control and I would like to make all of the tabs a certain color, say blue... How can this be done? I have tried through the following CSS: TabNavigator { tabStyleName: "tabs"; } .tabs { backgroundColor:#6588b9; } but it only seems to work ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303374", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Larger WCF messages via MSMQ not processed I have a Windows Console App hosting a WCF service that reads from an MSMQ. When the message size gets to around 7k to 8k the service reads it (i.e. it disappears from the Q) but the appropriate function isn't called. No exceptions thrown. Anybody have any clues about what'...
{ "language": "en", "url": "https://stackoverflow.com/questions/303392", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Existing libraries for web app sign-up, sign-in, manage passwords? Do the major web application frameworks (Rails, Django, etc) have libraries that provide functionality for signing in, signing up, creating usernames, changing passwords, and managing lost passwords? It seems to me that this is common functionality t...
{ "language": "en", "url": "https://stackoverflow.com/questions/303394", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Nodes in an XML document I have designed a xml schema to parse an incoming xml document. The receive location gets xml documents from 2 feeds, one of them has misspelled a node in the document, "Roookie" instead of "Rookie", Is there a way to have my existing xsd parse this document? A: You could probably preproces...
{ "language": "en", "url": "https://stackoverflow.com/questions/303397", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: help with distinct rows and data ordering If I have records: Row Date, LocationID, Account 1 Jan 1, 2008 1 1000 2 Jan 2, 2008 1 1000 3 Jan 3, 2008 2 1001 4 Jan 3, 2008 1 1001 5 Jan 3, 2008 3 1001 6 Jan 4, 2008 3 1002 I need...
{ "language": "en", "url": "https://stackoverflow.com/questions/303404", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Implementing threads using C++ I have an API call in my application where I am checking the time taken for a single call. I have put this in a FOR loop and using 10000 calls to get the average times of all calls. Now the issue which came up was that the actual application using the API, is multi-threaded. If I wish ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303405", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is there a master list of COMExceptions? The Oracle community has a several support sites (here and here) that have lists of errors. The first site even has suggestions for how to fix them. Does anyone know of an equivalent list for Microsoft COM, preferably with Office Interop issues? A: No, every component is pe...
{ "language": "en", "url": "https://stackoverflow.com/questions/303411", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: What are the best practices in writing a sql stored procedure I found that SQL stored procedures are very interesting and useful. I have written stored procedures but i want to write well crafted, good performance tuned and concise SPs for any sort of requirement and also would love to learn about any tricks or good...
{ "language": "en", "url": "https://stackoverflow.com/questions/303417", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "37" }
Q: Ensuring only one user login using ASP.Net Membership Provider How would you ensure that only one user is logged in per account at a time? Assuming cookies are persistent. A: Typically the best way is to implement a customization on the provider that checks for last login, as well as adding methods to your code to ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303420", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Efficient persistent data structures for relational database I'm looking for material on persistent data structures that can be used to implement a relational model. Persistence in the meaning of immutable data structures. Anyone know of some good resources, books, papers and such? (I already have the book Purely Fu...
{ "language": "en", "url": "https://stackoverflow.com/questions/303426", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: setting a:visited link to same state as a:link and a:hover I'm working on a idea where my a:link have one state (blue, no underline etc) with a a:hover being white. I want my visited links to have the same state as a:link and a:hover. Is this possible? supported in most common browsers? A: The mnemonic I was taught...
{ "language": "en", "url": "https://stackoverflow.com/questions/303440", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: IE removes CHECKED attribute during animation I have some radio buttons inside a <div> container which I show and hide via jQuery effect. When the container hides in Firefox, the radio buttons are fine and the values reappear when the container reappears. However, in IE, the radio buttons first clear the checked r...
{ "language": "en", "url": "https://stackoverflow.com/questions/303446", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: What is the relationship between IRimTable and PersistenceStore? The BlackBerry Desktop API has the interface IRimTable which apparently maps an "application database" on a BlackBerry device to a virtual structure (i.e, IRimTable has IRimRecords, each of which has IRimField) that developer can browse the handheld de...
{ "language": "en", "url": "https://stackoverflow.com/questions/303452", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Does sp_updatestats cause tables to be inaccessible in SQL Server 2005? Does updating statistics cause tables to be inaccessible? In other words, can you run this procedure without downtime? Specifically for SQL Server 2005 A: No (it doesn't make them inaccessible), and Yes (you can run it without downtime). sp_u...
{ "language": "en", "url": "https://stackoverflow.com/questions/303454", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: What type of set-up/tools are must have if I want to build my skills as a software developer (in Java, Python, C, C++)? I am a newbie in the software development field. I am hungry for more avenues through which I can develop, nurture, and mature in my development, scripting, and programming skills, more so outside ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303456", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Proper ObjectDataSource Use Greetings! I'm creating a User Control that will display data in a GridView control. We are using n-tier architecture and the data in question is retrieved from our database and returned to us as a ReadOnlyCollection. OurNewObject is a class containing several properties and an empty co...
{ "language": "en", "url": "https://stackoverflow.com/questions/303460", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: cvs: working revision vs repository revision? When I do a cvs status, I see working revision and repository revision numbers. What is the difference between the two, or rather, what do they mean? A: the working revision is just the revision you are currently using. the repository revision is the revision currently ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303467", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: In PHP how can you clear a WSDL cache? In through php_info() where the WSDL cache is held (/tmp), but I don't necessarily know if it is safe to delete all files starting with WSDL. Yes, I should be able to just delete everything from /tmp, but I don't know what else this could effect if I delete any all WSDL files....
{ "language": "en", "url": "https://stackoverflow.com/questions/303488", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "97" }
Q: Programatically changing the culture of a DataGridView? I'd like to change the pricing column on my DataGridView based upon currency a user selected currency ComboBox. Currently, the price column is formatted to "C2". This defaults to look like "$1.00". However, if my user were to switch the currency to be Great B...
{ "language": "en", "url": "https://stackoverflow.com/questions/303491", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: C# When debugging I get "The requested operation requires elevation", why? It was OK yesterday! C# When I try to debug my program today I get "The requested operation requires elevation" (Vista of course). Why today? I've not changed anything the reads/writes to the registry or hard drive, where should I look? Thank...
{ "language": "en", "url": "https://stackoverflow.com/questions/303492", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: C# vs VB.NET - Handling of null Structures I ran across this and was wondering if someone could explain why this works in VB.NET when I would expect it should fail, just like it does in C# //The C# Version struct Person { public string name; } ... Person someone = null; //Nope! Can't do that!! Person? someoneEl...
{ "language": "en", "url": "https://stackoverflow.com/questions/303502", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "23" }
Q: How can I prevent XML::XPath from fetching a DTD while processing an XML file? My XML (a.xhtml) starts like this <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> ... My code starts like this use XML::XPath; use XML::XPath::XMLParser; my $x...
{ "language": "en", "url": "https://stackoverflow.com/questions/303510", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: CruiseControl.net -- How to checkin code during the build I'm setting up CruiseControl.NET and during the build I want to modify my version.txt file and have it checked in. When I do this, CruiseControl.NET doesn't know this checkin was done by the build and so the next time it checks sources, it sees there were mo...
{ "language": "en", "url": "https://stackoverflow.com/questions/303511", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Hidden features of Groovy? It seems like Groovy was forgotten in this thread so I'll just ask the same question for Groovy. * *Try to limit answers to Groovy core *One feature per answer *Give an example and short description of the feature, not just a link to documentation *Label the feature using bold title ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303512", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "78" }
Q: Should GExperts Functionality be Incorporated into Delphi? I recently upgraded to Delphi 2009 and was disappointed to find out that I couldn't easily replace one VCL component with another. The best answer back was that GExperts could be used to do this. Is it worthwhile to petition Embarcadero to incorporate some ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303515", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: initializing an n elements array using O(1) performence? someone has an idea how can I do that ? thanks A: If you need to do something to each element of a set of n elements, you cannot do it with better than O(n) performance. A: If you mean "initialize a dense array of N items in a time independent of N", then it...
{ "language": "en", "url": "https://stackoverflow.com/questions/303519", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: indirect remote images I am trying to create some HTML which shows me if my server is available from the internet, green light OK red light unavailable. This I can do for a remote site but not for my home, my router seems to prevent me from returning to home via my static IP address. I want to create some HTML so th...
{ "language": "en", "url": "https://stackoverflow.com/questions/303541", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: XML Deserialization Issue I have the following xml that's sent to me from a web service. I'm using .NET to deserialize it, but I'm getting an exception saying that its formatted wrong. There is an error in XML document (2, 2) Now, if I understand that correctly, it's not liking that it's finding the first <error> ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303548", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Bind asp.net control's value to code behind function I have a hidden field that i want to bind to either a function on the page's code behind. I don't quite recall the exact syntax and i can't find the answer via Google. Is the code below correct? Thank. print("<asp:HiddenField ID="dummy" Value='<%#Getdummy() %>' ru...
{ "language": "en", "url": "https://stackoverflow.com/questions/303554", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Using an interface to convert an object from one type to another? Suppose I have two classes with the same interface: interface ISomeInterface { int foo{get; set;} int bar{get; set;} } class SomeClass : ISomeInterface {} class SomeOtherClass : ISomeInterface {} Suppose I have an instance of ISomeInterfac...
{ "language": "en", "url": "https://stackoverflow.com/questions/303555", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: C++ format macro / inline ostringstream I'm trying to write a macro that would allow me to do something like: FORMAT(a << "b" << c << d), and the result would be a string -- the same as creating an ostringstream, inserting a...d, and returning .str(). Something like: string f(){ ostringstream o; o << a << "b" ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303562", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "15" }
Q: Using spring to get your service layer - good idea? Suppose I have service layer doing hibernate and DB stuff. Silverlight and windows clients need to get service layer through some kind of remote service. ASP.NET would benefit if could get it directly (on the same machine, same process, class instantiation). Is it ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303565", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: A range intersection algorithm better than O(n)? Range intersection is a simple, but non-trivial problem. Its has been answered twice already: * *Find number range intersection *Comparing date ranges The first solutions is O(n) and the second solution is for a database (which is less than O(n) of course). I have...
{ "language": "en", "url": "https://stackoverflow.com/questions/303591", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "24" }
Q: Graphviz for documentation I noticed that doxygen uses the graphviz library for creating diagrams. Have you ever used graphviz for generating documentation? Is it worth learning the graphviz for documentation purposes outside the scope of doxygen? Or am I better off to sticking with a standard data modeling package ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303608", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "17" }
Q: HttpWebRequest Server Unavailable 503 probleme I originally used WebRequest and WebResponse to sent Http Post Messages. Always I got a response of "OK". The message I post is an XML signed with a certificate in the xml. The composition is this: C# service that is sending to a https website. HTTPS Website on another ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303611", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Can we use JMX for Alerts/Notification Here are the specs that I'm trying to implement in a nutshell: 1) Some Alerts have to be sent on certain events in the application. 2) These Alerts have Users subscribe to them. 3) And the Users have set their own Notification preferences (e.g. Email and/or SMS). I have not bee...
{ "language": "en", "url": "https://stackoverflow.com/questions/303613", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: What's your Favorite Extreme Feedback Device? We've probably all heard about the connecting lava lamps and ambient orbs to your continuous integration systems. I was curious to know what other interesting things people are using or have heard of for extreme feedback devices? Also, this Tux Droid seemed pretty sweet...
{ "language": "en", "url": "https://stackoverflow.com/questions/303614", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "19" }
Q: Logging component that produces xml logs A lot of programs log things into a text file in a format something like this: 11/19/2008 13:29:01 DEBUG Opening connection to localhost. 11/19/2008 13:29:01 DEBUG Sending login message for user 'ADMIN'. 11/19/2008 13:29:03 DEBUG Received login response 'OK' for user 'ADMIN'....
{ "language": "en", "url": "https://stackoverflow.com/questions/303615", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: ADAM authentication w/ ADAM user and simple bind I've followed the ADAM Step by Step Guide from Microsoft and setup an ADAM instance on my local machine. I'm attempting to authenticate using the "Mary Baker" account, but every time I get a COM exception on the if (entry.Guid != null) line below. The exception stat...
{ "language": "en", "url": "https://stackoverflow.com/questions/303625", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: BBcode regex for **bold text** I'm terrible with regex, but I've had a try and a Google (and even looked in reddit's source) and I'm still stuck so here goes: My aim is to match the following 'codes' and replace them with the HTML tags. It's just the regex I'm stuck with. **bold text** _italic text_ ~hyperlink~ Her...
{ "language": "en", "url": "https://stackoverflow.com/questions/303639", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Custom component redraw issue with Delphi I have written a new custom component derived from TLabel. The component adds some custom drawing to component, but nothing else. When component is painted, everything works fine. But when the redraw is needed (like dragging another window over the component), "label part" w...
{ "language": "en", "url": "https://stackoverflow.com/questions/303642", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How do I learn if events are bound to an element using jquery? I need a hasEvents() method like var someBool = hasEvents($("#myelement")); that returns true if there are some bound events to any of the element's event handlers. A: have you taken a look at the hasEvent() plugin? the code is pretty small: (function(...
{ "language": "en", "url": "https://stackoverflow.com/questions/303654", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Open new Page from an Xbap Our application is an Xbap running in full trust. I have a function similar to this: private void ShowPage(Page page) { NavigationWindow mainWindow = Application.Current.MainWindow as NavigationWindow; mainWindow.Navigate(page); } This works great for browsing inside an existing...
{ "language": "en", "url": "https://stackoverflow.com/questions/303656", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Newbie Python Question about tuples I am new to Python, and I'm working on writing some database code using the cx_Oracle module. In the cx_Oracle documentation they have a code example like this: import sys import cx_Oracle connection = cx_Oracle.Connection("user/pw@tns") cursor = connection.cursor() try: cu...
{ "language": "en", "url": "https://stackoverflow.com/questions/303664", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Object Oriented Design help from C++ to C# Hey I usually run into a situation where I will create a class that should only be instantiated by one or a few classes. In this case I would make its constructor private and make it a friend class to the objects that should be able to instantiate it. For example (in C++): ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303668", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Using mysql concat() in WHERE clause? I would like to search my table having a column of first names and a column of last names. I currently accept a search term from a field and compare it against both columns, one at a time with select * from table where first_name like '%$search_term%' or last_name lik...
{ "language": "en", "url": "https://stackoverflow.com/questions/303679", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "53" }
Q: VB.NET Read current line in a text area? I have a text area and a function to do syntax highlighting on it. Right now it reads the entire RichTextBox. How would I get a string variable containing the current line? Below is the code i currently have. Private Sub HighLight() Dim rm As System.Text.RegularExpression...
{ "language": "en", "url": "https://stackoverflow.com/questions/303699", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Inheriting a .net class Ok here's what I'm trying to do I want to write a class that inherits everything from the class ListItem class RealListItem : ListItem { public string anExtraStringINeed; } For some reason or another .net is treating all the members like they are private when I try to do this so my class...
{ "language": "en", "url": "https://stackoverflow.com/questions/303700", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Calling a JNI modal dialog disables taskbar icon In a Java application (JRE 1.5.0_12) on Windows XP, I call a native method: public native int attachImage( ... ); ... which lives in a Visual C++ 6.0 .dll. It displays an application-modal window. Problem is, the application's tray icon doesn't respond to mouseclicks...
{ "language": "en", "url": "https://stackoverflow.com/questions/303712", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to display non-existing images the way IE/Opera does? My Firefox 3.0.4 does not display non-existing images at all, or it displays the image alt as plain text (if available). This way I would have no idea that there is supposed to be an image there. Does anyone know if there is a way to make it work like IE/Oper...
{ "language": "en", "url": "https://stackoverflow.com/questions/303718", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Is there a JavaScript alert that doesn't pause the script? I'm looking for something like alert(), but that doesn't "pause" the script. I want to display an alert and allow the next command, a form submit(), to continue. So the page will be changing after the alert is displayed, but it won't wait till the user has c...
{ "language": "en", "url": "https://stackoverflow.com/questions/303720", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "46" }
Q: ASP.NET Application state vs a Static object if i have a standard ASP.NET application, is there any difference between making an object static as opposed to putting the object instance in the Application state? from my understanding, both objects exist ONCE for the app domain. Secondly, what happens if you have a st...
{ "language": "en", "url": "https://stackoverflow.com/questions/303725", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "41" }
Q: (Python) socket.gaierror on every addres...except http://www.reddit.com? I'm just playing around and I'm trying to grab information from websites. Unfortunately, with the following code: import sys import socket import re from urlparse import urlsplit url = urlsplit(sys.argv[1]) sock = socket.socket() sock.connec...
{ "language": "en", "url": "https://stackoverflow.com/questions/303726", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: System.Net.Mail - Invalid Characters in Mail Address How can I send an email using SYstem.Net.Mail to an email address that is unusual (myFirstName.O'Reilly@mywebsite.com) but is still RFC 5322 compliant? Does .NET support sending mail addresses that have single quotes in them, and if so, how do I force the system t...
{ "language": "en", "url": "https://stackoverflow.com/questions/303731", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: VBScript: how to set values from recordset to string This is probably a beginner question, but how do you set a recordset to a string variable? Here is my code: Function getOffice (strname, uname) strEmail = uname WScript.Echo "email: " & strEmail Dim objRoot : Set objRoot = GetObject("LDAP://RootDSE") Dim objD...
{ "language": "en", "url": "https://stackoverflow.com/questions/303745", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Activate a File Virus Scan from within Delphi app We have an app that monitors a folder for file drop and need to initiate a virus scan before using any incoming files. This needs to be a part of the Delphi app and the file must pass the Virus Scan otherwise we delete the file. I know that there are command shell op...
{ "language": "en", "url": "https://stackoverflow.com/questions/303755", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: convert string to long long I'm using VS 2008 to create a C++ DLL (not managed) project and I need convert a char* to a long long type. Is there an easy way to do it? Thanks in advance :) A: If you're using boost, lexical_cast is the way to go, in my opinion. long long ll = boost::lexical_cast<long long>(mystr) A...
{ "language": "en", "url": "https://stackoverflow.com/questions/303759", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: What are use cases for coroutines? The concept of a coroutine sounds very interesting, but I don't know, if it makes sense in a real productive environment? What are use cases for coroutines, where the coroutine implementation is more elegant, simpler or more efficient than other methods? A: As a producer/consumer ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303760", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "61" }
Q: How do I get the path of the current drupal theme? The Drupal API has drupal_get_path($type, $name) which will give the path of any particular theme or module. What if I want the path of the current theme? A: In Drupal 8, if you need to get the active theme path when you have the admin theme active you can fetch t...
{ "language": "en", "url": "https://stackoverflow.com/questions/303761", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "28" }
Q: Automate "Attach to Process" in VS2005/2008 I was wondering if anyone knew of a macro or keyboard shortcut or anything really that would automate Attaching to a Process within visual studio? A: System.Diagnostics.Debugger.Break() "If no debugger is attached, users are asked if they want to attach a debugger. If yes...
{ "language": "en", "url": "https://stackoverflow.com/questions/303763", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: How do I determine height and scrolling position of window in jQuery? I need to grab the height of the window and the scrolling offset in jQuery, but I haven't had any luck finding this in the jQuery docs or Google. I'm 90% certain there's a way to access height and scrollTop for an element (presumably including the...
{ "language": "en", "url": "https://stackoverflow.com/questions/303767", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "183" }
Q: PhpMailer vs. SwiftMailer? I'm building a fairly simple PHP script that will need to send some emails with attachments. I've found these 2 libraries to do this. Does either one have significant advantages over the other? Or should I just pick one at random and be done with it? A: There is also Zend_Mail. If I had ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303783", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "65" }
Q: asp.net cascading dropdown with a difference Anyone know of a control for asp.net that can achieve this either server or ajax. I have a hierarchy of school, division and programme area. Unfortunately this hierarchy has complexities such that a programme area can appear in more than one school. As it is for reportin...
{ "language": "en", "url": "https://stackoverflow.com/questions/303795", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Hooking Up an NSTableView to an XML-RPC Server There are multiple ways to fill an NSTableView up with data through either bindings, delegates, or data sources. What is the best way to go about filling up the tableview with data that is changed pretty frequently from an XML-RPC server? I'm targeting Mac OS X 10.5 on...
{ "language": "en", "url": "https://stackoverflow.com/questions/303805", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How do I place/scale a XAML graphic in my application? I'm working on a simple application to start learning my way around WPF. I created a vector graphic in Microsoft Expression Design at 400px by 400px, mainly because I thought it would be easier to create it on a bigger canvas. I've exported the image to a XAML f...
{ "language": "en", "url": "https://stackoverflow.com/questions/303809", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Variable (dynamic) OPTION lists in HTML SELECT using IE I'm trying to implement a dynamic OPTION list in JavaScript. Depending on other selections in the web form, some of the OPTIONS in a specific SELECT are not valid. Things I've tried that don't work in IE are: * *populate all options, then set the disabled...
{ "language": "en", "url": "https://stackoverflow.com/questions/303810", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Accessing MySQL relations with Ruby on Rails How do you access a MySQL relation using RoR? A: Toby is right. You need to learn about table relationships using ActiveRecord. The gist. You need to put the following codes in your models. Here is an example. In User model: has_many :addresses In the Address model: bel...
{ "language": "en", "url": "https://stackoverflow.com/questions/303827", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Ruby 'Capitalize!' paradox In Ruby we have the 'bang' method capitalize! which has the strange behavior of returning a nil if no changes to the string were made. That means I can't chain this commands with other since it effectively destroys the chain if it returns nil. What im trying to do is something like this: f...
{ "language": "en", "url": "https://stackoverflow.com/questions/303829", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: What's the best way to parse a body of text against multiple (15+) regexes on each line? I have a body of text that I have to scan and each line contains at least 2 and sometimes four parts of information. The problem is that each line can be 1 out of 15-20 different actions. in ruby the current code looks somewhat ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303830", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: Should a method ignore illegal input or raise an exception? If a method checks it's input and detects illegal input, what should it do: Raise an exception (or use another error-mechanism) or do nothing/ignoring on the wrong input? In Java the HashTable-class throws an NullPointerException if given null-references as...
{ "language": "en", "url": "https://stackoverflow.com/questions/303832", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to handle authorization when using NHibernate in .NET I'm using the repository pattern to query our database using NHibernate. It makes it really easy to do things like: public T GetById(int id) {...} But that doesn't help much when someone start mucking with the querystrings to see things they aren't allowed to...
{ "language": "en", "url": "https://stackoverflow.com/questions/303835", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Create a new cmd.exe window from within another cmd.exe prompt I am in the process of setting up CruiseControl.NET. The problem I am having is that I am running CC as a console application and when my build completes successfully and executes (using exec) it launches it within the CruiseControl DOS prompt. I am just...
{ "language": "en", "url": "https://stackoverflow.com/questions/303838", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "124" }
Q: Why does my script report 'uninitialized value in eval "string"? I am getting this warning: Use of uninitialized value in eval \"string\" at myscript.pl line 57. When I run this code: eval; { `$client -f $confFile -i $inputFile -o $outputFile`; }; if( $@ ) { # error handling here ... } What is cau...
{ "language": "en", "url": "https://stackoverflow.com/questions/303841", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: ActiveX control within Web Page to create User Account I'm wondering if there is any way to create a User Account on a Windows XP machine that can be done through scripting from an ActiveX control on a webpage. Specifically, I'd like to know if there's any way to deploy an ActiveX control with computers (that I pre...
{ "language": "en", "url": "https://stackoverflow.com/questions/303842", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: how to use libxml2 to modify an existing xml file? I need to take an existing xml file, and modify just a few attributes and write the file back out. I was thinking of using libxml2 to get this done. Application is C/C++ running on Linux. Thing is, libxml2 seems to include several variations of the kitchen sink, al...
{ "language": "en", "url": "https://stackoverflow.com/questions/303845", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: Active Record / Three Tier Architecture I would like to separate my application into three tiers to use a service layer. I would also like to use the same domain model in both the UI tier, and the business layer tier because I control both ends. This makes sense, but I would also like to use Castles Active Record fo...
{ "language": "en", "url": "https://stackoverflow.com/questions/303849", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What are your impressions of Maven? I am considering using Maven for a Java open source project I manage. In the past, however, Maven has not always had the best reputation. What are your impressions of Maven, at this time? A: There a few very good things about maven: * *Archetypes: A kind of start up (base) p...
{ "language": "en", "url": "https://stackoverflow.com/questions/303853", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "20" }
Q: ASP.NET and Sessions - New Browser Instance versus New Browser Window I'm hoping someone can clarify this behavior for me, and explain how ASP.NET is deciding when to treat something like a new Session. A) In Internet Explorer I load the ASP.NET site in question. It starts a new Session. B) If I go to menu File - Ne...
{ "language": "en", "url": "https://stackoverflow.com/questions/303859", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Is a successor for TeX/LaTeX in sight? TeX/LaTeX is great, I use it in many ways. Some of its advantages are: * *it uses text files, this way the input-files can be diffed and many tools exist to work with text *it is very flexible *it has a stable layout: if I change something at the start of the document, it ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303877", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "123" }
Q: Should software development be separated from software design & usability? In most of the commercial jobs I've had to date, my role has mostly been confined to "writing the code", whereas the reason I wanted to get into development in the first place was because I enjoyed usability and design aspect of software. I f...
{ "language": "en", "url": "https://stackoverflow.com/questions/303891", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Any Rhino Commons Getting Started Tutorials? There used to be a great one at this blog: http://www.hanneyetc.co.uk/ but it is offline now. A: Ryan Lanciaux blog: RhinoCommons, NHibernate and ASP.NET MVC Part 1 - Setup A: Some more resources: * *Ayende's wiki *Ayende's Exesto (a sample app) *Rhino Commons unit...
{ "language": "en", "url": "https://stackoverflow.com/questions/303906", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: REST tools support for development and testing There is a similar question here but it only covers some of the issues below. We have a client who requires web services using REST. We have tons of experience using SOAP and over time have gathered together a really good set of tools for SOAP development and testing e....
{ "language": "en", "url": "https://stackoverflow.com/questions/303911", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "23" }
Q: Java: Reading integers from a file into an array File fil = new File("Tall.txt"); FileReader inputFil = new FileReader(fil); BufferedReader in = new BufferedReader(inputFil); int [] tall = new int [100]; String s =in.readLine(); while(s!=null) { int i = 0; tall[i] = Integer.parseInt(s); //this is line 19 ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303913", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "15" }
Q: IoC and User Interfaces I'm trying to wrap my head around the best way to use IoC within my application for dependency injection, however I have a little issue. I am using a loose implementation of the MVP pattern with a WPF app. Essentially, a presenter class is instantiated, and a view and task (e.g. IEmployeeView...
{ "language": "en", "url": "https://stackoverflow.com/questions/303916", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Sql 2008 query problem - which LatLong's exists in a geography polygon? i have the following two tables:- GeoShapes * *GeoShapeId INT IDENTITY *Name VARCHAR(100) *ShapeFile GEOGRAPHY [ this is a closed Polygon of Lat/Longs ] CrimeLocations * *CrimeLocationId INT IDENTITY *LatLong GEOGRAPHY [ this is a ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303927", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Display separator in Sharepoint AspMenu control All I'm trying to do is display a separator (I've tried images & stylesheets) between the primary navigation menu items in Sharepoint. Here is what I want it to look like: Home | Menu1 | Menu2 | Menu3 When I attempt to use the StaticTopSeparatorImageUrl (using a bar ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303929", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How do you make 'scrum' work when participants are 12 time zones apart? Is it even sensible to try forming a scrum when one of the participants is in India (+05:30), and others are in the US (-06:00 and -08:00)? There isn't a comfortable meeting time for everyone with that. A: I've been in this sort of situation, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303933", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: C# extension methods in a "site.master" template thats wrapped in a namespace quandary The question is this, why do I need to add an "import" directive on my Site.Master file to get Intellisense when the html helpers work without it. Using a simple C# string extension method without a namespace == no problem. Howeve...
{ "language": "en", "url": "https://stackoverflow.com/questions/303938", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Contextual Selectors in CSS2 I'm wondering why styling an element within a specific class, like this: .reddish H1 { color: red } is shown as an example of correct syntax in the CSS1 specification under Contextual selectors: Cascading Style Sheets, level 1 but it's not shown as an example in the CSS2 spec: Cascading...
{ "language": "en", "url": "https://stackoverflow.com/questions/303939", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: In SQL*Plus, how do I change the prompt to show the connected user and database? To show, for example.... USER@SID > I thought this was potentially helpful to a few people so I'm going to answer it too! A: Amend your $ORACLE_HOME\sqlplus\admin\glogin.sql script - add: set sqlprompt "_user '@' _connect_identifier ...
{ "language": "en", "url": "https://stackoverflow.com/questions/303940", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }