instruction stringlengths 14 27.6k | completion stringlengths 3 38.3k | __original_row_idx int64 0 50k | conversations listlengths 2 2 |
|---|---|---|---|
WinXP Pro
Oracle 10g Instant Client 10.2.0.1
MS Access 2003
When I link a table in MS Access, the pick list that appears shows me every table and view in the system I have access to. This list is quite large. Normally, I really only want to look at the tables that I own. Is there a way to filter the items displayed bas... | In Microsoft Access, when you link tables from an Oracle database, it will display all the available tables and views that the connected user has access to, as you have experienced. Unfortunately, there is no direct filtering mechanism in the Access "Link Tables" dialog that allows you to only display the tables owned ... | 46,746 | [
{
"from": "human",
"value": "WinXP Pro\nOracle 10g Instant Client 10.2.0.1\nMS Access 2003\nWhen I link a table in MS Access, the pick list that appears shows me every table and view in the system I have access to. This list is quite large. Normally, I really only want to look at the tables that I own. Is t... |
I have a custom UILabel subclass for displaying currency values. I only want the user to be able to enter digits and let the view format those digits into a currency value -- like a cash register. This makes UITextField an inappropriate choice for this kind of input.
I've already overridden hitTest: so that the UILabel... | Creating a custom `UILabel` subclass that behaves like an input field while still acting like a label is certainly a challenging task. Since you want to only allow digits and backspace, using a `UILabel` directly is not the most suitable approach, as it is designed to display text and not handle user input.
Here are a... | 48,950 | [
{
"from": "human",
"value": "I have a custom UILabel subclass for displaying currency values. I only want the user to be able to enter digits and let the view format those digits into a currency value -- like a cash register. This makes UITextField an inappropriate choice for this kind of input.\nI've alrea... |
I am trying to create a function in postgres that retrieves data from one table and inputs into another. I am using the %ROWTYPE type to store the temporary data from the select statement and then iterate through it with an insert statement but have been unsuccessful! The following is my code :
CREATE OR REPLACE FUNCT... | It looks like you're on the right track with your PostgreSQL function, but I can identify a few areas that might be causing the issue. Here are some suggestions to help you get your function working:
1. **Initialization of the Counter**: Make sure to initialize the `counter` variable before you start the loop. Otherwi... | 48,425 | [
{
"from": "human",
"value": "I am trying to create a function in postgres that retrieves data from one table and inputs into another. I am using the %ROWTYPE type to store the temporary data from the select statement and then iterate through it with an insert statement but have been unsuccessful! The follow... |
I have a class that only really ever needed by classes in a certain class hierarchy. I wanted to know if it is possible to nest the class in the highest class's protected section and have all the other classes automatically inherit it?
| In many object-oriented programming languages, you can certainly nest a class within another class. If you nest a class in a class's `protected` section, it will allow subclasses of that class to access it. However, the accessibility and inheritance behavior can vary based on the programming language you are using.
He... | 48,320 | [
{
"from": "human",
"value": "I have a class that only really ever needed by classes in a certain class hierarchy. I wanted to know if it is possible to nest the class in the highest class's protected section and have all the other classes automatically inherit it?\n"
},
{
"from": "gpt",
"value":... |
I have to interface with a slightly archaic system that doesn't use webservices. In order to send data to this system, I need to post an XML document into a form on the other system's website. This XML document can get very large so I would like to compress it.
The other system sits on IIS and I use C# my end. I could... | To achieve compression of your request while interacting with the IIS server without modifying the server itself, you can take advantage of HTTP/1.1 features that include "Accept-Encoding" headers. By setting this header in your request, you can request that the server compress the response using a supported encoding l... | 45,469 | [
{
"from": "human",
"value": "I have to interface with a slightly archaic system that doesn't use webservices. In order to send data to this system, I need to post an XML document into a form on the other system's website. This XML document can get very large so I would like to compress it. \nThe other syste... |
I have written an Application Desktop Toolbar (a.k.a AppBar), it works great except for the fact that if I kill the process, the AppBar code never gets a chance to cleanup by sending an ABM_REMOVE. The problem is that this basically screws the users desktop up. The AppBar is written in .NET using interop code.
Does an... | When a process is forcefully terminated, it doesn't get a chance to execute any cleanup code, such as sending an `ABM_REMOVE` message to unregister the AppBar. This can leave the desktop in an inconsistent state. Unfortunately, because of the nature of process termination in Windows, there's no guaranteed way to perfor... | 49,263 | [
{
"from": "human",
"value": "I have written an Application Desktop Toolbar (a.k.a AppBar), it works great except for the fact that if I kill the process, the AppBar code never gets a chance to cleanup by sending an ABM_REMOVE. The problem is that this basically screws the users desktop up. The AppBar is wri... |
I've used Emacs for years on Linux, and I have lots of personally useful keybindings I've put under Hyper and Super. Nowadays I'm using Emacs on Windows and am missing those extra keybindings.
Is there some way in Windows to get modifier keys other than Ctrl and Meta?
| Yes, on Windows, you can use the Windows key and other modifier keys as substitutes for additional modifier keys in Emacs. Here's how you can set it up:
### Using `w32` Emacs Configuration
If you are using Emacs on Windows (specifically, the native version), you can utilize the `w32` window manager capabilities. The ... | 49,752 | [
{
"from": "human",
"value": "I've used Emacs for years on Linux, and I have lots of personally useful keybindings I've put under Hyper and Super. Nowadays I'm using Emacs on Windows and am missing those extra keybindings.\nIs there some way in Windows to get modifier keys other than Ctrl and Meta?\n"
},
... |
I'm looking for a cost effective tool for managing an web app on Ec2. Rightscale seems to the big dog and charges for it. Scalr looks like a more cost effective solution but it's hard to find out any real customer experiences..
The key aspects I'm looking for is a load balancer (http and https) and a way to automatical... | When it comes to managing web applications on Amazon EC2, there are several tools and approaches you can consider that can provide the functionality you're looking for without breaking the bank. Here are some options, along with insights and experiences from the field:
### 1. **AWS Elastic Beanstalk**
- **Overview**: ... | 49,035 | [
{
"from": "human",
"value": "I'm looking for a cost effective tool for managing an web app on Ec2. Rightscale seems to the big dog and charges for it. Scalr looks like a more cost effective solution but it's hard to find out any real customer experiences..\nThe key aspects I'm looking for is a load balancer... |
I have an SSIS package that does the following:
Selects the connection strings from a table of servers. The connection string is either the name of the server along with the domain (i.e. Dalin.myhouse.com) or is the direct IP to a server.
The package iterates through each connection string and populates a defined 'glo... | Certainly! To achieve this in SSIS (SQL Server Integration Services), you can use the **Execute SQL Task** effectively with the approach you've described. Here's a step-by-step method to set this up.
### Steps to Set Up the SSIS Package
1. **Set Up Global Variables:**
- Create two global variables in the Variable ... | 47,271 | [
{
"from": "human",
"value": "I have an SSIS package that does the following:\nSelects the connection strings from a table of servers. The connection string is either the name of the server along with the domain (i.e. Dalin.myhouse.com) or is the direct IP to a server.\nThe package iterates through each con... |
Okay, I will shortly be starting down the path of windows mobile development. I know nothing about the subject really and I am looking for people with experience to let me know of any gottchas you may know of.
Right now I dont even have a breif of what is requied but the assumption is that the application will be very... | It's great that you're diving into Windows Mobile development! Here’s a breakdown of key considerations and potential "gotchas" based on your outlined requirements and technologies:
### Offline Storage and Synchronization
1. **SQL Server Compact Edition (SQL CE)**:
- SQL CE is a lightweight, embedded database that... | 48,898 | [
{
"from": "human",
"value": "Okay, I will shortly be starting down the path of windows mobile development. I know nothing about the subject really and I am looking for people with experience to let me know of any gottchas you may know of. \nRight now I dont even have a breif of what is requied but the assum... |
I'm trying to integrate against a SOAP web service, running on Apache Axis. The WSDL specifies a namespace with a URI, that looks like:
<xsd:schema
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:stns="java:dk.tdc.serviceproviderweb.datatypes"
elementFormDefault="qualified"
attributeFormDefault="qualified"
... | When working with a SOAP web service defined in WSDL that utilizes namespaces, particularly those specified as `java:` in the `targetNamespace`, you need to take a few steps to integrate with it effectively using PHP. Here's how you can handle this situation:
### 1. Understand the Namespace:
The `targetNamespace` attr... | 40,685 | [
{
"from": "human",
"value": "I'm trying to integrate against a SOAP web service, running on Apache Axis. The WSDL specifies a namespace with a URI, that looks like:\n<xsd:schema\n xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\"\n xmlns:stns=\"java:dk.tdc.serviceproviderweb.datatypes\"\n elementFormDefault... |
I am wondering if there is a "best" way to shuffle a list of elements that contains duplicates such that the case where array[i] == array[i+1] is avoided as much as possible.
I am working on a weighted advertising display (I can adjust the number of displays per rotation for any given advertiser) and would like to avoi... | When you want to shuffle a list of elements containing duplicates to minimize the occurrence of consecutive duplicates (i.e., `array[i] == array[i+1]`), there are several strategies you can consider. Here’s a structured approach to achieve this:
### 1. Count Frequencies
First, count the frequency of each unique elemen... | 49,938 | [
{
"from": "human",
"value": "I am wondering if there is a \"best\" way to shuffle a list of elements that contains duplicates such that the case where array[i] == array[i+1] is avoided as much as possible.\nI am working on a weighted advertising display (I can adjust the number of displays per rotation for ... |
I have been pushing to finish off this project since 1 week and have been stuck with one problem that god knows how I missed. We have a sql server database that has 2 tables (of concern here).
Table 1 (id,langCode,englishText,translatedTextInUnicode{nvarchar(MAX)})
Table 2 (id,langCode,englishText,translatedTextInUtf-8... | It sounds like you're dealing with a character encoding issue when trying to display UTF-8 characters stored in your SQL Server database. Since you are using ASP.NET 3.5 and LINQ to SQL, there are several steps you can take to troubleshoot and resolve this issue. Here are some things to check and try:
### 1. Database ... | 45,047 | [
{
"from": "human",
"value": "I have been pushing to finish off this project since 1 week and have been stuck with one problem that god knows how I missed. We have a sql server database that has 2 tables (of concern here).\nTable 1 (id,langCode,englishText,translatedTextInUnicode{nvarchar(MAX)})\nTable 2 (id... |
I am trying to respond back to a client with a PDF stored in a MSSQL varbinary(MAX) field. The response works on my localhost and a test server over http connection, but does not work on the production server over https connection. I am using just a simple BinaryWrite (code below).
byte[] displayFile = DatabaseFile... | It seems like you're encountering a few issues while serving PDF files via HTTPS to IE 7. Here are some steps and suggestions to troubleshoot and potentially resolve the problem:
1. **Content-Disposition Header**: You've already tried using the `Content-Disposition` header, which is a good practice for prompting downl... | 47,576 | [
{
"from": "human",
"value": "I am trying to respond back to a client with a PDF stored in a MSSQL varbinary(MAX) field. The response works on my localhost and a test server over http connection, but does not work on the production server over https connection. I am using just a simple BinaryWrite (code belo... |
I have the following HTML
<div>
<img id="image1"
src="http://valleywag.com/assets/resources/2008/03/BlackGoogleLogo.jpg"
alt="Why doesn't this float correcly?"
style="border-width: 0px; float: left;" />
<div id="divText" style="font-family: Arial, Helvetica, sans-serif; font-size: 11... | The reason the text is not wrapping around the image is that the `img` tag has a `float: left;` style applied to it, but the surrounding `<div>` elements may not be set up properly to allow for the text to wrap around them.
Here are a few adjustments you can make to ensure the text flows around the image correctly:
1... | 49,923 | [
{
"from": "human",
"value": "I have the following HTML\n<div>\n <img id=\"image1\"\n src=\"http://valleywag.com/assets/resources/2008/03/BlackGoogleLogo.jpg\" \n alt=\"Why doesn't this float correcly?\"\n style=\"border-width: 0px; float: left;\" />\n <div id=\"divText\" style=... |
I need a VB.NET Forms application that processes a queue. It basically needs to ping a web service every 30 seconds and then load documents into a document management system, if there are any to load.
How would I implement this? Using a loop? Do I need to look into threads?
Thanks
| To implement a VB.NET Forms application that pings a web service every 30 seconds and processes a queue to load documents into a document management system, you can utilize a timer. This is a more efficient approach than using a continuous loop, as it does not block the UI thread and allows your application to remain r... | 43,106 | [
{
"from": "human",
"value": "I need a VB.NET Forms application that processes a queue. It basically needs to ping a web service every 30 seconds and then load documents into a document management system, if there are any to load.\nHow would I implement this? Using a loop? Do I need to look into threads?\nTh... |
Is it possible for me to create and destroy a TXMLDocument by myself in Borland C++ Builder? I've tried but borland keeps telling me that TXMLDocument is (and must be) an IDE managed component.
Also, the only reason that I want to do this is that TXMLDocument sort of crashes: I get the TXMLDocument and 'Gets' a workbo... | In Borland C++ Builder, `TXMLDocument` is indeed designed to be a managed component within the IDE's environment. This means that the IDE handles the lifecycle of the component, and it does not allow for standard C++ dynamic allocation or deallocation methods like `new` and `delete`. However, you can work around this b... | 49,460 | [
{
"from": "human",
"value": "Is it possible for me to create and destroy a TXMLDocument by myself in Borland C++ Builder? I've tried but borland keeps telling me that TXMLDocument is (and must be) an IDE managed component. \nAlso, the only reason that I want to do this is that TXMLDocument sort of crashes: ... |
I am in the process of refactoring our BI layers to make our code more "loosely coupled" and I was interested to hear what you guys thought might be interesting improvements to make?
At present, our API is something like the following:-
// Fetch a collection of objects
ProductCollection prods = Product.GetProducts();
... | Hi James,
Your thoughts about refactoring your BI layers to make them more loosely coupled and applying the Repository pattern are great steps towards achieving better maintainability and flexibility in your codebase. Let’s break down your current approach and the proposed changes, and I’ll address the advantages of m... | 48,599 | [
{
"from": "human",
"value": "I am in the process of refactoring our BI layers to make our code more \"loosely coupled\" and I was interested to hear what you guys thought might be interesting improvements to make?\nAt present, our API is something like the following:-\n// Fetch a collection of objects\nProd... |
I have a crystal report in my Visual Studio 2008 ASP.NET project, and when I choose "Group Expert" from the Crystal Reports -> Report menu, Visual Studio crashes / hangs and I have to use Task Manager to close the program. This happens no matter how many times I try, and oddly enough it seems to work fine on another c... | It sounds like you're experiencing a frustrating issue with Crystal Reports in Visual Studio 2008. Here are several troubleshooting steps that may help you resolve the problem:
### 1. **Update Crystal Reports**
Ensure that you are using the latest version of Crystal Reports for Visual Studio 2008. Sometimes, compatibi... | 48,016 | [
{
"from": "human",
"value": "I have a crystal report in my Visual Studio 2008 ASP.NET project, and when I choose \"Group Expert\" from the Crystal Reports -> Report menu, Visual Studio crashes / hangs and I have to use Task Manager to close the program. This happens no matter how many times I try, and oddl... |
I'd like to create a Web Part with security-trimmed links for a MOSS Publishing Intranet Portal. The idea is that their logged-in user name is checked against a custom provider to determine their permissions for a particular link and the hyperlinks would be rendered based on this.
What would be a good approach for some... | Creating a Web Part with security-trimmed links in a Microsoft Office SharePoint Server (MOSS) Publishing Intranet Portal is a great way to control access to content based on user permissions. You can indeed inherit from the "Summary Links" Web Part to extend its functionality, allowing for your custom permission check... | 46,719 | [
{
"from": "human",
"value": "I'd like to create a Web Part with security-trimmed links for a MOSS Publishing Intranet Portal. The idea is that their logged-in user name is checked against a custom provider to determine their permissions for a particular link and the hyperlinks would be rendered based on thi... |
I have a very complicated .NET application that contains cut/copy/paste functionality. I want to enable/disable cut/copy/paste buttons depending on the selected control/content. The app has many user controls. What is the best way to achieve this?
Thanks
| Enabling and disabling cut/copy/paste functionality in a complex .NET application with multiple user controls can be managed effectively by implementing a centralized approach. Here's a systematic way to achieve this:
### 1. Define an Interface
Create an interface that all your user controls can implement. This inter... | 47,081 | [
{
"from": "human",
"value": "I have a very complicated .NET application that contains cut/copy/paste functionality. I want to enable/disable cut/copy/paste buttons depending on the selected control/content. The app has many user controls. What is the best way to achieve this?\nThanks\n"
},
{
"from":... |
I'm working on something that needs a webpage to go full screen. The screen must become completely white.
Is there anyway that I can do this without flash or silverlight?
Thanks in advance
edit: Im not trying to force anybody into fullscreen, this will be mainly used by a couple of people. Even so I'll give proper fe... | Yes, you can achieve a full-screen white screen effect using HTML, CSS, and JavaScript without using Flash or Silverlight. You can utilize the Fullscreen API available in most modern browsers to go full screen. Here's a simple example to demonstrate this:
### HTML
```html
<!DOCTYPE html>
<html lang="en">
<head>
<m... | 47,031 | [
{
"from": "human",
"value": "I'm working on something that needs a webpage to go full screen. The screen must become completely white. \nIs there anyway that I can do this without flash or silverlight? \nThanks in advance\nedit: Im not trying to force anybody into fullscreen, this will be mainly used by a c... |
I have a number of user permissions that are tested throughout my ASP.NET application. These permission values are referenced in an Enum so that I can conveniently test permissions like so:
btnCreate.Enabled = PermissionManager.TestPermission(Permission.AllowCreate);
However, I also have these permissions stored in t... | Yes, managing permissions in both an enum and a database can create maintenance challenges and tightly coupled systems. To alleviate this issue, consider the following strategies that can help decouple your permission logic from your database and improve maintainability:
### 1. **Use a Singleton or Static Class for Pe... | 44,854 | [
{
"from": "human",
"value": "I have a number of user permissions that are tested throughout my ASP.NET application. These permission values are referenced in an Enum so that I can conveniently test permissions like so:\n\nbtnCreate.Enabled = PermissionManager.TestPermission(Permission.AllowCreate);\n\nHowev... |
echo date('r',strtotime("16 Dec, 2010")); //Tue, 16 Dec 2008 20:10:00 +0530
echo date('r',strtotime("16 Dec 2010")); //Sat, 16 Jan 2010 00:00:00 +0530
That's just wrong... Either it should fail or it should parse correctly. Do you know any robust natural language date/time parser in php? How do you parse natural l... | You're encountering issues with PHP's `strtotime()` function, which can be somewhat forgiving and inconsistent in how it interprets various date formats. Your observations are valid: `strtotime()` can produce unexpected results when it encounters formats or inputs that it considers "valid," even if they may not make se... | 48,935 | [
{
"from": "human",
"value": "echo date('r',strtotime(\"16 Dec, 2010\")); //Tue, 16 Dec 2008 20:10:00 +0530\necho date('r',strtotime(\"16 Dec 2010\")); //Sat, 16 Jan 2010 00:00:00 +0530\n\nThat's just wrong... Either it should fail or it should parse correctly. Do you know any robust natural language date... |
This is a question for a WSS/SharePoint guru.
Consider this scenario: I have an ASP.Net web service which links our corporate CRM system and WSS-based intranet together. What I am trying to do is provision a new WSS site collection whenever a new client is added to the CRM system. In order to make this work, I need to... | It looks like you're encountering a couple of issues related to SharePoint's object model and the security context in which your ASP.NET web service is executing. Here are some key points and suggestions to help you resolve the problem:
### 1. **NullReferenceException with SPUtility.ValidateFormDigest()**
The `NullRef... | 42,920 | [
{
"from": "human",
"value": "This is a question for a WSS/SharePoint guru. \nConsider this scenario: I have an ASP.Net web service which links our corporate CRM system and WSS-based intranet together. What I am trying to do is provision a new WSS site collection whenever a new client is added to the CRM sys... |
I'm developing a multilanguage software. As far as the application code goes, localizability is not an issue. We can use language specific resources and have all kinds of tools that work well with them.
But what is the best approach in defining a multilanguage database schema? Let's say we have a lot of tables (100 or ... | Designing a multilingual database schema is indeed a significant consideration for software localization and global reach. Each of the approaches you've outlined has its advantages and disadvantages. Let's go through them and then evaluate a potential recommendation based on different scenarios:
### 1. Separate Column... | 49,172 | [
{
"from": "human",
"value": "I'm developing a multilanguage software. As far as the application code goes, localizability is not an issue. We can use language specific resources and have all kinds of tools that work well with them.\nBut what is the best approach in defining a multilanguage database schema? ... |
Where can I download a PyLucene+JCC Windows build compiled for python 2.6?
Jose
| Finding a specific version of PyLucene and JCC, especially for an older version of Python like 2.6, can be challenging since many repositories and distributions have moved on to support more recent versions of Python. Here are a few steps you can take to find what you need:
1. **Official PyLucene Website**: Start by c... | 47,881 | [
{
"from": "human",
"value": "Where can I download a PyLucene+JCC Windows build compiled for python 2.6?\nJose\n"
},
{
"from": "gpt",
"value": "Finding a specific version of PyLucene and JCC, especially for an older version of Python like 2.6, can be challenging since many repositories and distri... |
How to list physical disks in Windows?
In order to obtain a list of "\\\\.\PhysicalDrive0" available.
| To list physical disks in Windows, you can use several methods. Below are a couple of ways to achieve this using Command Prompt, PowerShell, and Disk Management. Each method will help you identify the physical drives, including their paths such as `\\.\PhysicalDrive0`.
### Method 1: Using Command Prompt
1. **Open Com... | 47,033 | [
{
"from": "human",
"value": "How to list physical disks in Windows?\nIn order to obtain a list of \"\\\\\\\\.\\PhysicalDrive0\" available.\n"
},
{
"from": "gpt",
"value": "To list physical disks in Windows, you can use several methods. Below are a couple of ways to achieve this using Command Pro... |
I made a code that translate strings to match each word from the array 0ne to the array two and its showing the right results. But how to let the compiler take the number in the string and print it out as it is, ummmm see the code i wrote
class Program
{
public static string[] E = { "i", "go", "school", "t... | To modify your code so that it translates strings and retains any numbers as they are, you can adjust the `Translate` method to handle numbers explicitly. Specifically, you can use a regular expression to match both words and numbers, then process them accordingly.
Here’s how you can achieve that:
1. Update the regul... | 44,225 | [
{
"from": "human",
"value": "I made a code that translate strings to match each word from the array 0ne to the array two and its showing the right results. But how to let the compiler take the number in the string and print it out as it is, ummmm see the code i wrote\n\nclass Program\n {\n public ... |
I must be dense. After asking several questions on StackOverflow, I am still at a loss when it comes to grasping the new routing engine provided with ASP.NET MVC. I think I've narrowed down the problem to a very simple one, which, if solved, would probably allow me to solve the rest of my routing issues. So here it ... | Yes, it is definitely possible to register a route to support Twitter-like URLs (i.e., `www.twitter.com/username`) in ASP.NET MVC alongside your existing routes for login and register. You can do this by defining a custom route for user profiles and then specifying it before the default route.
Here's how you can set i... | 48,421 | [
{
"from": "human",
"value": "I must be dense. After asking several questions on StackOverflow, I am still at a loss when it comes to grasping the new routing engine provided with ASP.NET MVC. I think I've narrowed down the problem to a very simple one, which, if solved, would probably allow me to solve th... |
The 64 bits version of Windows Server does not came with the ODBC DBF Drivers by default.
Is there a way to get them?
What alternatives exist?
| Windows Server does not include native ODBC drivers for DBF files (often used by dBase or FoxPro) by default, but you have a few options to get ODBC support for DBF files:
### 1. **Install Third-Party ODBC Drivers**
You can find third-party ODBC drivers that support DBF files. Some popular options include:
- **Actual... | 49,300 | [
{
"from": "human",
"value": "The 64 bits version of Windows Server does not came with the ODBC DBF Drivers by default.\nIs there a way to get them?\nWhat alternatives exist?\n"
},
{
"from": "gpt",
"value": "Windows Server does not include native ODBC drivers for DBF files (often used by dBase or... |
I've been utilizing NHibernate 2.0.1.4000 on all current .NET 3.5 SP1 projects and have had no problems with any other queries (utilizing either the Query or Criteria APIs), until some new business logic dictated the necessity of a new query in this particular project against the application's database that needs to re... | It sounds like you're encountering a frustrating issue with NHibernate when trying to query for records with a null property. The exception "Value cannot be null!" typically indicates that there may be a problem with how the criteria or the query is being set up. Here are a few things you might check or try in order to... | 47,036 | [
{
"from": "human",
"value": "I've been utilizing NHibernate 2.0.1.4000 on all current .NET 3.5 SP1 projects and have had no problems with any other queries (utilizing either the Query or Criteria APIs), until some new business logic dictated the necessity of a new query in this particular project against th... |
There is a socket related function call in my code, that function is from another module thus out of my control, the problem is that it blocks for hours occasionally, which is totally unacceptable, How can I limit the function execution time from my code? I guess the solution must utilize another thread.
| To limit the execution time of a blocking function call in Python, you can use the `threading` module to run the blocking function in a separate thread and then wait for that thread to finish within a specified timeout. If the thread does not complete in the allotted time, you can handle that scenario accordingly.
Her... | 49,315 | [
{
"from": "human",
"value": "There is a socket related function call in my code, that function is from another module thus out of my control, the problem is that it blocks for hours occasionally, which is totally unacceptable, How can I limit the function execution time from my code? I guess the solution mu... |
I have a long "binary string" like the output of PHPs pack function.
How can I convert this value to base62 (0-9a-zA-Z)?
The built in maths functions overflow with such long inputs, and BCmath doesn't have a base_convert function, or anything that specific. I would also need a matching "pack base62" function.
| To convert a long binary string to base62 and vice versa (pack), you can follow the approach below using PHP. We'll write two functions: one for converting a binary string to base62 and another for converting base62 back to the binary string.
### Converting Binary String to Base62
Base62 uses the characters `0-9`, `a... | 43,883 | [
{
"from": "human",
"value": "I have a long \"binary string\" like the output of PHPs pack function.\nHow can I convert this value to base62 (0-9a-zA-Z)?\nThe built in maths functions overflow with such long inputs, and BCmath doesn't have a base_convert function, or anything that specific. I would also need... |
I'm using C# and .NET 3.5. I need to generate and store some T-SQL insert statements which will be executed later on a remote server.
For example, I have an array of Employees:
new Employee[]
{
new Employee { ID = 5, Name = "Frank Grimes" },
new Employee { ID = 6, Name = "Tim O'Reilly" }
}
and I need to end up w... | When generating T-SQL statements manually, especially in a situation where you're not using parameterized queries (like with `SqlCommand`), you need to be particularly cautious about SQL injection and the proper handling of special characters.
Since you're generating insert statements for later execution, you'll want ... | 45,114 | [
{
"from": "human",
"value": "I'm using C# and .NET 3.5. I need to generate and store some T-SQL insert statements which will be executed later on a remote server.\nFor example, I have an array of Employees:\nnew Employee[]\n{\n new Employee { ID = 5, Name = \"Frank Grimes\" },\n new Employee { ID = 6, N... |
In an app I'm coding I would like to make an alert message to appear that displays a large semi-transparent warning message without affecting the users work. Basically I will fade in the message but never set it's opacity to 1 and I want the user to be able to click 'through' the message as if it isn't there.
I have s... | To create a large semi-transparent warning message in your application that allows users to click through it without capturing mouse events, you can take the following approach using Windows Forms:
### Using Layered Windows for Click-Through Transparency
Instead of using a standard window, you can create a layered wi... | 47,292 | [
{
"from": "human",
"value": "In an app I'm coding I would like to make an alert message to appear that displays a large semi-transparent warning message without affecting the users work. Basically I will fade in the message but never set it's opacity to 1 and I want the user to be able to click 'through' t... |
I have a class with a string property, having both a getter and a setter, that is often so long that the PropertyGrid truncates the string value. How can I force the PropertyGrid to show an ellipsis and then launch a dialog that contains a multiline textbox for easy editing of the property? I know I probably have to se... | To create a custom property editor for a long string property in a `PropertyGrid`, you can implement the `UITypeEditor` class, which allows you to create a custom user interface for editing properties.
Here’s how you can do this:
1. **Create a Custom UITypeEditor**: This class will define how your property will be di... | 44,299 | [
{
"from": "human",
"value": "I have a class with a string property, having both a getter and a setter, that is often so long that the PropertyGrid truncates the string value. How can I force the PropertyGrid to show an ellipsis and then launch a dialog that contains a multiline textbox for easy editing of t... |
this seems so silly - i must be missing something obvious. I have the following code (just as a test):
<%@ Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script runat="server">
void page_load(object o, EventArgs e)
... | It sounds like you're experiencing differences in response buffering behavior between your local development environment (Cassini) and the production environment (IIS 6). This is not unusual, as different web servers and configurations can lead to variations in how they handle response buffering.
Here are a few consid... | 49,075 | [
{
"from": "human",
"value": "this seems so silly - i must be missing something obvious. I have the following code (just as a test):\n<%@ Page Language=\"C#\" %>\n\n<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n\n<script runat=\... |
I dynamically create an element (div) in javascript, on which i register an event listener:
var tooltip = document.createElement('div');
tooltip.onclick = function() { alert('hello'); }
Now, if I attach this element to the document body:
document.body.appendChild(tooltip);
all is well and the event is captured. Howe... | When dynamically creating elements in JavaScript and attaching event listeners, the functionality should typically remain intact regardless of where the element is appended in the DOM. However, there are a couple of possible reasons why the `onclick` event listener might not be working when you append the tooltip to a ... | 49,238 | [
{
"from": "human",
"value": "I dynamically create an element (div) in javascript, on which i register an event listener:\nvar tooltip = document.createElement('div');\ntooltip.onclick = function() { alert('hello'); } \n\nNow, if I attach this element to the document body:\ndocument.body.appendChild(tooltip)... |
Env.: VS 2008, .NET 2.0, WinForms
I have a listview in Tile mode. Some items have an associated image. Some don't.
The contents (listview items) is often renewed when user clicks some controls. When this happens, it sometimes appears that none of the new items have images. In that case, I would like to get rid of the e... | In a Windows Forms application, when you use a `ListView` in tile mode with an associated `LargeImageList`, the `ListView` always reserves space for the images, even if there are no images assigned to the items. The behavior you're experiencing is due to the `ListView` reserving space for images that it expects to be t... | 49,427 | [
{
"from": "human",
"value": "Env.: VS 2008, .NET 2.0, WinForms\nI have a listview in Tile mode. Some items have an associated image. Some don't.\nThe contents (listview items) is often renewed when user clicks some controls. When this happens, it sometimes appears that none of the new items have images. In ... |
Is it possible to rename all the tabs in a jQuery UI tab control? My tabs are numbered from 1..N, and it is possible to remove a tab from it. I want to "rename" the remaining tabs so they are numbered 1,2,3,4,5,6, and 1,2,3,5,6,7 when you remove the fourth tab. They should end up named by their 1-based index.
| Yes, you can rename all the tabs in a jQuery UI tab control by updating the tab titles based on their current index. This can be done by iterating over the tabs and modifying their text based on the new index after a tab has been removed.
Here's a sample implementation:
1. First, ensure you have included jQuery and j... | 49,041 | [
{
"from": "human",
"value": "Is it possible to rename all the tabs in a jQuery UI tab control? My tabs are numbered from 1..N, and it is possible to remove a tab from it. I want to \"rename\" the remaining tabs so they are numbered 1,2,3,4,5,6, and 1,2,3,5,6,7 when you remove the fourth tab. They should end... |
I have two dedicated servers and no hardware firewall. I'd like to forward all requests that come into the primary server on port 1008 to be fulfilled by another dedicated server on the same network. I know I need to set up some kind of TCP proxy, but I first heard of IPTables yesterday. Any quick tips?
| Sure! If you're looking to forward requests coming into your primary server on port 1008 to another dedicated server on the same network, you can use `iptables` to set up a TCP proxy. Here’s a simple way to do that.
1. **Set Up IP Forwarding**: First, you need to enable IP forwarding on your primary server. You can do... | 48,992 | [
{
"from": "human",
"value": "I have two dedicated servers and no hardware firewall. I'd like to forward all requests that come into the primary server on port 1008 to be fulfilled by another dedicated server on the same network. I know I need to set up some kind of TCP proxy, but I first heard of IPTables y... |
The bugzilla (perl-based) system has a feature to login automatically by using a http server environment variable. If you fill in the right ID or username, you are automatically logged in.
My server runs Joomla (PHP-based) and has all the information about who is logged in. It runs bugzilla within a sub-frame.
So, how ... | To set an environment variable in a PHP script that can be read by a Perl script (like your Bugzilla instance), you can modify the Apache server configuration or use a `.htaccess` file (if allowed) to set environment variables based on specific conditions (like user authentication from Joomla).
However, if you want t... | 46,552 | [
{
"from": "human",
"value": "The bugzilla (perl-based) system has a feature to login automatically by using a http server environment variable. If you fill in the right ID or username, you are automatically logged in.\nMy server runs Joomla (PHP-based) and has all the information about who is logged in. It ... |
After tinkering around to solve [this][1] problem, I think the core of the problem is the following:
When you use the Html.RadioButton() html helper with an Enum as value field, you can only choose your option once. AFter reposting the page, the helpers will ignore the value set in the call and set all radio buttons to... | The issue you're encountering with the `Html.RadioButton()` helper in ASP.NET MVC appears to be related to how you're determining which radio button should be checked based on the model state. When using radio buttons, it is crucial that the `checked` attribute is correctly set based on the model's value after a form s... | 48,087 | [
{
"from": "human",
"value": "After tinkering around to solve [this][1] problem, I think the core of the problem is the following:\nWhen you use the Html.RadioButton() html helper with an Enum as value field, you can only choose your option once. AFter reposting the page, the helpers will ignore the value se... |
I am using C#.net for application development.
To log and debug exceptions, I use the stacktrace.
I executed my application on another machine, but when errors occur it refers to the path of my development machine.
Ex: D:\Projects\xyz.CS line no :12 _Error_message_here.
Why does it trace to the path on my developmen... | When you run a C#.NET application that is compiled in Debug mode, the compiler includes metadata in the binary files (DLLs and EXEs), including debug symbols. These debug symbols contain information about the original source code, including the file paths and line numbers where the code is defined. This is why you're s... | 49,249 | [
{
"from": "human",
"value": "I am using C#.net for application development.\nTo log and debug exceptions, I use the stacktrace.\nI executed my application on another machine, but when errors occur it refers to the path of my development machine.\nEx: D:\\Projects\\xyz.CS line no :12 _Error_message_here.\n... |
Does anyone know of a simple way for a C++ program to communicate directly with a MySQL database? I have looked at MySQL++ and found it to be very confusing. If anyone knows of a very simple way of doing this, please let me know.
Thanks
P.S. I am developing on a Windows machine. PHP and MySQL web web application set... | Yes, there is a straightforward way to communicate with a MySQL database using C++. You can use the MySQL Connector/C++ provided by Oracle. It's a well-documented and relatively simple library to work with. Below, I'll guide you through setting it up and provide a sample code snippet to get you started.
### Step 1: In... | 42,204 | [
{
"from": "human",
"value": "Does anyone know of a simple way for a C++ program to communicate directly with a MySQL database? I have looked at MySQL++ and found it to be very confusing. If anyone knows of a very simple way of doing this, please let me know.\nThanks\nP.S. I am developing on a Windows mach... |
I have a button, I need to display a pop-up in javascript. So on its client click I call a javascript function which does that.
if user clicks "yes", I need to do a post back and call buttons server side click event, here is what I am doing inside the javascript function
__doPostBack(deleteLinkButton, 'Click');
' Wh... | When you're trying to trigger a server-side click event for a button using `__doPostBack`, there are a couple of things to ensure for it to work correctly. Here are a few troubleshooting steps and suggestions:
### 1. Verify the Button ID:
Ensure that the `deleteLinkButton` variable holds the correct client ID of the b... | 49,019 | [
{
"from": "human",
"value": "I have a button, I need to display a pop-up in javascript. So on its client click I call a javascript function which does that.\nif user clicks \"yes\", I need to do a post back and call buttons server side click event, here is what I am doing inside the javascript function\n__... |
I have created a one-time subscription in SSRS report manager 2008. However I keep getting duplicate emails sent out by the subscription. The interval between each email is about 30 minutes.
I have checked SQL agent job and it looks the SQL agent job is created correctly. It just runs once and after that the next run ... | Dealing with duplicate emails from SQL Server Reporting Services (SSRS) can be quite frustrating. Since you've already checked the SQL Agent job and verified that the SMTP service is functioning correctly, here are some additional steps and considerations that you can look into to troubleshoot and potentially resolve t... | 48,359 | [
{
"from": "human",
"value": "I have created a one-time subscription in SSRS report manager 2008. However I keep getting duplicate emails sent out by the subscription. The interval between each email is about 30 minutes. \nI have checked SQL agent job and it looks the SQL agent job is created correctly. It j... |
I have a class which inherits from QTreeWidgetItem and I intercept the click event.
I need to get another object from inside MY QTreeWidgetItem when I click the tree row, how can I do that??
| To intercept the click event on your custom `QTreeWidgetItem` class and retrieve another object, you need to override the `mousePressEvent` method of your `QTreeWidgetItem` subclass and then access the desired object from that method. Since `QTreeWidgetItem` does not directly support mouse events like other widgets, th... | 48,893 | [
{
"from": "human",
"value": "I have a class which inherits from QTreeWidgetItem and I intercept the click event.\nI need to get another object from inside MY QTreeWidgetItem when I click the tree row, how can I do that??\n"
},
{
"from": "gpt",
"value": "To intercept the click event on your custo... |
I am looking for a performance profiler that is able to profile a C++ library that is being called from a .NET Application.
I tried Purify+ without success (I don't get the calls the COM library) and a few others.
| Profiling a C++ library from a .NET application can be a bit tricky due to the interop layer between the two environments. However, there are several tools you can consider that should help you profile your C++ code, even when it is called from a .NET application:
1. **Visual Studio Profiler**:
- If you're using Vi... | 49,401 | [
{
"from": "human",
"value": "I am looking for a performance profiler that is able to profile a C++ library that is being called from a .NET Application.\nI tried Purify+ without success (I don't get the calls the COM library) and a few others.\n"
},
{
"from": "gpt",
"value": "Profiling a C++ lib... |
Possible Duplicate:
Attempted SQL injection attack - what are they trying to do?
I have seen this SQL injection attempt on my site many times in the last few months.
';DECLARE @S CHAR(4000);SET @S=CAST(0x4445434C415245204054207661726368617228323535292C40432076617263686172283430303029204445434C415245205461626C655F4... | The SQL injection attempt you've provided is quite complex, and it reflects a typical strategy used by attackers to execute arbitrary SQL code on a vulnerable SQL Server database. Let’s break down the components of the attempted injection to understand what the attacker is attempting to do.
### Breakdown of the Attemp... | 48,375 | [
{
"from": "human",
"value": "\nPossible Duplicate:\nAttempted SQL injection attack - what are they trying to do? \n\nI have seen this SQL injection attempt on my site many times in the last few months. \n';DECLARE @S CHAR(4000);SET @S=CAST(0x4445434C415245204054207661726368617228323535292C40432076617263686... |
According to this article rebasing is not necessary for .NET assemblies due to JIT compilation of the code. The article states:
"JIT-compiled code does not have a rebasing problem since the addresses are generated at run time based on where the code is placed in memory. Also, MSIL is rarely affected by base address mi... | In the context of .NET assemblies and the JIT compilation process, the term "rebasing" generally refers to the adjustment of the base address of a DLL or executable file in memory. This can be necessary when multiple modules (DLLs or EXEs) are loaded into the same process space, and their default base addresses overlap... | 44,566 | [
{
"from": "human",
"value": "According to this article rebasing is not necessary for .NET assemblies due to JIT compilation of the code. The article states: \n\"JIT-compiled code does not have a rebasing problem since the addresses are generated at run time based on where the code is placed in memory. Also,... |
Hey I usually run into a situation where I will create a class that should only be instantiated by one or a few classes. In this case I would make its constructor private and make it a friend class to the objects that should be able to instantiate it. For example (in C++):
class CFoo
{
friend class CFoo;
// pr... | The design you're using in C++ with a private constructor and friend classes is a common approach to control instantiation and encapsulate class behavior. However, there are alternative designs that can achieve similar objectives and might be more idiomatic in C#. Here are some options for both languages:
### C++ Appr... | 47,154 | [
{
"from": "human",
"value": "Hey I usually run into a situation where I will create a class that should only be instantiated by one or a few classes. In this case I would make its constructor private and make it a friend class to the objects that should be able to instantiate it. For example (in C++):\nclas... |
Following up this question: "Database enums - pros and cons", I'd like to know which database systems support enumeration data types, and a bit of detail on how they do it (e.g. what is stored internally, what are the limits, query syntax implications, indexing implications, ...).
Discussion of use cases or the pros an... | Enumeration (enum) data types are a useful feature in various database systems that allow for the definition of a set of named values. Below are details on some popular database systems that support enum data types, how they implement it, and various implications related to storage, limits, query syntax, and indexing.
... | 42,677 | [
{
"from": "human",
"value": "Following up this question: \"Database enums - pros and cons\", I'd like to know which database systems support enumeration data types, and a bit of detail on how they do it (e.g. what is stored internally, what are the limits, query syntax implications, indexing implications, .... |
I bet I've got elementary question, but I couldn't solve it for two nights.
I've got 1 "ul" element and I just want it to move any amount of pixels every e.g. 2 sec to the left. I want him to move like this step by step and then come back to the original position and start moving again.
I've been stucked, my script on... | To achieve the desired effect where your `<ul>` element moves step by step to the left and then comes back to the original position, you can modify your approach using `setInterval` to incrementally change the position. You’ll also need to keep track of the current position and the direction of movement (left or right)... | 46,504 | [
{
"from": "human",
"value": "I bet I've got elementary question, but I couldn't solve it for two nights.\nI've got 1 \"ul\" element and I just want it to move any amount of pixels every e.g. 2 sec to the left. I want him to move like this step by step and then come back to the original position and start mo... |
I have a page generated by php which includes two drop-down lists (SELECTs) which contain a lot of items (about 2,000 each). The page is fine, but when it loads in Firefox, there's a delay during the load, and then it seems to refresh the entire page. If a user tries to click on anything before the "reload" occurs, it ... | It sounds like you're experiencing an issue with the way the page and its components are loading, which could be related to how browsers handle large HTML payloads or how your PHP script is structured. Here are some potential causes and solutions you can consider:
### Possible Causes
1. **Large Data Sets**: Loading 2... | 49,055 | [
{
"from": "human",
"value": "I have a page generated by php which includes two drop-down lists (SELECTs) which contain a lot of items (about 2,000 each). The page is fine, but when it loads in Firefox, there's a delay during the load, and then it seems to refresh the entire page. If a user tries to click on... |
I've a table with a lot of registers (more than 2 million). It's a transaction table but I need a report with a lot of joins. Whats the best practice to index that table because it's consuming too much time.
I'm paging the table using the storedprocedure paging method but I need an index because when I want to export t... | Indexing is crucial for optimizing performance, especially when dealing with large tables like your transaction table with over 2 million records. Here are some best practices to consider when indexing your table and optimizing your queries:
### 1. Identify Key Queries
- **Analyze Query Patterns:** Look at the most co... | 48,644 | [
{
"from": "human",
"value": "I've a table with a lot of registers (more than 2 million). It's a transaction table but I need a report with a lot of joins. Whats the best practice to index that table because it's consuming too much time.\nI'm paging the table using the storedprocedure paging method but I nee... |
Recently the company I work for was asked to pitch for creation of a forum targetted at children as part of a website solution.
I think that at least we should reccommend
Human moderation by a trained individual to protect these kids
Code alarm / suspicious analysis into the forum
How has anyone else tackled this and... | Creating a forum targeted at children is a significant responsibility, and it’s crucial to prioritize their safety, privacy, and overall positive experience. Here are some ideas and strategies that have been effectively implemented in similar projects:
### 1. **Human Moderation**
- **Trained Moderators**: Employ indiv... | 45,323 | [
{
"from": "human",
"value": "Recently the company I work for was asked to pitch for creation of a forum targetted at children as part of a website solution.\nI think that at least we should reccommend\n\nHuman moderation by a trained individual to protect these kids\nCode alarm / suspicious analysis into th... |
I have resource dictionary files (MenuTemplate.xaml, ButtonTemplate.xaml, etc) that I want to use in multiple separate applications. I could add them to the applications' assemblies, but it's better if I compile these resources in one single assembly and have my applications reference it, right?
After the resource ass... | Yes, compiling your resource dictionaries into a single assembly is a good approach for reusability across multiple applications. Here’s how to reference those resources in your application's `App.xaml` after building the resource assembly.
### Step 1: Create a Resource Dictionary Assembly
1. Create a new Class Librar... | 48,052 | [
{
"from": "human",
"value": "I have resource dictionary files (MenuTemplate.xaml, ButtonTemplate.xaml, etc) that I want to use in multiple separate applications. I could add them to the applications' assemblies, but it's better if I compile these resources in one single assembly and have my applications ref... |
I have a page in my application that refreshes some content (a list of users currently signed in) from the server every 10 seconds. This data is loaded using the Ajax class from the mootools framework, specifically with Javascript that looks like:
var xmldata = (function() {
new Ajax('xmldata.jsp?time='+$time(), {m... | It sounds like you are dealing with a classic issue of resource management in web applications, particularly when dealing with repeated asynchronous requests. This situation is exacerbated in Internet Explorer due to its handling of long-running scripts. Here are some approaches you can take to diagnose and potentially... | 49,868 | [
{
"from": "human",
"value": "I have a page in my application that refreshes some content (a list of users currently signed in) from the server every 10 seconds. This data is loaded using the Ajax class from the mootools framework, specifically with Javascript that looks like:\nvar xmldata = (function() {\n ... |
I have just start using git and i can't get it to remember my passphrase I'm using cmd.exe elevated and my git host is github and i have create a ssh key like that guide on github
but i still get
*\subnus.mvc>git push origin master
Enter passphrase for key '/c/Users/Subnus/.ssh/id_rsa':
| When you create an SSH key with a passphrase, Git will ask for that passphrase every time you use the key, unless you use an SSH agent to manage your keys. Here’s how you can use an SSH agent to remember your passphrase, so you don't have to enter it every time.
### Using the SSH Agent
1. **Start the SSH Agent**:
... | 48,442 | [
{
"from": "human",
"value": "I have just start using git and i can't get it to remember my passphrase I'm using cmd.exe elevated and my git host is github and i have create a ssh key like that guide on github\nbut i still get \n*\\subnus.mvc>git push origin master\nEnter passphrase for key '/c/Users/Subnus... |
Our Development environment has many layers and is complicated to replicate or even backup effectively. Basically the File system (ie. /usr/appdir/webapp...) has other applications serving our web application, those application we update doing svn updates from their repository.
The use of the web application itself ... | Implementing a robust deployment process that effectively manages changes across development, staging, and production environments can be complex, especially when user input affects both the file system and the database. Below are some best practices and pointers to help streamline this process:
### 1. Version Control... | 47,967 | [
{
"from": "human",
"value": "Our Development environment has many layers and is complicated to replicate or even backup effectively. Basically the File system (ie. /usr/appdir/webapp...) has other applications serving our web application, those application we update doing svn updates from their repository.... |
Is there an editor that is:
Available for at least windows and linux
Highlights multiple syntaxes in the same document. (Ala Dreamweaver)
Tabbed interface
All the editors I tried highlighted by file extension only which isn't fine grained enough.
At the very least it needs to distinguish scripting from html, css and ... | Yes, there are several code editors that meet your requirements of being available on both Windows and Linux, supporting syntax highlighting for multiple languages in the same document, and offering a tabbed interface. Here are a few options you might consider:
### 1. **Visual Studio Code**
- **Platforms**: Windows, L... | 48,557 | [
{
"from": "human",
"value": "Is there an editor that is:\n\nAvailable for at least windows and linux\nHighlights multiple syntaxes in the same document. (Ala Dreamweaver)\nTabbed interface\n\nAll the editors I tried highlighted by file extension only which isn't fine grained enough.\nAt the very least it ne... |
Which talks/videos appealed to you as a developer?
I really like this talk by Clay Shirky:
http://www.youtube.com/watch?v=Xe1TZaElTAs
And, Startup School talk by David:
http://www.omnisio.com/startupschool08/david-heinemeier-hansson-at-startup-school-08
Which ones you recommend? please provide links and a short descrip... | Here are some talks and videos that appeal to developers and provide valuable insights, even if they aren't specifically programming-focused:
1. **Simon Sinek: How Great Leaders Inspire Action**
- [Watch Here](https://www.ted.com/talks/simon_sinek_how_great_leaders_inspire_action)
- Sinek introduces the concept ... | 48,133 | [
{
"from": "human",
"value": "Which talks/videos appealed to you as a developer?\nI really like this talk by Clay Shirky:\nhttp://www.youtube.com/watch?v=Xe1TZaElTAs\nAnd, Startup School talk by David:\nhttp://www.omnisio.com/startupschool08/david-heinemeier-hansson-at-startup-school-08\nWhich ones you recom... |
GCC supports Setjump-longjump (sjlj) and Dwarf2 table-based unwinding (dw2) exception handling models. What is the difference between the two models and how to choose the appropriate model? Why is Dwarf2 table-based unwinding (dw2) the more efficient model? I understand that the two models cannot be mixed.
Reference: T... | The two exception handling models provided by GCC, Setjmp-Longjmp (sjlj) and DWARF2 table-based unwinding (dw2), have different mechanisms for managing exceptions, and each has its strengths and weaknesses depending on the context in which they are used.
### Setjmp-Longjmp (sjlj)
- **Mechanism**: The sjlj model is ba... | 48,445 | [
{
"from": "human",
"value": "GCC supports Setjump-longjump (sjlj) and Dwarf2 table-based unwinding (dw2) exception handling models. What is the difference between the two models and how to choose the appropriate model? Why is Dwarf2 table-based unwinding (dw2) the more efficient model? I understand that the... |
What are the best practices for naming ant targets?
For example, what would you expect the target "test" to run? All unit tests? All functional tests? Both?
What are the standard names used for running different types of tests (unit/functional/all)? Are there standards for target names to deploy software in J2SE? i... | Naming your Ant targets appropriately is crucial for maintaining clarity, usability, and consistency within your build process. Below are best practices for naming Ant targets, as well as standard conventions for running different types of tests and for deploying software in Java projects.
### Best Practices for Namin... | 45,563 | [
{
"from": "human",
"value": "What are the best practices for naming ant targets? \nFor example, what would you expect the target \"test\" to run? All unit tests? All functional tests? Both?\nWhat are the standard names used for running different types of tests (unit/functional/all)? Are there standards f... |
Could someone compare and contrast on WCF Rest services vs. ADO.NET Data Services? What is the difference and when to use which?
Thanks,
Ray.
Edit: thanks for the first answer, just to give a bit of background on what I'm looking to do: I have a web app I plan to put in the cloud (someday), and the DAL is built with AD... | Certainly, Ray! Let’s break down the differences between WCF REST Services and ADO.NET Data Services, particularly in the context of your web application that utilizes ADO.NET Entity Framework and is intended to be cloud-deployed.
### WCF REST Services
**Overview:**
- Windows Communication Foundation (WCF) is a frame... | 45,019 | [
{
"from": "human",
"value": "Could someone compare and contrast on WCF Rest services vs. ADO.NET Data Services? What is the difference and when to use which?\nThanks,\nRay.\nEdit: thanks for the first answer, just to give a bit of background on what I'm looking to do: I have a web app I plan to put in the c... |
I develop a variety of applications and have 3-4 miscellaneous libraries that I reuse across these apps (one for math, one for database functions etc.).
Currently I have one master source directory with each project as a top level directory (including my helper projects). And each project that needs a helper adds the e... | Managing multiple projects and shared libraries can indeed become cumbersome, especially in a version control system like Subversion (SVN). Here are some strategies to consider that can help streamline your workflow, manage dependencies, and maintain backward compatibility while keeping your repository manageable.
###... | 45,134 | [
{
"from": "human",
"value": "I develop a variety of applications and have 3-4 miscellaneous libraries that I reuse across these apps (one for math, one for database functions etc.).\nCurrently I have one master source directory with each project as a top level directory (including my helper projects). And e... |
With wxWidgets I use the following code:
HWND main_window = ...
...
wxWindow *w = new wxWindow();
wxWindow *window = w->CreateWindowFromHWND(0, (WXHWND) main_window);
How do I do the same thing in Qt? The HWND is the handle of the window I want as the parent window for the new QtWidget.
| To create a Qt widget that uses an existing Windows HWND as its parent, you can use the `QWidget::createWindowContainer` method. This method allows you to create a Qt widget that will serve as a container for the existing native window. Here's how you can do this in Qt:
1. Ensure you have included the necessary header... | 49,595 | [
{
"from": "human",
"value": "With wxWidgets I use the following code:\nHWND main_window = ...\n...\nwxWindow *w = new wxWindow();\nwxWindow *window = w->CreateWindowFromHWND(0, (WXHWND) main_window);\n\nHow do I do the same thing in Qt? The HWND is the handle of the window I want as the parent window for th... |
I'm currently in the process of updating a site from preview 2 of ASP.NET MVC to the Beta release. I'm down to my last compile error with no solution in site after an exhaustive search. I have some code in Global.asax.cs which sets up IOC using the Windsor container:
ControllerBuilder.Current.SetControllerFactory(typeo... | It sounds like you're encountering a versioning issue with the MVC framework and the Windsor container. When moving from a preview version of ASP.NET MVC to the Beta release, it is indeed possible that some libraries may not be compatible due to changes in the MVC assembly's version or namespace.
Here are a few steps ... | 49,618 | [
{
"from": "human",
"value": "I'm currently in the process of updating a site from preview 2 of ASP.NET MVC to the Beta release. I'm down to my last compile error with no solution in site after an exhaustive search. I have some code in Global.asax.cs which sets up IOC using the Windsor container:\nController... |
Our marketing department comes back with "active directory integration" being a key customer request, but our company does not seem to have the attention span to (1) decide on what functional changes we want to make toward this end, (2) interview a broad range of customer to identify the most requested functional chang... | Active Directory (AD) integration can be a complex topic, especially when considering its implications for both ASP.NET and WinForms applications. Let's address the considerations you've listed and the broader implications of integrating AD into your applications.
### Key Considerations for Active Directory Integratio... | 48,532 | [
{
"from": "human",
"value": "Our marketing department comes back with \"active directory integration\" being a key customer request, but our company does not seem to have the attention span to (1) decide on what functional changes we want to make toward this end, (2) interview a broad range of customer to i... |
So here's one way to define a sum as a message passing object:
(define (make-sum . exps)
(let ((len (length exps)))
;; first handle variable length operands
(cond
((= len 0) (make-number 0)) ;; base case for addition
((= len 1) (car exps)) ;; might as well drop the sum if only 1 argument
... | To transform your `make-product` function from the first format (variable-length arguments) into the second format (two arguments), you can follow a similar structure to the `make-sum` function you provided. Here's how you can rewrite the `make-product` function:
```scheme
(define (make-product exp1 exp2)
(cond ((ex... | 38,399 | [
{
"from": "human",
"value": "So here's one way to define a sum as a message passing object:\n (define (make-sum . exps)\n (let ((len (length exps)))\n ;; first handle variable length operands\n (cond \n ((= len 0) (make-number 0)) ;; base case for addition\n ((= len 1) (car exps)) ;; ... |
Is there any way to get a specific error condition when a C++ stream open fails? That is, whether it failed because the file didn't exist, or permissions were wrong, or etc. Basically I'm looking for functionality equivalent to errno for fopen() in plain C.
GCC seems to set errno properly, but that doesn't seem to be r... | In C++, when you attempt to open a file using `std::ifstream`, `std::ofstream`, or `std::fstream`, you can check if the open operation was successful using the `.fail()` or `.is_open()` methods. However, standard C++ does not provide a built-in way to get detailed error information about why the file opening failed (su... | 49,292 | [
{
"from": "human",
"value": "Is there any way to get a specific error condition when a C++ stream open fails? That is, whether it failed because the file didn't exist, or permissions were wrong, or etc. Basically I'm looking for functionality equivalent to errno for fopen() in plain C.\nGCC seems to set err... |
I'm writing a search & replace function in a kind of spreadsheet program. What I want is that if you search for a string, the program shows a table with the element that has been found.
So far so good, but I cannot get the element to obtain the focus, with the cursor in it so you can immediately start typing.
I'm using... | It sounds like you're on the right track with your implementation in Swing, but there are a few nuances to focus on when trying to set the focus on a cell editor after a search and replace operation. Here are a few suggestions and clarifications that might help you get the desired behavior.
### Focus and Timing
1. **I... | 47,090 | [
{
"from": "human",
"value": "I'm writing a search & replace function in a kind of spreadsheet program. What I want is that if you search for a string, the program shows a table with the element that has been found.\nSo far so good, but I cannot get the element to obtain the focus, with the cursor in it so y... |
Imagine I use the .NET graphic classes to draw a rectangle.
How could I then assign an event so that if the user clicks a certain point, or a certain point range, something happens (a click event handler)?
I was reading CLR via C# and the event section, and I thought of this scenario from what I had read.
A code exampl... | Certainly! To handle click events on a drawn rectangle in a .NET Windows Forms application, you can leverage the `MouseClick` event of a control (like a `Panel` or `Form`). Here's a step-by-step example demonstrating how to do this.
### Step 1: Create a Windows Forms Application
1. Open Visual Studio.
2. Create a new ... | 45,782 | [
{
"from": "human",
"value": "Imagine I use the .NET graphic classes to draw a rectangle.\nHow could I then assign an event so that if the user clicks a certain point, or a certain point range, something happens (a click event handler)?\nI was reading CLR via C# and the event section, and I thought of this s... |
I'm having trouble with TryUpdateModel(). My form fields are named with a prefix but I am using - as my separator and not the default dot.
<input type="text" id="Record-Title" name="Record-Title" />
When I try to update the model it does not get updated. If i change the name attribute to Record.Title it works perfectl... | Unfortunately, ASP.NET MVC's model binding does not directly support a custom separator like a hyphen (`-`). By default, it uses dots (`.`) as the separator for nested properties. This means that if you want to bind your model properties, the names in your form inputs need to follow the conventional pattern.
### Worka... | 44,357 | [
{
"from": "human",
"value": "I'm having trouble with TryUpdateModel(). My form fields are named with a prefix but I am using - as my separator and not the default dot.\n<input type=\"text\" id=\"Record-Title\" name=\"Record-Title\" />\n\nWhen I try to update the model it does not get updated. If i change th... |
This happens when compiling for Any Cpu as well as compiling to x86. Sections of the GUI doesn't redraw unless it's resized, for instance if the main form is maximized some of the controls don't resize with it, and others have sections that don't redraw and displays the what was previously there.
This works fine on 32... | The issue you are encountering with GUI redrawing on 64-bit Vista, especially when it works fine on 32-bit systems, can be tricky to diagnose. Here are some steps and considerations that might help you track down the root cause:
1. **Graphics Hardware Acceleration**: Disable hardware acceleration in your application (... | 48,906 | [
{
"from": "human",
"value": "This happens when compiling for Any Cpu as well as compiling to x86. Sections of the GUI doesn't redraw unless it's resized, for instance if the main form is maximized some of the controls don't resize with it, and others have sections that don't redraw and displays the what wa... |
I work with an application which uses rather big numbers and I need to store data as an unsigned 64-bit integer. I prefer to just store it without worrying about bit manipulation or anything like that so different programs can use the data in different ways.
| If you're looking to store large unsigned 64-bit integers (ranging from 0 to 18,446,744,073,709,551,615), there are several straightforward ways to handle this, depending on the context in which you're storing the data (e.g., in a database, a file, or directly in memory). Below are some common approaches to consider:
... | 47,482 | [
{
"from": "human",
"value": "I work with an application which uses rather big numbers and I need to store data as an unsigned 64-bit integer. I prefer to just store it without worrying about bit manipulation or anything like that so different programs can use the data in different ways. \n"
},
{
"... |
I have a mysql database set as utf-8, and csv data set as utf-8, delimited by semicolons and enclosed by double quotes.
The data Is seemingly imported fine, when doing a direct dump from the database.
However when attempting to display one of the fields containing html by echoing out in PHP, part of the html code is d... | The issue you're experiencing seems to stem from how HTML content is being echoed out in PHP. From your description, it looks like the HTML content in your database is being outputted directly into the browser, but it is not being handled properly by the `echo` statement, leading to part of the HTML tags being displaye... | 43,741 | [
{
"from": "human",
"value": "I have a mysql database set as utf-8, and csv data set as utf-8, delimited by semicolons and enclosed by double quotes. \nThe data Is seemingly imported fine, when doing a direct dump from the database.\nHowever when attempting to display one of the fields containing html by ech... |
I'm encountering problems with my .NET Framework 3.0 SP1 application. It is a C# winforms application communicating with a COM exe. Randomly either the winforms app or the COM exe crashes without any error message and the event log contains this entry:
[1958] .NET Runtime
Type: ERROR
Computer: CWP-OSL029-01
... | The error message you're encountering indicates a "Fatal Execution Engine Error," which generally points to a problem in the CLR (Common Language Runtime) that might stem from several potential issues. Here are some steps you can take to start troubleshooting this issue:
### 1. **Update the .NET Framework**
Ensure tha... | 45,792 | [
{
"from": "human",
"value": "I'm encountering problems with my .NET Framework 3.0 SP1 application. It is a C# winforms application communicating with a COM exe. Randomly either the winforms app or the COM exe crashes without any error message and the event log contains this entry:\n[1958] .NET Runtime\n T... |
Is it possible to send messages from a PHP script to the console in Eclipse? Has anyone attempted this already? I'm not very familiar with how the console works, so I'm not sure if there is a standardized method for communicating with it.
| Sending messages from a PHP script to the Eclipse console isn't straightforward because PHP typically runs in a web server environment or as a command-line script, whereas the Eclipse console is associated with the Eclipse IDE that is usually used for developing Java applications. However, you can achieve console outpu... | 46,652 | [
{
"from": "human",
"value": "Is it possible to send messages from a PHP script to the console in Eclipse? Has anyone attempted this already? I'm not very familiar with how the console works, so I'm not sure if there is a standardized method for communicating with it.\n"
},
{
"from": "gpt",
"valu... |
I'm wondering if there is any way to create a User Account on a Windows XP machine that can be done through scripting from an ActiveX control on a webpage. Specifically, I'd like to know if there's any way to deploy an ActiveX control with computers (that I preconfigure and ship) that will allow use of my webpage from... | Creating a user account on a Windows XP machine through an ActiveX control from a webpage involves significant security implications and technical challenges. Here's a breakdown of the relevant points:
### Security Considerations
1. **ActiveX Controls**: While ActiveX controls can interact with the operating system, t... | 48,550 | [
{
"from": "human",
"value": "I'm wondering if there is any way to create a User Account on a Windows XP machine that can be done through scripting from an ActiveX control on a webpage. Specifically, I'd like to know if there's any way to deploy an ActiveX control with computers (that I preconfigure and shi... |
In windows there is perfmon to monitor various performances aspects (called counters) of the system.
Is there a perfmon-like for Linux?
especially, in interested in...
CPU usage (total/per process/in kernel)
Memory usage (total/per process/in kernel)
...Is it possible to store this information in files for future ana... | Yes, Linux provides several tools that are similar to Windows' Perfmon for monitoring performance metrics like CPU and memory usage. Here are some common tools and methods you can use:
### 1. **top / htop**
- **top**: A command-line utility that provides real-time system monitoring for CPU usage, memory usage, and mor... | 48,833 | [
{
"from": "human",
"value": "In windows there is perfmon to monitor various performances aspects (called counters) of the system.\nIs there a perfmon-like for Linux?\nespecially, in interested in...\n\nCPU usage (total/per process/in kernel)\nMemory usage (total/per process/in kernel)\n\n...Is it possible t... |
I have a web-server, that serves different domain-names, but has only one IP-address assigned. That works fine with virtual hosts in Apache. Now I want SSL-encrypted connections for the websites. How can I set different SSL-certificates for the different vhosts?
Using different IP's for the different hostnames would be... | To serve multiple SSL certificates for different virtual hosts on a single IP address in Apache, you can use **SNI (Server Name Indication)**, which is an extension to the TLS networking protocol. SNI allows the server to present multiple SSL certificates on the same IP address and port number. Here’s how to set it up:... | 45,340 | [
{
"from": "human",
"value": "I have a web-server, that serves different domain-names, but has only one IP-address assigned. That works fine with virtual hosts in Apache. Now I want SSL-encrypted connections for the websites. How can I set different SSL-certificates for the different vhosts?\nUsing different... |
What exactly is a learning curve?
And why is it wrong to use the term "steep learning curve" for something which has high entry barriers and takes quite some time to get into?
As to the why-ness of this question:
The terms are used often and inconsistently on Stack Overflow
I myself have been confused by it
Mostly t... | A **learning curve** is a graphical representation of the rate at which a person learns a new skill over time. It shows the relationship between the proficiency of a learner and the experience or time spent learning the skill. Generally, it illustrates that as a person practices and gains experience, their proficiency ... | 48,227 | [
{
"from": "human",
"value": "\nWhat exactly is a learning curve?\nAnd why is it wrong to use the term \"steep learning curve\" for something which has high entry barriers and takes quite some time to get into?\n\nAs to the why-ness of this question:\n\nThe terms are used often and inconsistently on Stack Ov... |
I have a web site that is a customer to customer (C2C) service. Example, a user is looking for a hockey card of Gordie Howe and another customer wants to sell a Gordie Howe hockey card. If they sell the card 100$, I'd like to have 90$ that goes to the seller and 10$ that goes to me for providing the service (some kind ... | Yes, you can achieve a split payment model like the one you described using PayPal, specifically through their PayPal Commerce Platform or using PayPal's "Payouts" feature. Here are a few options:
### 1. **PayPal Commerce Platform (Adaptive Payments)**
**Note:** PayPal Adaptive Payments has been deprecated for new us... | 45,424 | [
{
"from": "human",
"value": "I have a web site that is a customer to customer (C2C) service. Example, a user is looking for a hockey card of Gordie Howe and another customer wants to sell a Gordie Howe hockey card. If they sell the card 100$, I'd like to have 90$ that goes to the seller and 10$ that goes to... |
When I try to create a Excel or Word workbook project in VS, I get the message:
A compatible version of Microsoft
Office is not installed on this
computer. You must install the
version of Office that is compatible
with your project. In addition,
repair the version of the Visual
Studio Tools for Office r... | It sounds like you are facing compatibility issues between Visual Studio 2008 (VS 2008) and Microsoft Office 2003. Here are some steps and tips you can try to resolve the issue:
1. **Check Compatibility**: Ensure that the Visual Studio Tools for Office (VSTO) you are using is compatible with Office 2003. For VS 2008, ... | 47,723 | [
{
"from": "human",
"value": "When I try to create a Excel or Word workbook project in VS, I get the message: \n\nA compatible version of Microsoft\n Office is not installed on this\n computer. You must install the\n version of Office that is compatible\n with your project. In addition,\n repair the v... |
Can anyone recommend any programmer-friendly (i.e. extensible) frameworks or systems for performing network level packet fuzzing?
I'm looking for such a system where I can program in additional packet formats and various ways of breaking those packets in a protocol-dependent manner.
I know how to Google. I'm looking f... | Here are several programmer-friendly frameworks and systems that are well-suited for network-level packet fuzzing and can be easily extended for different protocols:
1. **Peach Fuzzer**: Peach is a versatile fuzzing framework that allows for protocol definition and is highly extensible. You can define packet formats u... | 49,443 | [
{
"from": "human",
"value": "Can anyone recommend any programmer-friendly (i.e. extensible) frameworks or systems for performing network level packet fuzzing?\nI'm looking for such a system where I can program in additional packet formats and various ways of breaking those packets in a protocol-dependent ma... |
I want to make a WPF Window that behaves like a context menu.
So, for instance - when I show the wpf window, I want it to be the topmost window and from there on out, if the user clicks anything outside of that window I want the window to be hidden again.
So far I have tried quite a few techniques but the only one that... | To create a WPF window that behaves like a context menu, you want to make sure that it remains topmost and hides itself when the user clicks outside of it. Below is an approach that uses a combination of event handling and some state management to achieve this.
Here's an example implementation:
1. **Create the WPF Wi... | 49,004 | [
{
"from": "human",
"value": "I want to make a WPF Window that behaves like a context menu.\nSo, for instance - when I show the wpf window, I want it to be the topmost window and from there on out, if the user clicks anything outside of that window I want the window to be hidden again.\nSo far I have tried q... |
The following is a simplified version of what I'm trying to do, because I'm sure you don't want to wade through an entire set of structs and function prototypes for a particle system.
float const materials[24][4][4] = {{{...}}};
typedef struct EmitterStruct { float *material[4][4]; } Emitter;
typedef struct ParticleSt... | The issues you're facing stem from how you're handling arrays and pointers in C. Let's break down the problems and see how you can achieve your goal of creating an emitter, storing a 4x4 material array, and then copying that material into a particle.
1. **Pointer Type Mismatch**: The `Emitter` struct has a member `flo... | 46,067 | [
{
"from": "human",
"value": "The following is a simplified version of what I'm trying to do, because I'm sure you don't want to wade through an entire set of structs and function prototypes for a particle system.\nfloat const materials[24][4][4] = {{{...}}};\ntypedef struct EmitterStruct { float *material[... |
I get the correct results (nov and dec data) when I run a query in the Data tab of a report that I built in SQL Server Reporting Services. When I preview the report I get old data from October. It doesn't make any sense to me. I'm not sure whats going on. Note: the data is in Oracle.
Here's the date filter I'm using
... | It sounds like you are encountering a caching issue in your SQL Server Reporting Services (SSRS) report when you preview it. Here are a few potential reasons and solutions for why you might be seeing old data in the Preview tab:
1. **Cached Data in SSRS**:
- When you preview a report in SSRS, it may use cached data... | 47,882 | [
{
"from": "human",
"value": "I get the correct results (nov and dec data) when I run a query in the Data tab of a report that I built in SQL Server Reporting Services. When I preview the report I get old data from October. It doesn't make any sense to me. I'm not sure whats going on. Note: the data is in ... |
Is it a good idea to share views between different controllers (using the Views/Shared folder)? I am creating my first MVC application and it requires some pieces of data that are similar to each other. They "explain" different things (and will therefore be stored in different tables) but they each have an Id, Name and... | Using a shared view in an MVC application can be a great way to promote code reusability and maintainability, especially when dealing with similar data structures. Here are some considerations to help you decide if sharing views is the right approach for your situation:
### Pros of Using Shared Views
1. **Code Reusab... | 45,911 | [
{
"from": "human",
"value": "Is it a good idea to share views between different controllers (using the Views/Shared folder)? I am creating my first MVC application and it requires some pieces of data that are similar to each other. They \"explain\" different things (and will therefore be stored in different... |
Is it possible to use a DB sequence for some column that is not the identifier/is not part of a composite identifier?
I'm using hibernate as jpa provider, and I have a table that has some columns that are generated values (using a sequence), although they are not part of the identifier.
What I want is to use a sequenc... | Yes, it is indeed possible to use a database sequence to generate a value for a non-primary key column in a JPA entity when using Hibernate as your JPA provider. However, your current setup is not quite correct in terms of annotations and Hibernate's behavior with respect to `@GeneratedValue`.
In JPA and Hibernate, th... | 48,284 | [
{
"from": "human",
"value": "Is it possible to use a DB sequence for some column that is not the identifier/is not part of a composite identifier? \nI'm using hibernate as jpa provider, and I have a table that has some columns that are generated values (using a sequence), although they are not part of the i... |
I've been trying to build a simple prototype application in Django, and am reaching the point of giving up, sadly, as it's just too complicated (I know it would be worth it in the long-run, but I really just don't have enough time available -- I need something up and running in a few days). So, I'm now thinking of goin... | I can understand your frustration, especially when you're pressed for time and trying to learn a new framework like Django. It can indeed be challenging when you're not familiar with the conventions and patterns that frameworks impose. That said, let's explore your options regarding PHP and how it can interact with oth... | 46,122 | [
{
"from": "human",
"value": "I've been trying to build a simple prototype application in Django, and am reaching the point of giving up, sadly, as it's just too complicated (I know it would be worth it in the long-run, but I really just don't have enough time available -- I need something up and running in ... |
I am working on a system that processes documents that are dumped into a target directory. I pick up the files by detecting the FileSystemWatcher OnChanged event.
As part of a unit test, how should I go about automating this? How should I organize the input files and the output files that get compared to verify that ... | Automating the testing of a system that processes documents using a `FileSystemWatcher` can be effectively organized through careful planning and organization of your input and output files. Here's how you can structure your tests and the testing process:
### 1. Structure Your Files
**Input Directory:**
- Create a d... | 49,132 | [
{
"from": "human",
"value": "I am working on a system that processes documents that are dumped into a target directory. I pick up the files by detecting the FileSystemWatcher OnChanged event.\nAs part of a unit test, how should I go about automating this? How should I organize the input files and the outp... |
I'm trying to get a dynamic movie clip from the timeline.
I have a timeline of unknown length with a movie clip with instance name "blah" on one of the key frames (assumed 88 in this case).
No matter what I do, I cannot get a reference to the said movie clip.
Here's what I tried:
trace(blah); // null
trace(this.blah);... | It looks like you're trying to access a movie clip from the timeline in ActionScript, but you're encountering issues with it returning `null`. Here are some key points to consider when trying to access a dynamically created movie clip:
1. **Instance Name and Scope**: Make sure that the instance name "blah" is actually... | 49,797 | [
{
"from": "human",
"value": "I'm trying to get a dynamic movie clip from the timeline.\nI have a timeline of unknown length with a movie clip with instance name \"blah\" on one of the key frames (assumed 88 in this case).\nNo matter what I do, I cannot get a reference to the said movie clip. \nHere's what I... |
We are making an automated patching application and would like to post files on production server through asp.net page (or maybe a web service), since we can only access production server via http. The page should accept files and store them to appropriate location. The path to files will be declared in external XML fi... | Yes, it is indeed possible to post files encoded in Base64 to an ASP.NET application and subsequently save them to a specified location on the server. Below are the steps you can take to implement this, as well as some considerations for security and efficiency.
### Overview of the Approach:
1. **Create an ASP.NET We... | 45,770 | [
{
"from": "human",
"value": "We are making an automated patching application and would like to post files on production server through asp.net page (or maybe a web service), since we can only access production server via http. The page should accept files and store them to appropriate location. The path to ... |
I am having problems connecting to a Sqlite database through System.Data.Sqlite. I was trying to use FluentNhibernate but that didn't work, so I went back to basics but got the same error: Cannot find entry point sqlite3_open_v2 in DLL sqlite3.
This is my (fairly simple I believe) code:
using (SQLiteConnection connecti... | The error message you're encountering, "Cannot find entry point sqlite3_open_v2 in DLL sqlite3," suggests that your application is unable to find the correct SQLite native library or that there is a version mismatch. Here are a few steps you can follow to troubleshoot and resolve the issue:
1. **Check SQLite DLL Refer... | 46,775 | [
{
"from": "human",
"value": "I am having problems connecting to a Sqlite database through System.Data.Sqlite. I was trying to use FluentNhibernate but that didn't work, so I went back to basics but got the same error: Cannot find entry point sqlite3_open_v2 in DLL sqlite3.\nThis is my (fairly simple I belie... |
I got a table with a custom TableCellEditor (extending DefaultCellEditor) with a JFormattedTextField as the editor component.
Now I got problem: when I press a separate button while editing. When the button is pressed, the editor remains "open and active" while I'd want it to stop editing so that the changes made would... | To ensure that the editing is stopped when you press a button, you can explicitly call the stopCellEditing() method on the TableCellEditor associated with your JTable. This will commit the changes made in the JFormattedTextField and make them available for any operations triggered by the button.
Here’s how you can imp... | 49,297 | [
{
"from": "human",
"value": "I got a table with a custom TableCellEditor (extending DefaultCellEditor) with a JFormattedTextField as the editor component.\nNow I got problem: when I press a separate button while editing. When the button is pressed, the editor remains \"open and active\" while I'd want it to... |
Can anyone provide a good example of IHttpHnalder for handling Image Type. I want to resize the image that's hosted on my server
| Certainly! If you want to handle image resizing in an ASP.NET application using `IHttpHandler`, you can create a custom HTTP handler that processes image requests and resizes the images as needed. Below is a simple example of how to implement such a handler.
### Step 1: Create the Image Resizing Handler
1. Create a n... | 48,508 | [
{
"from": "human",
"value": "Can anyone provide a good example of IHttpHnalder for handling Image Type. I want to resize the image that's hosted on my server\n"
},
{
"from": "gpt",
"value": "Certainly! If you want to handle image resizing in an ASP.NET application using `IHttpHandler`, you can c... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.