default

How to set gtk file chooser button default to user's home folder

I've got a gtk file chooser button on my application I am writing in c# using Mono Develop. I would like to set the file chooser's default location to the users' home directory regardless of what user is running it. I've tried the ~/ short cut - fchFolder1.SetCurrentFolder("~/"); - but this did not work. I was just wondering if there wa...

Default Eclipse preferences

Hi everyone, I have previously exported the default preferences but accidentally deleted it. Is there anywhere I can download the default set of preferences from? I am running the latest version on Mac OS X. Thanks, Dany. ...

map<int,int> default values

Hello. I have this : std::map<int,int> mapy; ++mapy[5]; Is it safe to assume that mapy[5] will always be 1? I mean, will mapy[5] always get the default value of 0 before '++', even if not explicitly declared, as in my code? Cheers ...

Gravatar : Is there a default image?

I have implemented gravatar for a portal I am building and wanted to know if there is a default image URL for gravatar? Not all people who visit the site are logged in or have email addresses, in such a case, is there a default image that can be shown (accessible via gravatar url) ...

Android Preferences: How to load the default values when the user hasn't used the preferences-screen?

I am using a PreferenceActivity to let the user set some values. I am feeding it the xml file with the defined preferences. I have set all the android:defaultValue="" for them. When I start my application, I need the preferences, or if they are not set yet manually, I want the default values: SharedPreferences prefs = PreferenceManage...

jQuery preventDefault stops rest of code working

I have this code where I am using jQuery to navigate to the next page, because I want some effects to take place before that happens. The problem is, that everything after the prevent.Default(); doesn't seem to work! $("a").click(function(event){ event.preventDefault(); $(".content-center").animate({height: "0px"}, 500); nav...

Using alternative content if url for flash file is bad

I am trying to display a default swf file in case the supplied url for the swf file is not a valid one. Can somebody suggest a good way to do this? ...

How do set default values in django for an HttpRequest.GET?

I have a webpage that displays data based on a default date. The user can then change their view of the data by slecting a date with a date picker and clicking a submit button. I already have a variable set so that if no date is chosen, a default date is used.... so what's the problem? The problem comes if the user trys to type in the...

setting default values for empty nodes

Hello all I need to transform a piece of XML, so that the value of every node in a list I specify is set to "0" for example: <contract> <customerName>foo</customerName> <contractID /> <customerID>912</customerID> <countryCode/> <cityCode>7823</cityCode> </contract> would be transformed into <contract> <customerName>foo</custo...

Set a project default for VB.NET projects so that the default Modifiers property for controls is Private

Is it possible to set a project default for VB.NET winforms projects so that the default Modifier for controls added to winforms is Private (not Friend)? I know there's a "modifiers" property in the properties window so I can set it for each individual control... however I would like to change the project so from now on myself and other...

Is it possible to set a default behaviour for custom (non-native) methods/functions in Java?

Is it possible to set a default behaviour for custom (non-native) methods/functions in Java? For example, I would like to change the default "Function" to do a System.out.println("message") whenever called. So, when a custom method/function is being created: public String testMethod() { //custom code } it should execute the newly...

How to get the default gmail user name and password of one android cell phone

How to get the default gmail user name and password of one android cell phone during developing android program. ...

Android: get the default gmail username and password

Now I am doing a android porjct. The project needs get the default username and password of Android phone. I don't know how to get the default gmail information of one Android Cell Phone. Can u help me. Thx. ...

MVVM Focus To Textbox

How would I set focus to a textbox without specifying the name for that textbox? At the moment I am doing the following <Window FocusManager.FocusedElement="{Binding ElementName=Username}"> <Grid> <TextBox Text="{Binding Username}" Name="Username" /> </Grid> </Window> Is there any way of doing this without ...

Codeigniter only loads the default controller

I am very new to CodeIgniter, but have been programming PHP for ages. I'm writing some software at the moment and using CI for the first time with it. The default controller is set to the first controller I want to action call 'login' (the controller is login.php, the view is login.php. When the form is submitted it calls the 'authent...

Default value list for pipeline param in Powershell

I have a Powershell script that reads values off of the pipeline: PARAM ( [Parameter(ValueFromPipeline = $true)] $s ) PROCESS { echo "* $s" } Works just fine: PS > my.ps1 foo * foo I would like the script to have list of default values, as the most common usage will always use the same values and storing them in...

Please tell me what is use of "default" keyword in c#.net

I have got following code: I have a enum: public enum HardwareInterfaceType { Gpib = 1, Vxi = 2, GpibVxi = 3, } and m using this enum like this : HardwareInterfaceType type = default(HardwareInterfaceType); please tell me what is keyword "default" is doing here? what is the use of it? ...

Error: default parameter given for parameter 1

Here is my class definition: class MyClass { public: void test(int val = 0); } void MyClass::test(int val = 0) { // } When I try to compile this code I get the error: "default parameter given for parameter 1" It's just a simple function, I don't know what's wrong. I'm using Eclipse + MinGW. ...

Does a syntax for this exist? In any language?

It seems pretty common to me to have an argument, in a dynamically typed language that is either an Object or a key to lookup that object. For instance when I'm working with a database I might have a method getMyRelatedStuff(person) All I really need to lookup the related stuff is the id of the person so my method could look like this i...

Help With LINQ: Mixed Joins and Specifying Default Values

I am trying to figure out how to do a mixed-join in LINQ with specific access to 2 LINQ objects. Here is an example of how the actual TSQL query might look: SELECT * FROM [User] AS [a] INNER JOIN [GroupUser] AS [b] ON [a].[UserID] = [b].[UserID] INNER JOIN [Group] AS [c] ON [b].[GroupID] = [c].[GroupID] LEFT JOIN [GroupEn...