I got into an interesting discussion in a forum where we discussed the naming of variables.
Conventions aside, I noticed that it is legal for a variable to have the name of a Unicode character, for example the following is legal:
int \u1234;
However, if I for example gave it the name #, it produces an error. According to Sun's tutori...
this can't be too complex but it is baffling me - I would like to pass a variable through a url (www.site.com/index.html?var=whatever.htm) and use the variable within an onclick function so that the onclick button uses the variable as the url to go to..onclick.
I am trying to do this in place of a history button, since the button is wi...
Provided that we know that all the file will be loaded in memory and we can afford it,
what are the drawbacks (if any) or limitations (if any) of loading an entire file (possibly a binary file) in a python variable. If this is technically possible, should this be avoided, and why ?
Regarding file size concerns, to what maximum size this...
Hello everyone,
I realize this is a pretty open question and could get a variety of answers, but here goes.
Using C# (or Java, or any OO language), is there a general rule that states how many variables should be passed into the constructor? The number of variables I am passing into the constructor of the extended classes seem to be g...
hi all
i created a configure.ac file like this:
AC_INIT()
set
the purpose of this is to print every available environment variable the configure
script creates using 'set'
so i do:
user@host:~$ autoconf
user@host:~$ ./configure
which prints a bunch of variables like
build=
cache_file=/dev/null
IFS='
'
LANG=C
LANGUAGE=C
d...
Hi-- I think this is probably something really simple, but I'd appreciate a hint:
I am using a python list to hold some some database insert statements:
list = [ "table_to_insert_to" ],["column1","column2"],[getValue.value1],["value2"]]
The problem is one of the values isn't evaluated until runtime-- so before the page even gets run,...
Within an SSIS package I have a dataflow that extracts two coloumns from an access database a TaskID and a date
I store this in a ADO recordset and pass this to a For Each Loop Container
I am them attempting to assign each value pair to two variables "taskID" and "taskDate"
I then want to use thse two variables within a SQL Insert task...
I have a bug on my plate to locate and rewrite a static variable in one of our libraries that is taking up launch time in our application. I am not familiar with the library code base and am asking for good heuristics/techniques/grep commands/etc. that would ease my task in identifying the location of said static variable?
(P.S. I'm alr...
When I'm writing scripts in PHP to work with MySQL databases with a MEMORY storage engine, is it as fast as PHP variables? Can I consider using such a database in place of some variables for buffers, message queues, etc?
...
Hi,
I was wondering how to add custom configuration variables to a rails application and how to access them in the controller, for e.g I wanna be able to define an upload_directory in the configuration files say development.rb and be able to access it in one of my controllers.
Secondly I was planning to have S3 support for uploads in m...
Hi everyone,
I'd like to fire a function. Unfortunately I can't call it directly as the functions' name is provided as a string.
Example:
function myFunction() {
alert('I am myFunction');
}
function anotherFunction() {
alert('I am anotherFunction');
}
var func_name = 'myFunction';
$obj = jQuery('a');
$obj.each(function(){
...
I have a module Routines.pm:
package Routines;
use strict;
use Exporter;
sub load_shortest_path_matrices {
my %predecessor_matrix = shift;
my %shortestpath_matrix = shift;
...
}
From another script I call the the sub in the module, passing in arguments which happen to have the same name:
use Routines;
use strict;
my %predeces...
I have a boolean global variable that is set true if an administrator is logged in and wants to amend the content of the lists and comboboxes. As a result, a button is displayed beside each combo to display a dialog box when clicked.
If I was not coding for WPF, I would probably include some sort of code similar to the following in each...
how I can call a variable (private Label ccc;) in another event:
private Label ccc;
protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e)
{
Label Label1 = FindControlRecursive(Page, DropDownList1.SelectedValue) as Label;
if (Label1 != null)
this.ccc = lblCont;
thi...
I'm moving a PHP site from development to a production server and testing the new database connection. I have a config.php page that has only this (but with real data):
<?php
// Database Constants
defined('DB_SERVER') ? null : define('DB_SERVER', 'xxx.xxx.xxx');
defined('DB_PORT') ? null : define('DB_PORT', 'yyy');
def...
I am using an ENUM data type in MySQL and would like to reuse it, but not retype in the values. Is there an equivalent to the C, C++ way of defining types in MySQL?
I would like to do the following:
DEFINE ETYPE ENUM('a','b','c','d');
CREATE TABLE Table_1 (item1 ETYPE, item2 ETYPE);
Is this possible?
Thanks
...
I'm trying to find a way to lazily load a module-level variable.
Specifically, I've written a tiny Python library to talk to iTunes, and I want to have a DOWNLOAD_FOLDER_PATH module variable. Unfortunately, iTunes won't tell you where its download folder is, so I've written a function that grabs the filepath of a few podcast tracks and ...
Hi All,
Can anyone tell me how can i use a varaible foe button text in jquery dialogs .
I want to make a dynamic button name.
...
Hi, All,
I started to learn Flex and ActionScript and encountered interesting statement: untyped variable. That is:
var x:*;
or just
var x;
I found out that they can hold undefined values. Variables of Object type cannot. But I don't understand the purport of them. I don't think that someone often need to distinguish undefined and...
Hello All,
It's well known fact that static variable cannot be used in
Web Application as it remains static through out application.But,is there any scenario where static variable can be used in Web Application to achieve the functionality?
Thanks
...