instruction
stringlengths
14
27.6k
completion
stringlengths
3
38.3k
__original_row_idx
int64
0
50k
conversations
listlengths
2
2
Is there a way to get an ASP.NET textbox to accept only currency values, and when the control is validated, insert a $ sign beforehand? Examples: 10.23 becomes $10.23 $1.45 stays $1.45 10.a raises error due to not being a valid number I have a RegularExpressionValidator that is verifying the number is valid, but I ...
To create an ASP.NET TextBox that accepts only currency values and prefixes the value with a `$` sign upon validation, you can indeed use JavaScript, along with ASP.NET server controls. Here's a detailed way to achieve this using the RegularExpressionValidator to check for valid currency formats, and some JavaScript to...
31,035
[ { "from": "human", "value": "Is there a way to get an ASP.NET textbox to accept only currency values, and when the control is validated, insert a $ sign beforehand?\nExamples: \n10.23 becomes $10.23\n$1.45 stays $1.45\n10.a raises error due to not being a valid number \nI have a RegularExpressionValidator...
I have inherited a subversion repo which looks like this: https://foo/product/src I want to make it more like: https://foo/product/trunk/src https://foo/product/tags https://foo/product/branches Will moving ./src to ./trunk/src retain history ? I also want to make sure the other developers don't curse me for doing t...
Yes, you can reorganize your Subversion (SVN) repository by moving `./src` to `./trunk/src`, and this will retain the full history of the files. When you perform a move operation in SVN, it effectively records the action in the repository's history, which allows you and other developers to access the previous revisions...
32,993
[ { "from": "human", "value": "I have inherited a subversion repo which looks like this:\nhttps://foo/product/src\nI want to make it more like:\n\nhttps://foo/product/trunk/src\nhttps://foo/product/tags\nhttps://foo/product/branches\n\nWill moving ./src to ./trunk/src retain history ? \nI also want to make su...
Does anyone know of any code or tools that can strip literal values out of SQL statements? The reason for asking is I want to correctly judge the SQL workload in our database and I'm worried I might miss out on bad statements whose resource usage get masked because they are displayed as separate statements. When, in r...
Stripping literal values out of SQL statements to analyze the workload is a common requirement for database performance tuning. Below are a few approaches and tools that you can use, including code snippets for different programming languages. ### 1. Regular Expressions in Python You can use Python's regular expressi...
30,729
[ { "from": "human", "value": "Does anyone know of any code or tools that can strip literal values out of SQL statements?\nThe reason for asking is I want to correctly judge the SQL workload in our database and I'm worried I might miss out on bad statements whose resource usage get masked because they are dis...
WPF's view model oriented way of doing things makes it very tempting to just use business objects in the UI. Have you seen any issues with this? Why or why wouldn't you do this?
Using business objects directly in a WPF application can indeed seem tempting due to the convenience of having direct access to the data without needing a separate layer of abstraction. However, there are several reasons why this practice can lead to potential issues, and why implementing a more robust ViewModel patter...
35,077
[ { "from": "human", "value": "WPF's view model oriented way of doing things makes it very tempting to just use business objects in the UI. Have you seen any issues with this? Why or why wouldn't you do this?\n" }, { "from": "gpt", "value": "Using business objects directly in a WPF application can...
I have a Win32 console application which is doing some computations, compiled in Compaq Visual Fortran (which probably doesn't matter). I need to run a lot of them simultaneously. In XP, they take around 90-100% CPU together, work very fast. In Vista, no matter how many of them I run, they take no more than 10% of CPU...
It sounds like you're encountering a classic problem related to how Windows Vista handles scheduling and resource management differently compared to Windows XP. Here are several suggestions to help troubleshoot and potentially resolve the issue with your console applications running slowly on Vista: 1. **Check Process...
34,544
[ { "from": "human", "value": "I have a Win32 console application which is doing some computations, compiled in Compaq Visual Fortran (which probably doesn't matter). \nI need to run a lot of them simultaneously.\nIn XP, they take around 90-100% CPU together, work very fast.\nIn Vista, no matter how many of t...
I am looking to parse INSERT and UPDATE MySQL SQL queries in PHP to determine what changes where made from what original data. Now this would be pretty easy to create, but I want to see if there are any existing libraries in PHP to do this. Basically what I have is a table with all of the above queries that have been r...
Parsing SQL queries to extract meaningful changes and generate a changelog can be complex, but there are a few libraries in PHP that can help you with different aspects of this task. However, there isn't a specific library dedicated solely to parsing SQL INSERT and UPDATE queries to generate changelogs. Instead, you mi...
34,536
[ { "from": "human", "value": "I am looking to parse INSERT and UPDATE MySQL SQL queries in PHP to determine what changes where made from what original data. Now this would be pretty easy to create, but I want to see if there are any existing libraries in PHP to do this.\nBasically what I have is a table with...
Anyone know of an opensource PHP Load Testing Framework similar to the Grinder " "http://grinder.sourceforge.net/".
Yes, there are several open-source load testing frameworks available for PHP that can serve as alternatives to The Grinder. Here are a few options you might consider: 1. **Apache JMeter**: - While not PHP-based, JMeter is a powerful and widely-used open-source load testing tool that can simulate multiple users with...
28,518
[ { "from": "human", "value": "Anyone know of an opensource PHP Load Testing Framework similar to the Grinder \" \"http://grinder.sourceforge.net/\". \n" }, { "from": "gpt", "value": "Yes, there are several open-source load testing frameworks available for PHP that can serve as alternatives to The...
I'm using TkCVS as the GUI front-end for a CYGWIN CVS client, on a Windows XP machine. It's a good compromise, since on my Linux machine I'm also running TkCVS (the same machine running the CVS server, BTW...). I'm interested in replacing the diff utility (which has a tkdiff.tcl GUI front-end, for TkCVS) with a commerc...
To replace the default diff utility in TkCVS with a commercial product like Beyond Compare or ExamDiff, you'll need to configure TkCVS to use your chosen diff tool. Below are general steps to accomplish this: ### Steps to Configure TkCVS with a Commercial Diff Tool 1. **Install the Diff Tool**: Make sure that you hav...
32,183
[ { "from": "human", "value": "I'm using TkCVS as the GUI front-end for a CYGWIN CVS client, on a Windows XP machine.\nIt's a good compromise, since on my Linux machine I'm also running TkCVS (the same machine running the CVS server, BTW...).\nI'm interested in replacing the diff utility (which has a tkdiff.t...
Hello fellow stackoverflowers! I have a word list of 200.000 string entries, average string length is around 30 characters. This list of words are the key and to each key i have a domain object. I would like to find the domain objects in this collection by only knowing a part of the key. I.E. the search string "kov" wo...
Hi Oskar, It sounds like you're facing a performance challenge with your current Ternary Search Tree (TST) implementation for substring searches. Given your requirements for speed and the size of your dataset, there are several alternatives and optimizations you might consider: ### 1. **Aho-Corasick Algorithm** The A...
31,320
[ { "from": "human", "value": "Hello fellow stackoverflowers!\nI have a word list of 200.000 string entries, average string length is around 30 characters. This list of words are the key and to each key i have a domain object. I would like to find the domain objects in this collection by only knowing a part o...
It's been a few years since I've taken a deep look at Mono. When I last took a look, it wasnt quite there as far as BCL implementation and the tools available were limited. I have a specific need now to do some cross platform development, and was wondering what the community thought about Mono as a choice in the enterp...
Mono has made significant strides since it was first introduced, and it's now considered a viable option for cross-platform development, especially for enterprise applications. Here are some points to consider when evaluating Mono for your large-scale enterprise project: ### 1. **Compatibility and BCL Implementation**...
33,015
[ { "from": "human", "value": "It's been a few years since I've taken a deep look at Mono. When I last took a look, it wasnt quite there as far as BCL implementation and the tools available were limited. I have a specific need now to do some cross platform development, and was wondering what the community tho...
If you take over a project from someone to do simple updates do you follow their naming convention? I just received a project where the previous programmer used Hungarian Notation everywhere. Our core product has a naming standard, but we've had a lot of people do custom reporting over the years and do whatever they ...
When taking over a project, it's important to balance consistency with readability and maintainability. Here are some considerations to help you make a decision: 1. **Consistency with Existing Code**: If the existing codebase uses Hungarian Notation extensively, continuing with that convention for your updates may imp...
35,218
[ { "from": "human", "value": "If you take over a project from someone to do simple updates do you follow their naming convention? I just received a project where the previous programmer used Hungarian Notation everywhere. Our core product has a naming standard, but we've had a lot of people do custom repor...
Where can I setup custom errors for directories in my application such as App_Code, App_Browsers, etc.? I already have customErrors configured in the web.config and that works as expected. For example, http://www.mysite.com/bla.aspx > redirects to 404 page but http://www.mysite.com/App_Code/ > displays "The system ca...
When you encounter errors related to specific directories like `App_Code`, `App_Browsers`, etc., these errors often stem from the underlying IIS configuration or ASP.NET's handling of certain requests. Since these directories are part of the application structure but do not correspond to actual files accessible over HT...
35,002
[ { "from": "human", "value": "Where can I setup custom errors for directories in my application such as App_Code, App_Browsers, etc.? I already have customErrors configured in the web.config and that works as expected. For example,\nhttp://www.mysite.com/bla.aspx > redirects to 404 page\nbut\nhttp://www.my...
I'm trying to get my head around SPL iterators and I've come up with 2 ways to handle it. I see the first version to be less complicated but the second version has composition feel to it (I think). What am I not seeing is which one is preferable over the other? Or am I just over complicating this? Here are my thoughts:...
You are exploring two different design approaches for handling collections of items (in this case, chocolates) using iterators in PHP. Both approaches have their merits, and choosing the right one depends on your specific use case and design preferences. ### Approach 1: BoxOfChocolates Implements Iterator **Pros:** 1...
33,314
[ { "from": "human", "value": "I'm trying to get my head around SPL iterators and I've come up with 2 ways to handle it. I see the first version to be less complicated but the second version has composition feel to it (I think).\nWhat am I not seeing is which one is preferable over the other? Or am I just ove...
I created an html helper Html.BreadCrumb(IDictionary<string, string> crumbs) Where the first string is the label and the second string is the URL. The helper creates the html required (an unordered list, some classes for first element, current element, last element, dead element and separators etc) All working nice, ...
Using `StringBuilder` to construct HTML in a custom HTML helper is a common approach, and for smaller amounts of HTML, it's perfectly fine. However, for larger HTML structures or for performance-sensitive applications, there are indeed better alternatives that can help improve efficiency and readability. ### Alternati...
31,025
[ { "from": "human", "value": "I created an html helper \nHtml.BreadCrumb(IDictionary<string, string> crumbs)\n\nWhere the first string is the label and the second string is the URL.\nThe helper creates the html required (an unordered list, some classes for first element, current element, last element, dead e...
Summary Client (Windows XP SP3) Server (Windows Vista Business SP1) / Running as LocalSystem Service Api Sequence Client - AcquireCredentialsHandle Client - Initializesecuritycontext Server - Acquirecredentialshandle Server - AcceptSecurityContext Client/Server - CompleteAuthnToken Server - ImpersonateSecurity...
The summary describes a client-server application setup that uses SSPI (Security Support Provider Interface) for authentication and access control over an unsecured TCP network. The client runs on Windows XP SP3 and the server on Windows Vista Business SP1, utilizing the LocalSystem service. Here's a breakdown of the ...
31,013
[ { "from": "human", "value": "Summary \nClient (Windows XP SP3) \nServer (Windows Vista Business SP1) / Running as LocalSystem Service \nApi Sequence \nClient - AcquireCredentialsHandle \nClient - Initializesecuritycontext \nServer - Acquirecredentialshandle \nServer - AcceptSecurityContext \nClient/Server -...
I have 3 files: /a/A.java /a/aa/AA.java /b/B.java and B.java depends on A.java and AA.java. I basically want javac -classpath /a /b/B.java to work (i.e. have javac search below /a). Is there any way I can do this?
To compile `B.java` while allowing it to access `A.java` and `AA.java` from the `/a` directory using the `javac` command, you need to specify the classpath correctly. In Java, the classpath can include directories, and when you specify a directory in the classpath, it recursively searches for classes in the specified ...
33,434
[ { "from": "human", "value": "I have 3 files:\n/a/A.java\n/a/aa/AA.java\n/b/B.java\nand B.java depends on A.java and AA.java.\nI basically want javac -classpath /a /b/B.java to work (i.e. have javac search below /a).\nIs there any way I can do this?\n" }, { "from": "gpt", "value": "To compile `B....
Let's say I have a table: i j --- a 1 a 2 a 3 a 4 b 5 b 6 b 7 b 8 b 9 Obvoiusly SELECT a, GROUP_CONCAT(b SEPARATOR ',') GROUP BY a would give me a 1,2,3,4 b 5,6,7,8,9 But what if I want to get only a LIMITED number of results, like 2, for example: a 1,2 b 5,6 Any ideas?
To achieve this in SQL, where you want to group your results by a column and limit the number of concatenated values from another column, you can use a combination of `GROUP_CONCAT`, `LIMIT`, and a subquery or common table expressions (CTEs) to first fetch limited results for each group. Here’s one way to do it using ...
35,155
[ { "from": "human", "value": "Let's say I have a table:\n\ni j\n---\na 1\na 2\na 3\na 4\nb 5\nb 6\nb 7\nb 8\nb 9\n\nObvoiusly SELECT a, GROUP_CONCAT(b SEPARATOR ',') GROUP BY a would give me\n\na 1,2,3,4\nb 5,6,7,8,9\n\nBut what if I want to get only a LIMITED number of results, like 2, for example:\n\na ...
When browsing ASP.NET MVC source code in codeplex, I found it is common to have a class explicitly implementing interface. The explicitly implemented method/property then invoke another "protected virtual" method/property with same name. For example, public class MvcHandler : IHttpHandler, IRequiresSessionState { ...
The pattern you've encountered, where a class explicitly implements an interface and uses a protected virtual member to back it, has several benefits and design considerations: 1. **Encapsulation**: By explicitly implementing the interface member, the class keeps the interface's method or property hidden from public c...
33,050
[ { "from": "human", "value": "When browsing ASP.NET MVC source code in codeplex, I found it is common to have a class explicitly implementing interface. The explicitly implemented method/property then invoke another \"protected virtual\" method/property with same name.\nFor example, \npublic class MvcHandler...
Background I work for a large organization which has thousands of MS Access applications floating around. I didn't write any of these - in fact, most of the original authors have long since left the company - but from time to time another Access app lands on my desk for support. I would soooo love to replace access w...
It's great to see your initiative in wanting to transition away from MS Access, especially considering the challenges that come with supporting legacy applications. There are indeed several alternatives for creating front-end applications that provide structure, better maintainability, and scalability. Below are some s...
31,590
[ { "from": "human", "value": "Background\nI work for a large organization which has thousands of MS Access applications floating around. I didn't write any of these - in fact, most of the original authors have long since left the company - but from time to time another Access app lands on my desk for suppor...
I'm trying to load assemblies in a separate app domain, but am running into a very strange problem. Here's some code: public static void LoadAssembly(string assemblyPath) { string pathToDll = Assembly.GetCallingAssembly().CodeBase; AppDomainSetup domainSetup = new AppDomainSetup { ...
The issue you are encountering with a `InvalidCastException` when trying to cast the instance of `AssemblyLoader` that you created in a separate AppDomain to the type `AssemblyLoader` is a common issue when dealing with AppDomains and cross-AppDomain communication in .NET. Here are some potential reasons for this issu...
29,737
[ { "from": "human", "value": "I'm trying to load assemblies in a separate app domain, but am running into a very strange problem. Here's some code:\n public static void LoadAssembly(string assemblyPath)\n {\n\n string pathToDll = Assembly.GetCallingAssembly().CodeBase;\n AppDomainSetup do...
I need an algorithm that can compare two text files and highlight their difference and ( even better!) can compute their difference in a meaningful way (like two similar files should have a similarity score higher than two dissimilar files, with the word "similar" defined in the normal terms). It sounds easy to implem...
To compare two text files and highlight their differences while also calculating a similarity score, we can utilize a combination of file reading, string manipulation, and a diffing algorithm. For this implementation, we'll use Python, leveraging libraries such as `difflib` to compute differences and calculate a simila...
27,598
[ { "from": "human", "value": "I need an algorithm that can compare two text files and highlight their difference and ( even better!) can compute their difference in a meaningful way (like two similar files should have a similarity score higher than two dissimilar files, with the word \"similar\" defined in ...
I've been asked to add Google e-commerce tracking into my site. This tracking involves inserting some javascript on your receipt page and then calling it's functions. From my asp.net receipt page, I need to call one function (_addTrans) for the transaction info and then another (_addItem) for each item on the order. ...
Certainly! To implement Google e-commerce tracking on your ASP.NET receipt page, you'll typically want to render the necessary JavaScript directly from your code-behind. Assuming you're using ASP.NET Web Forms, you can directly inject the JavaScript for `_addTrans` and `_addItem` functions into your page in the approp...
29,203
[ { "from": "human", "value": "I've been asked to add Google e-commerce tracking into my site. This tracking involves inserting some javascript on your receipt page and then calling it's functions. From my asp.net receipt page, I need to call one function (_addTrans) for the transaction info and then anothe...
I am using a custom colour scheme in Visual Studio 2008. The annotate bar (that shows who checked each block of code in and when) is rendering in some illegible colours. I can't identify which colours these are within the relevant Options dialog so I cannot change them to something clearer. Does anybody know how to cha...
In Visual Studio 2008, the colors used in the annotate bar (also known as the "Source Control" bar) can be a bit tricky to change, especially since it may not be directly exposed in the regular color settings. However, you can adjust some settings to make the annotate bar more legible. Here's how you can change the co...
31,865
[ { "from": "human", "value": "I am using a custom colour scheme in Visual Studio 2008. The annotate bar (that shows who checked each block of code in and when) is rendering in some illegible colours. I can't identify which colours these are within the relevant Options dialog so I cannot change them to someth...
I have not developed web services applications that publicly faced the Internet. As I begin to consider the issues of exposing schema definitions to a wide audience, I believe a certain amount of consideration should be spent on properly formatting the schema namespaces. Has anybody come across a guideline document tha...
When it comes to defining XML schema namespaces, there are indeed many considerations to take into account, and best practices can vary depending on organizational needs, existing practices, and future expectations. While there may not be a universally agreed-upon guideline document specifically for XML schema namespac...
26,289
[ { "from": "human", "value": "I have not developed web services applications that publicly faced the Internet. As I begin to consider the issues of exposing schema definitions to a wide audience, I believe a certain amount of consideration should be spent on properly formatting the schema namespaces.\nHas an...
My question is in regards to MySQL, but I also wonder how this affects other databases. I have several fields that are varchar(255) but my coworker insists if they were varchar(30) -- or any smaller size -- then queries would run faster. I'm not so sure, but if it's so I'll admit to it.
The size of `VARCHAR` fields can have an impact on performance, but it's not always as straightforward as smaller sizes leading to faster queries. Here are some factors to consider: ### 1. Storage Efficiency: - **Disk Space**: Smaller `VARCHAR` sizes may save disk space when storing data. If you have a large amount of...
32,950
[ { "from": "human", "value": "My question is in regards to MySQL, but I also wonder how this affects other databases. I have several fields that are varchar(255) but my coworker insists if they were varchar(30) -- or any smaller size -- then queries would run faster. I'm not so sure, but if it's so I'll ad...
I'm trying to configure NAnt to automate my build process - once I've got this step nailed, I'll be integrating the unit tests. Perhaps I don't exactly know what I want, so please correct me if there is a completely different way of doing all of this... I want two NAnt targets, one to do quick, debug builds to make sur...
It's great that you're using NAnt to automate your build process! Let's tackle your problems one at a time. ### 1. Compiling DLLs without copying web assets If you want to compile your project without copying additional web assets (like .aspx files, images, etc.), you can change your MSBuild target. Instead of using ...
32,548
[ { "from": "human", "value": "I'm trying to configure NAnt to automate my build process - once I've got this step nailed, I'll be integrating the unit tests.\nPerhaps I don't exactly know what I want, so please correct me if there is a completely different way of doing all of this...\nI want two NAnt targets...
Here's the XML code I'm working with: <inventory> <drink> <lemonade supplier="mother" id="1"> <price>$2.50</price> <amount>20</amount> </lemonade> <lemonade supplier="mike" id="4"> <price>$3.00</price> <amount>20</amount> </lemonade> ...
Your XPath expressions appear to be correct, and they should indeed filter the `<lemonade>` elements by their attributes, selecting only the `<price>` child elements of those filtered `<lemonade>` elements. However, in your PHP code, it looks like there may be a couple of issues that could prevent the expected output...
24,345
[ { "from": "human", "value": "Here's the XML code I'm working with:\n<inventory>\n <drink>\n <lemonade supplier=\"mother\" id=\"1\">\n <price>$2.50</price>\n <amount>20</amount>\n </lemonade>\n <lemonade supplier=\"mike\" id=\"4\">\n <price>$3.00</pric...
In the following code I loop through a map and test if an element needs to be erased. Is it safe to erase the element and keep iterating or do I need to collect the keys in another container and do a second loop to call the erase()? map<string, SerialdMsg::SerialFunction_t>::iterator pm_it; for (pm_it = port_map.begin...
In C++, when you are iterating through a `std::map` (or any standard associative container) and you want to erase elements, it is crucial to be aware of the iterator's validity after an erase operation. In your current loop: ```cpp map<string, SerialdMsg::SerialFunction_t>::iterator pm_it; for (pm_it = port_map.begin...
35,940
[ { "from": "human", "value": "In the following code I loop through a map and test if an element needs to be erased. Is it safe to erase the element and keep iterating or do I need to collect the keys in another container and do a second loop to call the erase()?\nmap<string, SerialdMsg::SerialFunction_t>::i...
Can I really and truly trust .NET to initialize fields (like ints, structs and the like)? And what if I still want to initialize those fields - what could be the repercussions?
Yes, you can trust .NET to initialize fields of classes and structs. In .NET, when you create a new instance of a class or struct, all its fields are automatically initialized to their default values. Here are some key points regarding field initialization in .NET: 1. **Default Initialization**: - For reference typ...
34,115
[ { "from": "human", "value": "Can I really and truly trust .NET to initialize fields (like ints, structs and the like)? And what if I still want to initialize those fields - what could be the repercussions?\n" }, { "from": "gpt", "value": "Yes, you can trust .NET to initialize fields of classes...
I'd like to log the call trace during certain points, like failed assertions, or uncaught exceptions.
To log the call trace during certain points in your application—such as when a failed assertion occurs or when an uncaught exception is thrown—you can use Python's built-in modules like `logging` and `traceback`. Below are examples of how to set this up in your code. ### 1. Logging Call Trace on Failed Assertions You...
33,945
[ { "from": "human", "value": "I'd like to log the call trace during certain points, like failed assertions, or uncaught exceptions.\n" }, { "from": "gpt", "value": "To log the call trace during certain points in your application—such as when a failed assertion occurs or when an uncaught exception...
In all of my other .net apps my build process (a mixture of nant and custom tasks) automatically updates the [AssemblyVersionAttribute] AssemblyInfo.cs with the current build number before the call to msbuild, stamping in the build number in the version number. I'm now working on my first BizTalk project and I'd like t...
Managing version numbers in BizTalk projects can indeed be tricky due to how references are handled in the IDE and the way that BizTalk projects build and deploy. Here's a structured approach to handle versioning more effectively in your BizTalk projects, allowing your build process to control the version numbers witho...
34,295
[ { "from": "human", "value": "In all of my other .net apps my build process (a mixture of nant and custom tasks) automatically updates the [AssemblyVersionAttribute] AssemblyInfo.cs with the current build number before the call to msbuild, stamping in the build number in the version number.\nI'm now working ...
struct elem { int i; char k; }; elem user; // compile error! struct elem user; // this is correct In the above piece of code we are getting an error for the first declaration. But this error doesn't occur with a C++ compiler. In C++ we don't need to use the keyword struct again and again. So why doesn't anyone upda...
Your question raises a variety of important points about language evolution, backward compatibility, and the differences between C and C++. Let's break down some of the key issues: ### 1. **Language Design Philosophy**: - **C Language Philosophy**: C was designed with a philosophy of simplicity and minimalism. The ...
27,507
[ { "from": "human", "value": "struct elem\n{\n int i;\n char k;\n};\nelem user; // compile error!\nstruct elem user; // this is correct\n\nIn the above piece of code we are getting an error for the first declaration. But this error doesn't occur with a C++ compiler. In C++ we don't need to use the keyword s...
I am looking for a tool to replace multiple lines through out a project. For example: #include "../DiscreteIO/Discrete.h" #include "../PCI/pci.h" #include "../Arinc429/ARINC429.h" with #include "../PCI/pci.h" #include "../DiscreteIO/DiscreteHW.h" #include "../DiscreteIO/Discrete.h" I have tried two tools that work fo...
It sounds like you've done your research and have a good understanding of the tools available for batch search and replace operations. Since you’re looking for alternatives to WildEdit and Actual Search and Replace, here are a few free or open-source tools and methods that may meet your needs: 1. **GNU `sed`**: Althou...
32,876
[ { "from": "human", "value": "I am looking for a tool to replace multiple lines through out a project. For example:\n#include \"../DiscreteIO/Discrete.h\"\n#include \"../PCI/pci.h\"\n#include \"../Arinc429/ARINC429.h\"\n\nwith\n#include \"../PCI/pci.h\"\n#include \"../DiscreteIO/DiscreteHW.h\"\n#include \".....
I have a page which dynamically loads a section of content via AJAX. I'm concerned that this means the content will not be found by search engines. To show you what I mean, the site is at http://www.gold09.net and the dynamic content is at /speakers.php - Normally no one would visit that second link, it's just loaded i...
To address your concern about dynamic AJAX-loaded content not being indexed by search engines, and the goal of allowing crawlers to access the content without showing the /speakers.php link in search results, here are some suggestions: ### 1. Use the `noindex` Meta Tag You can add a `noindex` meta tag to the `<head>`...
32,023
[ { "from": "human", "value": "I have a page which dynamically loads a section of content via AJAX. I'm concerned that this means the content will not be found by search engines.\nTo show you what I mean, the site is at http://www.gold09.net and the dynamic content is at /speakers.php - Normally no one would ...
Is there any way to find out what exceptions might be thrown by any method in .NET code? Ideally I want to see what might be thrown and choose which ones I want to handle. I guess I want the information you'd get from the throws clause in java. The situation is I'm doing a linq query on an xml document from the networ...
In .NET, there is no built-in way to directly see all the exceptions that a method might throw, as there is no equivalent to Java's `throws` clause. However, there are several strategies you can employ to determine the exceptions that may be thrown by a method, especially when working with LINQ queries and XML document...
32,625
[ { "from": "human", "value": "Is there any way to find out what exceptions might be thrown by any method in .NET code? Ideally I want to see what might be thrown and choose which ones I want to handle. I guess I want the information you'd get from the throws clause in java. \nThe situation is I'm doing a lin...
In my Java development I have had great benefit from the Jad/JadClipse decompiler. It made it possible to know why a third-party library failed rather than the usual guesswork. I am looking for a similar setup for C# and Visual Studio. That is, a setup where I can point to any class or variable in my code and get a cod...
To achieve the functionality you're looking for in C# and Visual Studio (especially versions 2005 and 2008), you can consider the following decompilation tools that integrate well with the IDE and allow you to browse and explore third-party assemblies similarly to how Jad/JadClipse works for Java. ### 1. **dotPeek** -...
32,446
[ { "from": "human", "value": "In my Java development I have had great benefit from the Jad/JadClipse decompiler. It made it possible to know why a third-party library failed rather than the usual guesswork.\nI am looking for a similar setup for C# and Visual Studio. That is, a setup where I can point to any ...
I keep getting an NHibernate.PersistentObjectException when calling session.Save() which is due to an uninitialized proxy passed to save(). If I fiddle with my cascade settings I can make it go away, but then child objects aren't being saved. The only other fix I have found is by adding the following to my DefaultSave...
The `NHibernate.PersistentObjectException` you are encountering typically happens when you attempt to save an uninitialized proxy object, which is not managed by the session. In NHibernate, proxies are used to represent lazily-loaded entities, and if they haven't been initialized (i.e., if their properties haven't been...
25,106
[ { "from": "human", "value": "I keep getting an NHibernate.PersistentObjectException when calling session.Save() which is due to an uninitialized proxy passed to save(). If I fiddle with my cascade settings I can make it go away, but then child objects aren't being saved.\nThe only other fix I have found is...
I'm implementing a blog with tags with some French characters. My question has to do with how to deal with spaces and unicode (utf-8) characters in the url. let's say I have a tag called: ohlàlà! and I have the following code in my tag cloud: <%= link_to h(tag.name.capitalize), { :controller => :blog, :action => :tag, ...
When dealing with URLs that include spaces and Unicode characters like French characters (e.g., `à`, `è`, `ç`, etc.), it’s important to properly encode these characters so that they are safely included in the URL. In a Rails application, the `link_to` helper can be used to create links, and Rails will automatically UR...
32,092
[ { "from": "human", "value": "I'm implementing a blog with tags with some French characters. My question has to do with how to deal with spaces and unicode (utf-8) characters in the url.\nlet's say I have a tag called: ohlàlà! and I have the following code in my tag cloud:\n<%= link_to h(tag.name.capitalize)...
A VBScript cannot edit the registry by default on Vista. How do I get elevation (even if the user has to do something when they run the script) so that the script can edit the registry? The error is: --------------------------- Windows Script Host --------------------------- Script: blah blah blah.vbs Line: 6 Char: ...
To allow a VBScript to modify the Windows registry in Windows Vista and later versions (like Windows 7, 8, 10, and 11), you need to run the script with elevated privileges. Here's a general approach you can take to achieve this: ### Method: Create a Batch File to Elevate the Script 1. **Create your VBScript**: Save y...
34,157
[ { "from": "human", "value": "A VBScript cannot edit the registry by default on Vista. How do I get elevation (even if the user has to do something when they run the script) so that the script can edit the registry?\nThe error is:\n---------------------------\nWindows Script Host\n--------------------------...
I've developed an application (C#) that currently sits on a a number of workstations. Each workstation accesses the same database (MS-SQL). I've been asked to port this to Citrix. Can anyone offer insight into documentation or suggestion of where someone would start with this? Is the application installed on the Ci...
Porting your C# application to a Citrix environment involves several steps and considerations. Here are some insights and guidance on getting started: ### 1. Understanding Citrix Environment Citrix is primarily used for delivering virtual applications and desktops to end-users. Here are some key points to understand:...
30,243
[ { "from": "human", "value": "I've developed an application (C#) that currently sits on a a number of workstations. Each workstation accesses the same database (MS-SQL). I've been asked to port this to Citrix. Can anyone offer insight into documentation or suggestion of where someone would start with this...
This is the XML I am creating in JavaScript: <root> <GradeValueSet> <GradeValueSetMaster SetId="0" SetName="wrwr" SetComments="werwrwr" mode="add"/> <DetailInfo> <ChildInfo Name="This sfsf" Weightage="24"/> <ChildInfo Name="45654" Weightage="67"/> </DetailInfo> </GradeValueSet> </root> I am sending this to a .a...
Your XML structure appears to be well-formed, as it contains a single root element (`<root>`) that contains child elements. However, the error message "root element missing" typically indicates that the XML parser did not find the expected root element in the input stream it is trying to read from. Here are a few step...
33,201
[ { "from": "human", "value": "This is the XML I am creating in JavaScript:\n<root>\n<GradeValueSet>\n<GradeValueSetMaster SetId=\"0\" SetName=\"wrwr\" SetComments=\"werwrwr\" mode=\"add\"/>\n<DetailInfo>\n <ChildInfo Name=\"This sfsf\" Weightage=\"24\"/>\n <ChildInfo Name=\"45654\" Weightage=\"67\"/>\n <...
I am using a WPF user control (tab control) to add tab items dynamically in the simplified code below: .... foreach (string id in ids) { TabControl.Items.Add(CreateTabItem(id)); } private TabItem CreateTabItem(string name) { StackPanel txtBlock = new TextBlock(); txtblock.Text = name; txtBlock.Horizont...
To make your WPF TabControl automatically adjust its height to show all tab items or to enable scrolling when the tab items exceed the available height, you can wrap your TabControl in a `ScrollViewer`. Here’s how to achieve both of your goals: ### 1. Automatically Adjusting the Height of the TabControl WPF controls ...
33,410
[ { "from": "human", "value": "I am using a WPF user control (tab control) to add tab items dynamically in the simplified code below:\n....\nforeach (string id in ids)\n{\n TabControl.Items.Add(CreateTabItem(id));\n}\n\nprivate TabItem CreateTabItem(string name)\n{\n StackPanel txtBlock = new TextBlock(...
In ASP.NET, I have an XML file (within my project) that I would like to deserialize. FileStream objects do not allow you to open a file via URL. What is the easiest way to open the file so that I can deserialize it?
In ASP.NET, if you want to deserialize an XML file from your project, you typically want to do so using a path that is accessible within your application. You can read the XML file as a stream and then deserialize it using classes such as `XmlSerializer`. Instead of using `FileStream`, you can use `StreamReader`, which...
32,026
[ { "from": "human", "value": "In ASP.NET, I have an XML file (within my project) that I would like to deserialize. FileStream objects do not allow you to open a file via URL. \nWhat is the easiest way to open the file so that I can deserialize it? \n" }, { "from": "gpt", "value": "In ASP.NET, i...
I have this code to give me a rollover on submit buttons, and I'm trying to make it more generic: $('.rollover').hover( function(){ // Change the input image's source when we "roll on" srcPath = $(this).attr("src"); srcPathOver = ??????? /*need to ...
Certainly! You can manipulate the `srcPath` variable to create the `srcPathOver` variable by using JavaScript string methods. Specifically, you can use the `replace()` method to replace the part of the filename before the file extension with the desired string. Here's how you can do it: 1. Use the `replace()` method ...
32,516
[ { "from": "human", "value": "I have this code to give me a rollover on submit buttons, and I'm trying to make it more generic:\n$('.rollover').hover(\n function(){ // Change the input image's source when we \"roll on\"\n srcPath = $(this).attr(\"src\");\n ...
I have a site I'm working on that has an event page. The owner wants to be able to edit the event page weekly. Would it be easier to teach the site owner how to edit this one page and upload it or use a CMS just for this one page?? Apart from a contact form that posts to an email addy, the rest of the site is static....
When deciding whether to teach the site owner how to edit the event page manually or to implement a content management system (CMS) for that purpose, consider the following factors: ### Manual Editing vs. CMS #### Manual Editing: - **Pros:** - Simplicity: If the event page is relatively simple, teaching the owner h...
31,494
[ { "from": "human", "value": "I have a site I'm working on that has an event page. The owner wants to be able to edit the event page weekly. Would it be easier to teach the site owner how to edit this one page and upload it or use a CMS just for this one page??\nApart from a contact form that posts to an e...
I've written a rails app that follows the regular directory structure (model code in models, controller code in controllers). But I'm now working on a new feature and for that I have written some (what I would call) "service" code. The new feature is to import some data into the system, at the moment it's two classes t...
You're not alone in your approach, and placing service objects in `app/services` is a common practice in Rails applications. This allows you to keep your code organized and separate concerns effectively. Your instinct to create a dedicated directory for service objects is sound, and it's a pattern many Rails developers...
34,645
[ { "from": "human", "value": "I've written a rails app that follows the regular directory structure (model code in models, controller code in controllers).\nBut I'm now working on a new feature and for that I have written some (what I would call) \"service\" code.\nThe new feature is to import some data into...
On my blog, I display in the right nav the 10 most popular articles in terms of page hits. Here's how I get that: SELECT * FROM entries WHERE is_published = 1 ORDER BY hits DESC, created DESC LIMIT 10 What I would like to do is show the top 10 in terms of page hits per day. I'm using MySQL. Is there a way I can do thi...
Your approach is quite close to what you need to calculate the average hits per day for each blog post. However, there are a few adjustments to ensure you handle cases where a blog post was created today or has very few hits properly. For example, you want to avoid division by zero errors. Here's a revised version of ...
34,171
[ { "from": "human", "value": "On my blog, I display in the right nav the 10 most popular articles in terms of page hits. Here's how I get that:\nSELECT *\nFROM entries\nWHERE is_published = 1\nORDER BY hits DESC, created DESC\nLIMIT 10\n\nWhat I would like to do is show the top 10 in terms of page hits per d...
This is what I'd like to do, but it doesn't seem possible: (edit: changed single to double quotes) function get_archives($limit, $offset) { $query = $this->db->query(" SELECT archivalie.id, archivalie.signature, type_of_source.description AS type_of_source_description, ...
The error you are encountering is due to the SQL syntax used in the `LIMIT` clause. In some database systems (like PostgreSQL), the correct way to use `LIMIT` with an offset is to use separate `LIMIT` and `OFFSET` clauses instead of a combined format. Here’s how you can modify your SQL query to use the correct syntax...
28,121
[ { "from": "human", "value": "This is what I'd like to do, but it doesn't seem possible:\n(edit: changed single to double quotes)\nfunction get_archives($limit, $offset) \n{\n $query = $this->db->query(\"\n SELECT archivalie.id, \n archivalie.signature, \n type_of_sou...
I like to use IPython's zope profile to inspect my Plone instance, but a few annoying permissions differences come up compared to inserting a breakpoint and hitting it with the admin user. For example, I would like to iterate over the content objects in an unpublished testing folder. This query will return no results i...
When using IPython with Plone's Zope profile, you may encounter permission issues because the default context may not have sufficient permissions to access certain content, especially if it is unpublished or if the user associated with the shell is not an admin user. Here are a few approaches you can take to authentic...
34,430
[ { "from": "human", "value": "I like to use IPython's zope profile to inspect my Plone instance, but a few annoying permissions differences come up compared to inserting a breakpoint and hitting it with the admin user.\nFor example, I would like to iterate over the content objects in an unpublished testing f...
My organization is considering using Jabber as an agnostic device to device to application messaging protocol. Does anyone know of the best practice existing Microsoft competitor to Jabber? Or, an emerging competitor? And, if so, a good URL reference to get a jump start? Website for Jabber: http://www.jabber.org/web/...
Jabber, also known as XMPP (Extensible Messaging and Presence Protocol), is indeed a flexible and widely used protocol for messaging and presence. If your organization is exploring alternatives, especially in the context of Microsoft products, there are several options you can consider. ### Best Practices and Competi...
31,667
[ { "from": "human", "value": "My organization is considering using Jabber as an agnostic device to device to application messaging protocol.\nDoes anyone know of the best practice existing Microsoft competitor to Jabber? Or, an emerging competitor? And, if so, a good URL reference to get a jump start?\nWeb...
I'm looking for some sample code that will sort the list items in an HTML list by alphabetical order. Can anyone help? Here is a sample list for people to work with: <ul class="alphaList"> <li>apples</li> <li>cats</li> <li>bears</li> </ul>
Certainly! You can use JavaScript to sort the items in your HTML list in alphabetical order. Below is a sample code snippet that does just that: ```html <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Sort List Alp...
34,849
[ { "from": "human", "value": "I'm looking for some sample code that will sort the list items in an HTML list by alphabetical order. Can anyone help?\nHere is a sample list for people to work with:\n<ul class=\"alphaList\">\n <li>apples</li>\n <li>cats</li>\n <li>bears</li>\n</ul>\n\n" }, { ...
What are the ways by which we can reduce the size of the HTML Response sent by an asp.net application? I am using Controls which are not owned by me and it produces output with white spaces. I am interested in Minifying the entire HTML output of the page just like how google does (View source www.google.com) to improve...
Reducing the size of the HTML response in an ASP.NET application can significantly improve page load times and overall performance. If you have control over the application and are using third-party controls that produce extra whitespace, minifying the HTML output is a good approach. Here are several strategies and uti...
26,560
[ { "from": "human", "value": "What are the ways by which we can reduce the size of the HTML Response sent by an asp.net application?\nI am using Controls which are not owned by me and it produces output with white spaces. I am interested in Minifying the entire HTML output of the page just like how google do...
is it possible to throw a custom error message to a ThrowActivity, in windows workflow foundation? eg. Imagine i want to throw this exception, in my WF :- CutomException("This is my custom error message", myNumber, myObect); cheers :)
Yes, in Windows Workflow Foundation (WF), you can throw a custom error message using a `ThrowActivity`. You can create a custom exception class and then use it in your workflow to throw an exception with your desired error message and additional parameters. Here's a step-by-step guide on how to achieve this: ### Step...
34,931
[ { "from": "human", "value": "is it possible to throw a custom error message to a ThrowActivity, in windows workflow foundation?\neg. Imagine i want to throw this exception, in my WF :-\nCutomException(\"This is my custom error message\", myNumber, myObect);\n\ncheers :)\n" }, { "from": "gpt", "v...
I'm developing a web app using Java servlet to access Mysql db, how can I get the number of connections to my DB that is currently open ? Edit : I tried "show processlist", it showed me : 2695159, but that's not right, I'm just developing this new project, I'm the only user, couldn't have that many processes running, w...
To get the number of active connections to your MySQL database specifically from your web app, you will need to implement a way to track those connections yourself. The MySQL `SHOW PROCESSLIST` command returns information about all connections to the server, not just those from your specific application. However, you c...
29,169
[ { "from": "human", "value": "I'm developing a web app using Java servlet to access Mysql db, how can I get the number of connections to my DB that is currently open ?\nEdit :\nI tried \"show processlist\", it showed me : 2695159, but that's not right, I'm just developing this new project, I'm the only user,...
Is there explicit support for Single Table Inheritance in Django? Last I heard, the feature was still under development and debate. Are there libraries/hacks I can use in the meantime to capture the basic behavior? I have a hierarchy that mixes different objects. The canonical example of a corporation structure with a...
As of my last update, Django does not have built-in support for Single Table Inheritance (STI) as seen in some other ORMs. However, there are ways to implement similar behavior using Django's existing features, such as abstract models, multi-table inheritance, or third-party libraries. ### Options for Implementing Sin...
28,318
[ { "from": "human", "value": "Is there explicit support for Single Table Inheritance in Django? Last I heard, the feature was still under development and debate. \nAre there libraries/hacks I can use in the meantime to capture the basic behavior? I have a hierarchy that mixes different objects. The canonical...
Knuth recently objected to 64-bit systems, saying that for programs which fit in 4 gigs of memory, "they effectively throw away half of the cache" because the pointers are twice as big as on a 32-bit system. My question is: can this problem be avoided by installing a 32-bit operating system on a 64-bit machine? And a...
Knuth's observation about 64-bit systems relates to the fact that pointer sizes double from 32 bits to 64 bits, which can lead to increased memory usage for structures that heavily utilize pointers. When a program uses more memory to store pointers, it might reduce the effective cache utilization, as fewer data element...
30,209
[ { "from": "human", "value": "Knuth recently objected to 64-bit systems, saying that for programs which fit in 4 gigs of memory, \"they effectively throw away half of the cache\" because the pointers are twice as big as on a 32-bit system.\nMy question is: can this problem be avoided by installing a 32-bit ...
I want to insert something into a STL list in C++, but I only have a reverse iterator. What is the usual way to accomplish this? This works: (of course it does) std::list<int> l; std::list<int>::iterator forward = l.begin(); l.insert(forward, 5); This doesn't work: (what should I do instead?) std::list<int> l; std::li...
In C++, when you have a reverse iterator for a `std::list`, you cannot directly use it with the `insert` function as you would with a normal iterator. This is because the `insert` function expects a forward iterator, and the reverse iterator points to the element preceding the position you would like to insert. To ins...
34,542
[ { "from": "human", "value": "I want to insert something into a STL list in C++, but I only have a reverse iterator. What is the usual way to accomplish this?\nThis works: (of course it does)\nstd::list<int> l;\nstd::list<int>::iterator forward = l.begin();\nl.insert(forward, 5);\n\nThis doesn't work: (what ...
The mouse hovers over an element and a tip appears. The tip overflows the page, triggering a scrollbar, which changes the layout just enough so that the underlying element that triggered the tip is no longer under the mouse pointer, so the tip goes away. The tip goes away, so the scrollbar goes away, and now the mous...
The issue you're experiencing with tooltips causing scrollbars, which in turn causes the tooltip to disappear, can indeed be frustrating. A good solution would involve calculating the dimensions of the tooltip and the viewport before displaying it, ensuring that it doesn't exceed the visible area of the page and trigge...
30,068
[ { "from": "human", "value": "The mouse hovers over an element and a tip appears. The tip overflows the page, triggering a scrollbar, which changes the layout just enough so that the underlying element that triggered the tip is no longer under the mouse pointer, so the tip goes away.\nThe tip goes away, so...
I am writing multi-thread socket chat in C++Builder 2009. It is almost complete in accordance with what I need to do but I have a little problem. I need to pass the TMemo* pointer into CreateThread WinAPI function which upcasts it to void*. I tryed this way: HANDLE xxx = MemoChat->Handle; hNetThread = CreateThread(NULL...
When working with threads in C++, especially in the context of a GUI application, passing a pointer to a GUI component directly to a thread can lead to problems. The primary concern is that GUI components are not thread-safe, meaning that accessing them from a thread other than the one that created them (usually the ma...
32,939
[ { "from": "human", "value": "I am writing multi-thread socket chat in C++Builder 2009.\nIt is almost complete in accordance with what I need to do but I have a little problem.\nI need to pass the TMemo* pointer into CreateThread WinAPI function which upcasts it to void*.\nI tryed this way:\nHANDLE xxx = Mem...
We currently have a web application loading a Spring application context which instantiates a stack of business objects, DAO objects and Hibernate. We would like to share this stack with another web application, to avoid having multiple instances of the same objects. We have looked into several approaches; exposing the...
Hi Nils, It sounds like you're dealing with a classic scenario of wanting to share a common service layer (including Hibernate) among multiple web applications while minimizing redundancy and avoiding issues with caching and performance. Here are several lightweight strategies to consider for sharing your Spring-based...
33,382
[ { "from": "human", "value": "We currently have a web application loading a Spring application context which instantiates a stack of business objects, DAO objects and Hibernate. We would like to share this stack with another web application, to avoid having multiple instances of the same objects.\nWe have lo...
Is there a way to edit the log message of a certain revision in Subversion? I accidentally wrote the wrong filename in my commit message which could be confusing later. I've seen How do I edit an incorrect commit message in Git?, but the solution to that question doesn't seem to be similar for Subversion (according to ...
In Subversion (SVN), there is a way to change the commit message of a specific revision, but it typically requires administrative privileges on the repository. To edit a commit message in Subversion, you can use the `svn propedit` command to change the `svn:log` property of a specific revision. Here's how you can do i...
34,836
[ { "from": "human", "value": "Is there a way to edit the log message of a certain revision in Subversion? I accidentally wrote the wrong filename in my commit message which could be confusing later.\nI've seen How do I edit an incorrect commit message in Git?, but the solution to that question doesn't seem t...
When a form loads, the code needs to do things like setup datagrids, comboboxes, set the title, etc. I've tended to always use the load event rather than the new (constructor). Are there any guidelines for which one is best for which activities?
When deciding whether to use the Load event or the constructor for initializing a form, there are some guidelines to consider based on best practices and the typical lifecycle of a form. Here’s a breakdown of both approaches and their suitable use cases: ### Constructor **Use Cases:** 1. **Basic Initialization:** ...
30,927
[ { "from": "human", "value": "When a form loads, the code needs to do things like setup datagrids, comboboxes, set the title, etc. I've tended to always use the load event rather than the new (constructor). Are there any guidelines for which one is best for which activities?\n" }, { "from": "gpt", ...
We have an app in AppStore Bust~A~Spook we had an issue with. When you tap the screen we use CALayer to find the position of all the views during their animation and if you hit one we start a die sequence. However, there is a noticeable delay, it appears as if the touches are buffered and we we receive the event to l...
If you're experiencing lag in touch response when tapping on views in your app, it's essential to analyze how touch events are being handled. Here are several suggestions to help you address the lag and improve responsiveness: ### 1. Optimize Touch Handling Make sure you are handling touches as efficiently as possibl...
33,850
[ { "from": "human", "value": "We have an app in AppStore Bust~A~Spook we had an issue with. When you tap the screen we use CALayer to find the position of all the views during their animation and if you hit one we start a die sequence. However, there is a noticeable delay, it appears as if the touches are ...
I'd like to use the ADO.NET Entity Framework for data access, extend its objects for my business logic, and bind those objects to controls in my UI. As explained in the answers to another question, I cannot extend ADO.NET Entity Framework objects with partial classes and use my custom methods in LINQ queries. ADO.NET E...
When using ADO.NET Entity Framework, it can indeed be a challenge to maintain clear separation between your data access layer and your business logic layer, especially since EF entity classes cannot be extended with custom methods in a way that allows those methods to be used directly in LINQ queries. To avoid the iss...
31,097
[ { "from": "human", "value": "I'd like to use the ADO.NET Entity Framework for data access, extend its objects for my business logic, and bind those objects to controls in my UI.\nAs explained in the answers to another question, I cannot extend ADO.NET Entity Framework objects with partial classes and use my...
Is it possible to use CPython to develop Adobe Flash based applications?
No, it is not possible to use CPython to develop Adobe Flash-based applications. Adobe Flash primarily utilized ActionScript, which is a programming language specifically designed for creating interactive content within the Flash environment. CPython is the reference implementation of the Python programming language,...
36,152
[ { "from": "human", "value": "Is it possible to use CPython to develop Adobe Flash based applications?\n" }, { "from": "gpt", "value": "No, it is not possible to use CPython to develop Adobe Flash-based applications. Adobe Flash primarily utilized ActionScript, which is a programming language spe...
Let's say there is a report to compare charges with adjustments that outputs to excel, such that each row has the following fields: Account Number charge date Original item number Adjusted Item number Original Qty Adjusted Qty Original amount Adjusted amount Original Post date Adjusted Post date I need to help a user...
To create a view in Excel that compares the original and adjusted records in two rows as you described, you can use Excel's built-in features like formulas, and possibly a bit of manual layout work to achieve the desired format. Here’s how you can do it without using VBA: ### Step-by-Step Guide 1. **Data Preparation*...
30,290
[ { "from": "human", "value": "Let's say there is a report to compare charges with adjustments that outputs to excel, such that each row has the following fields:\n\nAccount Number\ncharge date\nOriginal item number\nAdjusted Item number\nOriginal Qty\nAdjusted Qty\nOriginal amount\nAdjusted amount\nOriginal ...
what's the quickest way to extract a 5 digit number from a string in c#. I've got string.Join(null, System.Text.RegularExpressions.Regex.Split(expression, "[^\\d]")); Any others?
Using regular expressions in C# is indeed a common and efficient way to extract numbers from a string. However, there are various methods to extract a 5-digit number specifically. Below are a couple of alternatives, including improvements and other approaches: ### 1. Using Regular Expressions If you want to ensure yo...
32,011
[ { "from": "human", "value": "what's the quickest way to extract a 5 digit number from a string in c#. \nI've got \nstring.Join(null, System.Text.RegularExpressions.Regex.Split(expression, \"[^\\\\d]\"));\n\nAny others?\n" }, { "from": "gpt", "value": "Using regular expressions in C# is indeed a ...
In cmd.exe, I can execute the command "copy c:\hello.txt c:\hello2.txt" and it worked fine. But in my C program, I ran this piece of code and got the following error: #include <iostream> using namespace std; int main() { system("copy c:\hello.txt c:\hello2.txt"); system("pause"); return 0; } Output: The...
The issue you're encountering is related to how backslashes (`\`) are treated in string literals in C and C++. In C/C++, the backslash is an escape character, which means it is used to introduce special character sequences (like `\n` for newline). In your command string, the `\h` sequence is invalid and can cause unexp...
36,435
[ { "from": "human", "value": "In cmd.exe, I can execute the command \"copy c:\\hello.txt c:\\hello2.txt\" and it worked fine.\nBut in my C program, I ran this piece of code and got the following error:\n#include <iostream>\n\nusing namespace std;\n\nint main()\n{\n system(\"copy c:\\hello.txt c:\\hello2.t...
I maintain an application which, during the course of two years, has constantly required new hardware to be even usable, due to the amount of new users / new data inserted. However, justifying the investiment is sometimes very hard to do. I started to wonder - how can I establish the maximum number of users a web appli...
To establish the maximum number of users a web application can support, you can use various performance testing tools and methodologies. While JMeter is a popular option, it's true that setting up complex scenarios can be challenging, especially when dealing with file transfers and decision trees. Here are some alterna...
28,447
[ { "from": "human", "value": "I maintain an application which, during the course of two years, has constantly required new hardware to be even usable, due to the amount of new users / new data inserted. However, justifying the investiment is sometimes very hard to do.\nI started to wonder - how can I establi...
So today I had to move some tables with data from an MS Access database into XML to be used in a web application. So I thought it would be an easy process to define the table structure as an XSD file in Visual Studio, then load in the data (for the sake of simplicity, lets say I would type it in). Well for the life o...
Visual Studio does provide some support for working with XML schemas (XSD) and XML files, but it might not offer the level of graphical support you are looking for when it comes to editing XML data in a grid-like interface. ### Option 1: Using Visual Studio While Visual Studio allows you to create and manage XSD files...
33,180
[ { "from": "human", "value": "So today I had to move some tables with data from an MS Access database into XML to be used in a web application. So I thought it would be an easy process to define the table structure as an XSD file in Visual Studio, then load in the data (for the sake of simplicity, lets say ...
I'm not looking for the whole ACO-ARO implementation... I just want to use Auth, and check against the user's role.... What do I put where in order to simply deny users from a given controller unless they have a certain role. I'm trying to use the $this->Auth->authorize = 'controller'; ... but I don't even know where ...
To restrict access to certain actions in a controller based on user roles in a CakePHP application using the Auth component, you'll want to implement authorization using the `Auth` component and set up a policy to check user roles. Here's a simplified way to do this in your controller: ### Step 1: Configure Auth in t...
31,313
[ { "from": "human", "value": "I'm not looking for the whole ACO-ARO implementation... I just want to use Auth, and check against the user's role....\nWhat do I put where in order to simply deny users from a given controller unless they have a certain role.\nI'm trying to use the $this->Auth->authorize = 'co...
I've set up multiple ssl sites on iis using Servier Bindings as per this article: http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/8d9f2a8f-cd23-448c-b2c7-f4e87b9e2d2c.mspx?mfr=true I have two different ssl certs for the two sites installed but when I browse to either site I get the same certi...
Yes, you can configure multiple SSL sites on IIS without requiring a wildcard certificate, but there are some steps to ensure that each site uses the correct SSL certificate. Here’s a general guideline on how to accomplish this: ### Step 1: Ensure Unique Host Headers Make sure that each site has a unique hostname in t...
33,250
[ { "from": "human", "value": "I've set up multiple ssl sites on iis using Servier Bindings as per this article: http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/8d9f2a8f-cd23-448c-b2c7-f4e87b9e2d2c.mspx?mfr=true\nI have two different ssl certs for the two sites installed but when I ...
How can one get Visual Studio 2005/2008 to reference assemblies in the 64-bit GAC instead of the 32-bit GAC? We are settin the target platfom to x64 and the compiler is throwing the error of Error 2 Warning as Error: Assembly generation -- Referenced assembly 'System.Data.dll' targets a different processor Common Erro...
To get Visual Studio 2005/2008 to reference assemblies in the 64-bit GAC instead of the 32-bit GAC, you have a few options. However, it is important to note that Visual Studio 2005/2008 may have limitations, as it was primarily designed for targeting 32-bit environments. Here are some steps you can try to resolve the i...
32,561
[ { "from": "human", "value": "How can one get Visual Studio 2005/2008 to reference assemblies in the 64-bit GAC instead of the 32-bit GAC? We are settin the target platfom to x64 and the compiler is throwing the error of\n\nError 2 Warning as Error: Assembly generation -- Referenced assembly 'System.Data.dll...
When developing custom ecommerce solutions, which "off the shelf" .NET based shipping components have you had luck with? It absolutely must give real-time shipping quotes and be easily integrated into a ASP.NET website. Ideally I'd like it to support most of the common US domestic shipping companies (UPS, FedEx, USP...
When developing custom eCommerce solutions in ASP.NET and looking for shipping components that offer real-time shipping quotes, there are several options that you might find useful. Here are some popular .NET-based shipping components that support major US domestic shipping carriers like UPS, FedEx, and USPS: 1. **Shi...
31,389
[ { "from": "human", "value": "When developing custom ecommerce solutions, which \"off the shelf\" .NET based shipping components have you had luck with? \nIt absolutely must give real-time shipping quotes and be easily integrated into a ASP.NET website. Ideally I'd like it to support most of the common US ...
I'm currently using subversion to manage my source code and I've come to a point where I need to brand the software I'm working on for a client. All the branding is handled in the project resources so changing the look for a client is very simple. What I'm running into a problem with is maintaining the branded version ...
Maintaining multiple branded versions of software while using a version control system like Subversion can indeed present challenges. However, there are several strategies you can use to manage your branded resources effectively without losing the ability to merge changes from the trunk easily. Here are a few approache...
31,032
[ { "from": "human", "value": "I'm currently using subversion to manage my source code and I've come to a point where I need to brand the software I'm working on for a client. All the branding is handled in the project resources so changing the look for a client is very simple. What I'm running into a problem...
I have a report in MS Access where the underlying data in the tables changes irregularly. I'd like the report to reflect these changes automatically, either by reloading the form say every 10 seconds or either the report gets a notification about the changes and shows the new data. Is this possible?
In Microsoft Access, there are a couple of ways to ensure that your report reflects changes in the underlying data. However, Access does not have built-in functionality for real-time updates or automatic refreshing of reports in the same way that other applications (like dashboards) might. That said, here are some opti...
31,913
[ { "from": "human", "value": "I have a report in MS Access where the underlying data in the tables changes irregularly. I'd like the report to reflect these changes automatically, either by reloading the form say every 10 seconds or either the report gets a notification about the changes and shows the new da...
I'm trying to learn GNUMake for a small project I'm working on. So far, even the "basic" tutorials seem pretty rough and I've yet to make sense of the makefile syntax. Does anyone have some good resources for an absolute beginner to get familiar with GNUMake?
Absolutely! Learning GNU Make can be a bit daunting at first, but once you get the hang of it, it can be a powerful tool for managing your builds. Here are some resources that are well-suited for beginners: 1. **Official GNU Make Manual**: - The official manual is quite comprehensive and includes examples, syntax e...
33,974
[ { "from": "human", "value": "I'm trying to learn GNUMake for a small project I'm working on. So far, even the \"basic\" tutorials seem pretty rough and I've yet to make sense of the makefile syntax.\nDoes anyone have some good resources for an absolute beginner to get familiar with GNUMake?\n" }, { ...
If I have a list of data in a text file seperated by a new line, is there a way to append something to the start, then the data, then append something else then the data again? EG a field X would become new X = X; Can you do this with bash or sed or just unix tools like cut? EDIT: I am trying to get "ITEM_SITE_ID :{$ro...
Yes, you can achieve this using `awk` or `sed`. The issue you're encountering is due to the quoting of the variable `$1` inside single quotes, which prevents it from being evaluated correctly in your command. Here’s a way to do it with `awk` to get the desired format: ```bash awk '{ print $1 " : {:" $1 "['$1']}" }' y...
34,344
[ { "from": "human", "value": "If I have a list of data in a text file seperated by a new line, is there a way to append something to the start, then the data, then append something else then the data again?\nEG a field X would become new X = X;\nCan you do this with bash or sed or just unix tools like cut?\n...
I have a master page that contains an ASP.NET server side Menu control (System.Web.UI.WebControls.Menu) I am using the CSSFriendly adapters from here http://www.asp.net/CSSAdapters/Menu.aspx and they do make the rendered HTML much cleaner however I am still getting inline styles output into the HEAD element in the HTML...
The inline styles that you are seeing are indeed generated by ASP.NET Web Forms for the `Menu` control. They are part of the control's rendering mechanism and can be attributed to how ASP.NET handles visibility and layout for these server controls. If you're using CSSFriendly adapters, you might not need these inline s...
30,982
[ { "from": "human", "value": "I have a master page that contains an ASP.NET server side Menu control (System.Web.UI.WebControls.Menu)\nI am using the CSSFriendly adapters from here\nhttp://www.asp.net/CSSAdapters/Menu.aspx\nand they do make the rendered HTML much cleaner however I am still getting inline sty...
example: I want to see if array[5] holds a value or is empty.
In many programming languages, you can check whether an array element holds a value or is empty by evaluating the element at the specified index. Below are examples for a few popular programming languages. ### JavaScript ```javascript let array = [1, 2, 3, undefined, null, 5]; // Check if array[5] holds a value or is...
33,888
[ { "from": "human", "value": "example:\nI want to see if array[5] holds a value or is empty.\n" }, { "from": "gpt", "value": "In many programming languages, you can check whether an array element holds a value or is empty by evaluating the element at the specified index. Below are examples for a ...
i noticed that paypal displays a very different favicon, one that's not just a simple 16x16 icon and is lengthy? anyone can teach me?
PayPal's favicon, like many modern favicons, can include multiple sizes and formats to adapt to various devices and browsers. The longer or more complex appearance may come from the way it handles favicons for different contexts, such as browser tabs, bookmarks, and mobile devices. Here are some steps and tips on how ...
31,796
[ { "from": "human", "value": "i noticed that paypal displays a very different favicon,\none that's not just a simple 16x16 icon and is lengthy?\nanyone can teach me?\n" }, { "from": "gpt", "value": "PayPal's favicon, like many modern favicons, can include multiple sizes and formats to adapt to va...
In another question, Mark speaks highly of IDEs, saying "some people still just dont know "why" they should use one...". As someone who uses vim for programming, and works in an environment where most/all of my colleagues use either vim or emacs for all of their work, what are the advantages of IDEs? Why should I use...
Using an Integrated Development Environment (IDE) has several advantages that can enhance productivity, especially for specific types of development tasks or projects. Here are some compelling reasons to consider using an IDE: 1. **Integrated Tools**: IDEs often come with built-in tools such as debuggers, code profile...
32,124
[ { "from": "human", "value": "In another question, Mark speaks highly of IDEs, saying \"some people still just dont know \"why\" they should use one...\". As someone who uses vim for programming, and works in an environment where most/all of my colleagues use either vim or emacs for all of their work, what ...
Hmm. I'm trying to deploy a web service to a new server and there is no ASP.NET tab. I've tried running aspnet_regiis from ASP.NET 2.0 directory but this doesn't seem to work. Any ideas anyone?
If you're not seeing the ASP.NET tab in your server's Internet Information Services (IIS) manager, it may be due to a few reasons. Here are some troubleshooting steps you can follow: 1. **Verify IIS Installation**: Ensure that IIS is installed correctly and the appropriate features for ASP.NET are enabled. You can ...
34,356
[ { "from": "human", "value": "Hmm. I'm trying to deploy a web service to a new server and there is no ASP.NET tab. I've tried running aspnet_regiis from ASP.NET 2.0 directory but this doesn't seem to work. Any ideas anyone?\n" }, { "from": "gpt", "value": "If you're not seeing the ASP.NET tab in...
How can I move items from one list box control to another listbox control using JavaScript in ASP.NET?
To move items between two list boxes using JavaScript in an ASP.NET application, you can follow these steps: 1. **Create the ASP.NET Web Form**: You'll need two list boxes (`<select>` elements) and buttons to move items between them. 2. **Add JavaScript Functions**: Implement JavaScript functions to handle the moving...
29,865
[ { "from": "human", "value": "How can I move items from one list box control to another listbox control using JavaScript in ASP.NET?\n" }, { "from": "gpt", "value": "To move items between two list boxes using JavaScript in an ASP.NET application, you can follow these steps:\n\n1. **Create the ASP...
I would like to create a link between a winMo device and a server, so that they can pass information back and forth to each other. I actually don't really know where to start, I've had SOAP, RPC and creating a TCP link suggested to me. If someone could provide a link to an example that would be great. Thanks! Thanks fo...
Creating a communication link between a Windows Mobile (WinMo) device and a server can be approached in several ways, depending on your requirements and preferences. Given your updates and considerations, here's a breakdown of your options along with some guidance on getting started: ### 1. Web Services (SOAP/REST) *...
32,297
[ { "from": "human", "value": "I would like to create a link between a winMo device and a server, so that they can pass information back and forth to each other. I actually don't really know where to start, I've had SOAP, RPC and creating a TCP link suggested to me. If someone could provide a link to an examp...
Can you use Windows Workflow and Compact Framework 3.5? I've just got an evaluation version of Visual Studio 2008 and I've had a look around but can't work out quickly if there is a way of doing this. I just don't want to waste anymore time looking around if there is no way of doing it.
Windows Workflow Foundation (WF) and the .NET Compact Framework (CF) are two different technologies that serve different purposes. 1. **Windows Workflow Foundation**: This is a framework for building workflow-enabled applications on the .NET Framework. It allows developers to define, execute, and manage workflows. 2...
35,952
[ { "from": "human", "value": "Can you use Windows Workflow and Compact Framework 3.5?\nI've just got an evaluation version of Visual Studio 2008 and I've had a look around but can't work out quickly if there is a way of doing this.\nI just don't want to waste anymore time looking around if there is no way of...
In building an ASP.NET 3.5 WAP, I'm always frustrated by the feeling that no matter how I "isolate" or "encapsulate" bits of logic or UI I'm still going to bring down the whole site any time I need to update a single line of code. I may be misunderstanding how ASP.NET handles changes in the "bin" directory, but given t...
You're right to be concerned about the application domain unloading in ASP.NET, especially when you're working with Web Application Projects (WAPs) in ASP.NET 3.5. Unlike Web Site Projects (WSPs), which are more flexible in terms of hot-reloading changes without requiring a full application restart, WAPs compile all co...
32,936
[ { "from": "human", "value": "In building an ASP.NET 3.5 WAP, I'm always frustrated by the feeling that no matter how I \"isolate\" or \"encapsulate\" bits of logic or UI I'm still going to bring down the whole site any time I need to update a single line of code. I may be misunderstanding how ASP.NET handle...
Prefer responses via php or ROR if possible! Example: The slide widget at www.slide.com can be deployed anywhere on the web. But the slide developers have centralized edit capabilities to these widgets. A change to the widget core, will update across all installed widgets. Can this be done with an entire...
Yes, it is possible to create a website engine that allows centralized control and updates while being deployed on individual customer servers. This kind of architecture is often referred to as a "multi-tenant" system, where a single instance of the software serves multiple clients, yet allows for individual customizat...
31,213
[ { "from": "human", "value": "Prefer responses via php or ROR if possible!\nExample:\n\nThe slide widget at www.slide.com can\n be deployed anywhere on the web. But\n the slide developers have\n centralized edit capabilities to these\n widgets. A change to the widget core,\n will update across all inst...
I've heard of "error" when using floating point variables. Now I'm trying to solve this puzzle and I think I'm getting some rounding/floating point error. So I'm finally going to figure out the basics of floating point error. What is a simple example of floating point/rounding error (preferably in C++) ? Edit: For e...
Floating point errors can indeed occur in calculations involving probabilities and combinations, particularly when dealing with operations that involve exponentiation and combinatorial functions. In your example, calculating the probability of exactly 2 successes in 10 independent trials (where the probability of succe...
29,417
[ { "from": "human", "value": "I've heard of \"error\" when using floating point variables. Now I'm trying to solve this puzzle and I think I'm getting some rounding/floating point error. So I'm finally going to figure out the basics of floating point error.\nWhat is a simple example of floating point/round...
A quick search gave me this announcement of Parrot DBDI from January 2004 and a dbdi-dev mailing list which appears to be long dead. Is Parrot DBDI still being developed? Is anyone working on a different database API or interface for Parrot?
As of my last knowledge update in October 2023, Parrot DBDI (Database Driver Interface) has not seen active development for a long time. The Parrot virtual machine itself has largely fallen out of favor, and many of its associated projects, including DBDI, have also seen minimal activity since the early 2010s. The Par...
36,744
[ { "from": "human", "value": "A quick search gave me this announcement of Parrot DBDI from January 2004 and a dbdi-dev mailing list which appears to be long dead. Is Parrot DBDI still being developed? Is anyone working on a different database API or interface for Parrot?\n" }, { "from": "gpt", "v...
I got a little problem I can't figure out. I have a server side MarshalByRefObject that I'm trying to wrap a transparent proxy around on the client side. Here's the setup: public class ClientProgram { public static void Main( string[] args ) { ITest test = (ITest)Activator.GetObject( typeof( ITest ), "http:...
The issue you're encountering with `ExecuteMessage` is due to the fact that you're trying to invoke a method on a `MarshalByRefObject` from a proxy that is not running in the native context of that object. The error message indicates that `ExecuteMessage` can only be called from within the context of the `MarshalByRefO...
29,779
[ { "from": "human", "value": "I got a little problem I can't figure out. I have a server side MarshalByRefObject that I'm trying to wrap a transparent proxy around on the client side. Here's the setup:\npublic class ClientProgram {\n public static void Main( string[] args ) {\n ITest test = (ITest)...
I've seen several responses to questions asking for IDEs where text editors were suggested and vice-versa. That makes me think that people treat them as the same thing, where I draw clear distinctions. How do you define "text editor" and "IDE"? Do you see a difference between the two tools? Note that I accepted an an...
The distinction between a text editor and an integrated development environment (IDE) is significant, as they serve different purposes and offer varying functionalities. Here’s how I define each: ### Text Editor A text editor is a software application that allows users to create and edit plain text files. Key characte...
27,131
[ { "from": "human", "value": "I've seen several responses to questions asking for IDEs where text editors were suggested and vice-versa. That makes me think that people treat them as the same thing, where I draw clear distinctions.\n\nHow do you define \"text editor\" and \"IDE\"?\nDo you see a difference be...
I have a .Net CF 2.0 application and am using log4net to log errors. I get a stack trace, but it doesn't have any line numbers. I noticed that it doesn't appear to deploy the pdb file to the device, so I tried to manually place it in the same directory as the exe. But that didn't help.
When working with a .NET Compact Framework (CF) application and using log4net for logging, it's common to encounter issues with obtaining stack traces that include line numbers. Here are some steps you can take to resolve the issue: 1. **Ensure PDB Files Are Generated**: First, make sure that the PDB (Program Database...
31,759
[ { "from": "human", "value": "I have a .Net CF 2.0 application and am using log4net to log errors. I get a stack trace, but it doesn't have any line numbers. I noticed that it doesn't appear to deploy the pdb file to the device, so I tried to manually place it in the same directory as the exe. But that di...
How do I know which files and registry keys an application is trying to access?
To monitor which files and registry keys an application is trying to access, you can use several tools and methods. Here are some of the most effective: ### 1. **Process Monitor (ProcMon)** Process Monitor is a powerful monitoring tool from Microsoft that allows you to see real-time file system, registry, and process/...
29,512
[ { "from": "human", "value": "How do I know which files and registry keys an application is trying to access?\n" }, { "from": "gpt", "value": "To monitor which files and registry keys an application is trying to access, you can use several tools and methods. Here are some of the most effective:\n...
I'm writing a mapping app that uses a Canvas for positioning elements. For each element I have to programatically convert element's Lat/Long to the canvas' coordinate, then set the Canvas.Top and Canvas.Left properties. If I had a 360x180 Canvas, can I convert the coordinates on the canvas to go from -180 to 180 rathe...
To achieve the conversion from latitude and longitude coordinates to canvas coordinates with the requirements you specified, you can follow these steps: 1. **Normalize the Latitude and Longitude**: Normalize the longitude to a range from -180 to 180 and the latitude to a range from -90 to 90. 2. **Map the normaliz...
29,163
[ { "from": "human", "value": "I'm writing a mapping app that uses a Canvas for positioning elements. For each element I have to programatically convert element's Lat/Long to the canvas' coordinate, then set the Canvas.Top and Canvas.Left properties.\nIf I had a 360x180 Canvas, can I convert the coordinates ...
One of our customers wants to be able to enter a date with only 2 digits for the year component. The date will be in the past, so we want it to work for the previous century if the 2 digit year is after the current year, but work for the current century if the 2 digit year is equal to or less than the current year. as ...
Your current solution works, but it can be simplified for better readability and maintainability. You can avoid the use of `StringUtils` and `NumberUtils` by using standard Java methods and reduce the overall complexity. Here's a cleaner approach to achieve the same functionality: ```java import java.util.Calendar; p...
32,764
[ { "from": "human", "value": "One of our customers wants to be able to enter a date with only 2 digits for the year component. The date will be in the past, so we want it to work for the previous century if the 2 digit year is after the current year, but work for the current century if the 2 digit year is eq...
I have a repeater control on an ASP.NET 2.0 web form. As I understanding it, all of the page's data-bound controls fire their binding events somewhere in between the Page_Load and the Page_PreRender events. However, my repeater's ItemDataBound event appears to be happening AFTER the PreRender event. How is this so a...
In ASP.NET, the page lifecycle consists of a series of events that occur during the rendering of a web page. The `ItemDataBound` event for a `Repeater` control is indeed designed to be raised whenever an item in the `Repeater` is data-bound, but it may be important to clarify when in the lifecycle these events occur, e...
30,591
[ { "from": "human", "value": "I have a repeater control on an ASP.NET 2.0 web form. \nAs I understanding it, all of the page's data-bound controls fire their binding events somewhere in between the Page_Load and the Page_PreRender events. \nHowever, my repeater's ItemDataBound event appears to be happening A...
I have a button inside an updatepanel. I have a PopupControlExtender linked to the button so when the button is clicked a panel pops up. It works fine except it does a full postback and I can't figure out why. The button and the PopupControlExtender is inside an update panel which inside the ContentTemplate tag. When I...
The issue you are facing with the `PopupControlExtender` causing a full postback instead of a partial postback is indeed related to how the controls are set up in the ASP.NET AJAX framework. Since you mentioned that using a `LinkButton` control generates a partial postback while a standard `Button` control does not, th...
23,301
[ { "from": "human", "value": "I have a button inside an updatepanel. I have a PopupControlExtender linked to the button so when the button is clicked a panel pops up. It works fine except it does a full postback and I can't figure out why. The button and the PopupControlExtender is inside an update panel whi...
With Java Version 1.5.0_06 on both Windows and Ubuntu Linux : Whenever I add minutes to the date "2008/10/05 00:00:00" , it seems that an extra hour is wrongly added. ie: adding 360 minutes to 2008/10/05 00:00:00 at midnight should arrive at 2008/10/05 06:00:00 But it is arriving at 2008/10/05 07:00:00 The totally perp...
The behavior you're observing is due to Daylight Saving Time (DST) changes that occurred in 2008. In particular, in the United States, Daylight Saving Time ended on November 2, 2008, but prior to that date, clocks were set one hour ahead. Here's a breakdown of what's likely happening in your case: 1. **Time Zone Awa...
32,752
[ { "from": "human", "value": "With Java Version 1.5.0_06 on both Windows and Ubuntu Linux :\nWhenever I add minutes to the date \"2008/10/05 00:00:00\" , it seems that an extra hour is wrongly added.\nie: adding 360 minutes to 2008/10/05 00:00:00 at midnight should arrive at 2008/10/05 06:00:00\nBut it is ar...
When I asked this previously I should have mentioned that it's particularly a light-weight IDE that I'm after, so I’m having to ask again as a different question. Something that is not just a text editor, is light-weight and versatile, that would suit Strawberry Perl, the GCC that comes with MinGW, GDB and Subversion. ...
For your requirements—specifically looking for a lightweight, versatile IDE that can handle both C (using GCC from MinGW) and Perl (Strawberry Perl)—here are a few suggestions: ### 1. **Code::Blocks** - **Type**: Lightweight IDE - **Languages**: Primarily C/C++ but can handle other languages with custom setup. - **Pro...
32,608
[ { "from": "human", "value": "When I asked this previously I should have mentioned that it's particularly a light-weight IDE that I'm after, so I’m having to ask again as a different question.\nSomething that is not just a text editor, is light-weight and versatile, that would suit Strawberry Perl, the GCC t...