I have a set of callback classes that I use for handling callbacks with variable numbers of parameters. Right now I have about 6 different instances of it to handle differing numbers of arguments. Is there a way to make one instance than can handle a variable number of arguments?? Ultimately I would love to have each parameter be a POD t...
When verbally talking about methods in C# during a code review or in pairing I'm never sure whether to use the word argument or parameter or something else. Either way the other people know what I mean but what's correct and what's the history of the terms?
Would people use different terms in different languages?
For the record I'm sel...
Hello,
I am not sure if I formulated the question right, but still ...
I have a view that shows a flash embed and this flash take as parameter a /controller/action URL that generates a XML. I nee to send, from this view, an array to the XML generator action. How is the best way ? Is there some helper->set() method like or I have to cre...
Routines can have parameters, that's no news. You can define as many parameters as you may need, but too many of them will make your routine difficult to understand and maintain.
Of course, you could use a structured variable as a workaround: putting all those variables in a single struct and passing it to the routine. In fact, using st...
Is it possible to get the text of an OleDbCommand with all parameters replaced with their values? E.g. in the code below I'm looking for a way to get the query text
SELECT * FROM my_table WHERE c1 = 'hello' and c2 = 'world'
after I finished assigning the parameters.
var query = "SELECT * FROM my_table WHERE c1 = ? and c2 = ?";
var c...
I have a function that looks like this
class NSNode {
function insertAfter(NSNode $node) {
...
}
}
I'd like to be able to use that function to indicate that the node is being inserted at the start, therefore it is after nothing. The way I think about that is that null means "nothing", so I'd write my function call like...
I am using a Session Parameter on an ObjectDataSource. It works fine on the local development machine but I get this error after copying the website to the production server:
Type 'System.Web.UI.WebControls.SessionParameter' does not have a public property named 'DbType'.
...
We have a web application that passes parameters in the url along the lines of this:
www.example.com/ViewCustomer?customer=3945
Reasonably often, we will see attempts to access just:
www.example.com/ViewCustomer
Or system logs this as invalid and sends back a "An error has occurred, contact support with trace number XXX" type page....
I've googled around a bit, but maybe I didn't put the correct magik incantation into the search box.
Does anyone know how to get output parameters from a stored procedure in Python? I'm using pymssql to call a stored procedure, and I'm not sure of the correct syntax to get the output parameter back. I don't think I can use any other db...
Take this non-compiling code for instance:
public string GetPath(string basefolder, string[] extraFolders)
{
string version = Versioner.GetBuildAndDotNetVersions();
string callingModule = StackCrawler.GetCallingModuleName();
return AppendFolders(basefolder, version, callingModule, extraFolders);
}
private string AppendFolder...
Is there a good method for writing C / C++ function headers with default parameters that are function calls?
I have some header with the function:
int foo(int x, int y = 0);
I am working in a large code base where many functions call this function and depend on this default value. This default value now needs to change to something ...
I'm working on an application for work that is going to query our employee database. The end users want the ability to search based on the standard name/department criteria, but they also want the flexibility to query for all people with the first name of "James" that works in the Health Department. The one thing I want to avoid is to si...
Apparantly, they're "confusing". Is that seriously the reason? Can you think of any others?
...
I have search in MSDN and I can't figure where are the POST parameters from HttpListenerRequest?
Any idea?
*QueryString seem to have only Get parameter not post
...
How do I pass a parameter from a page's useBean in JSP to a servlet in Java? I have some data in a form that gets passed no problem with a submit button, but no way to send anything else. Please help? Here is my code:
<input name = "deleteGameButton" type = "submit" value = "Delete"
onclick = "submitToServlet('DeleteGameServlet');">
...
I'm new to CakePHP but I've been though their FAQs and guides to no avail. This is so simple that I just must not be thinking straight:
How can I access a parameter sent through the URL within my view files?
Example: http://example.com/view/6
How would I take that parameter ("6") and cycle it through the controller to another view p...
I'm new to ASP.NET MVC so this may be a stupid question.
I have an account object that has many parameters. I've figured out a strategy to break this down into a "wizard"-like interface that will walk a user through collecting the required fields to create the initial business objects. It will then step through pages to collect other, ...
Would there a more elegant way of writing the following syntax?
Thread t0 = new Thread(new ParameterizedThreadStart(doWork));
t0.Start('someVal');
t0.Join();
Thread t1 = new Thread(new ParameterizedThreadStart(doWork));
t1.Start('someDiffVal');
t1.Join();
Presuming we want to pass 20 d...
I've got a (SQL Server 2005) database where I'd like to create views on-the-fly. In my code, I'm building a CREATE VIEW statement, but the only way I can get it to work is by building the entire query string and running it bare. I'd like to use parameters, but this:
SqlCommand cmd = new SqlCommand("CREATE VIEW @name AS SELECT @body");...
I'm kind of new to C++ and have some questions, this is one of them.
Is there ANY reason when you are using a function that takes in one or several parameters, parameters of which you know will always be stored in a variable before the function call, to pass a copy of the variable, rather than a pointer to the variable?
I'm talking in...