default

Why doesn't the C++ default destructor destroy my objects?

The C++ specification says the default destructor deletes all non-static members. Nevertheless, I can't manage to achieve that. I have this: class N { public: ~N() { std::cout << "Destroying object of type N"; } }; class M { public: M() { n = new N; } // ~M() { //this should happen by default // d...

Oracle Weblogic JNDI Datasource set Default Auto Commit

Hi. In my J2ee web application I am using a datasource accessed stored in the weblogic server and accessed through jndi. In normal datasource bean declaration there is a property defaultAutoCommit which can be set to false. Is there a similar property or is there a way to set something like this when using datasource in JNDI. Because cur...

Settings end up in user.config even though they are unmodified as read from app.config

Consider a C# app which has a number of user settings, some are actively used and updated and others are always read-only. Under which circumstances can such a read-only settings property end up in a per user maintained user.config? I am seeing a funny behavior that several user configuration settings that app merely reads end up in use...

Custom Message Box: Windows' "Move Cursor to Default Button" Feature

In Microsoft Windows, there is a (highly useful) feature that automatically moves the cursor to the default button of a modal dialog box (activated in Win+R, "control mouse"). Now I have created a custom dialog box in Delphi (basically a TForm), see below. But, quite naturally, the cursor does not automatically move to the default bu...

Default values of parametrs for own functions in jquery

Is it possible to set default values of parametrs for own functions in jquery? ...

.Net Inherited Control Property Default

Hello fellows Im trying to make a simple "ButtonPlus" control. the main idea is to inherit from the button control and add some default property values (such as font,color,padding...) No matter how i try, the WinForm always generates (or "serializes") the property value in the client forms the whole point is to have minimal and clean c...

Is it wise to rely on default features of a programming language?

Should I frequently rely on default values? For example, in PHP, if you have the following: <?php $var .= "Value"; ?> This is perfectly fine - it works. But what if assignment like this to a previously unused variable is later eliminated from the language? (I'm not referring to just general assignment to an unused variable.) There...

Does Apache need to be stopped to edit "/etc/apache2/sites-available/default"?

I am attempting to edit the "default" file located at .. "/etc/apache2/sites-available/default" on my Ubuntu machine running Apache 2.2.8. I want to do this in order to enable the use of .htaccess files. I have downloaded the "default" file and edited it and now I am trying to upload it back to the server via SFTP. I keep getting p...

Where can I find a list of Hibernate default configuration settings?

I'm looking for a list of hibernate configuration settings with the defaults listed. I found a good list of settings here: http://docs.jboss.org/hibernate/core/3.3/reference/en/html/session-configuration.html ...but the default settings are not listed. ...

Qt: default value of variable in class

When creating my own class in Qt I would like my variables in the class to have a standard/default value if I haven't set them to anything. It would be perfect if this was possible to set in the h-file so I don't have to do it in each instance method of my class. You can see what I want to do in the code below. In the example myBool woul...

Default value of a type

For any given type i want to know its default value. In C#, there is a keyword called default for doing this like object obj = default(Decimal); but I have an instance of Type (called myType) and if I say this, object obj = default(myType); it doesn't work Is there any good way of doing this? I know that a huge switch block will ...

Error when changing default lanuage in asp.net compilation from vb to c#

Hi all, We have a updatable web site project that is written in c#, it has the usual web form implementation using master page, skins, user controls,...etc. Up to this point we neglect to change the default compilation language from VB to C#. However, the second we change it, we see the following error. Object reference not set to an...

Screen saver is not set as default screen saver on MAC

I have developed a screen saver application for MAC OS X 10.6. I am setting our screen saver information in screen saver plist using installer. When i check information in plist just after installation, It shows right information also run our screen saver as default but when I open system preferences window, It start flurry screen saver ...

how to set a new value for a dijit.InlineEditBox

Hi All, i have problems to set a returned value to a declarative dijit.InlineEditBox the most near to a final solution was function(field,val,pid) { switch (field) { case 1: cell_name = "off_"+pid; break; case 6: cell_name = "saleprice_"+pid; break; default: break; } cell...

SSRS date default with formula disables parameter

When I set a default value formula for a date parameter in SSRS, such as: =CDate(”01/” & Month(Now) & “/” & Year(Now)) or even: =Now The date parameter control becomes disabled with nothing in it. Anyone know what simple thing (I am sure) I am doing wrong? ...

Resource files for Company-wise Label Values - Implicit calling of Global Resources

We have several companies using one web application. Companies may decide to display different values in Labels. e.g. CompanyA -> ZipCodeCaption = "Zip Code" CompanyB -> ZipCodeCaption = "Pin Code" CompanyA -> USDSymbolCaption = "USD" CompanyB -> USDSymbolCaption = "$" Currently, we have different settings saved for different compa...

default value for a static property

I like c#, but why can I do : public static bool Initialized { private set; get; } or this : public static bool Initialized = false; but not a mix of both in one line ? I just need to set access level to my variable (private set), and I need it set at false on startup. I wouldn't like to make that boring private _Initialized varia...

Indicating a user default value - flex

This was just what I was thinking for this solution and I would like to know if there's a better approach I could take? I'm creating a simple desktop contacts application. Users have the ability to enter in peoples contact information. I've add a combo box containing city name. The user has the ability to add city to this list and then...

Question About DateCreated and DateModified Columns - SQL Server

CREATE TABLE Customer ( customerID int identity (500,20) CONSTRAINT . . dateCreated datetime DEFAULT GetDate() NOT NULL, dateModified datetime DEFAULT GetDate() NOT NULL ); When i insert a record, dateCreated and dateModified gets set to default date/time. When i update/modify the r...

My defualt text is appear first then after a few second my replacement text appears

It looks awful. Please have a look at absolute-websites.com/portfolio and you'll see what I mean. What an I do to fix this please? ...