parameter-passing

getting parameters from a url returns 'parameter is undefined"

主宰稳场 提交于 2020-01-06 01:17:13
问题 It's a simple question but the answer seems to elude me. I am trying to pass a parameter to a script in the following way: https://script.google.com/macros/s/AKfycbzygHQ2qQ.../exec?id=1234&value=Hello The script is a simple one: function doGet(e) { Logger.log('in doGet function'); for (var i in e.parameter) { Logger.log('parameter ' + i+1 + ' is ' + e.parameter[i]); } } and getting the following in the execution transcript: [13-10-01 10:21:20:722 ICT] Starting execution [13-10-01 10:21:20:734

jquery getting GET variables from javascript file

我与影子孤独终老i 提交于 2020-01-05 08:53:09
问题 I have a link, and when a user clicks it, it pushes a javascript file onto the page. in addition to that, it adds on parameters to the javascript src example: <script type="text/javascript" src="javascripfile.js?r=some%values&u=more&values"> This isn't getting passed through URL on browser. I was wondering how I would get these parameters inside javascriptfile.js? javascriptfile.js : (function(){ //how to get r value, u value? }()); Thanks for your help! 回答1: Please try this: http://jsfiddle

Giving arguments from “…” argument to right function in R [duplicate]

喜夏-厌秋 提交于 2020-01-04 07:37:07
问题 This question already has answers here : Split up `…` arguments and distribute to multiple functions (3 answers) Closed 3 years ago . I have a function to compute the correlation of matrix of both categorical and continuous variables: correlation <- function(matrix, ...) { xx <- do.call(rbind, lapply(colnames(mtrc), function(ex_i) { ty_i <- wtype(matrix, ex_i) yy <- sapply(colnames(mtrc), function(ex_j) { ty_j <- wtype(matrix, ex_j) if(ty_i == "numeric" & ty_j == "numeric") { cor(mtrc[ , c(ex

Giving arguments from “…” argument to right function in R [duplicate]

ぐ巨炮叔叔 提交于 2020-01-04 07:34:07
问题 This question already has answers here : Split up `…` arguments and distribute to multiple functions (3 answers) Closed 3 years ago . I have a function to compute the correlation of matrix of both categorical and continuous variables: correlation <- function(matrix, ...) { xx <- do.call(rbind, lapply(colnames(mtrc), function(ex_i) { ty_i <- wtype(matrix, ex_i) yy <- sapply(colnames(mtrc), function(ex_j) { ty_j <- wtype(matrix, ex_j) if(ty_i == "numeric" & ty_j == "numeric") { cor(mtrc[ , c(ex

How to pass file to Jenkins with Java

纵然是瞬间 提交于 2020-01-04 02:43:28
问题 I have created a parameterized Jenkins job which I am passing variables to from my Java. Here is the Java: final HttpClient client = new HttpClient(); final PostMethod buildMethod = new PostMethod(Constants.SVN2GIT_QA_URL); buildMethod.setParameter(Constants.GIT_URL_PARAM, gitUrl); buildMethod.setParameter(Constants.PASSWORD_PARAM, password); buildMethod.setParameter(Constants.SVN2GIT_COMMAND, svn2gitCommand); buildMethod.setParameter(Constants.SVN2GIT_EMAIL, email); buildMethod.setParameter

Pass strings by reference in Powershell?

烈酒焚心 提交于 2020-01-03 06:48:11
问题 How can I pass strings by reference to the parent scope? This doesn't work since strings are not acceptable "values". function Submit([ref]$firstName){ $firstName.value = $txtFirstName.Text } $firstName = $null Submit([ref]$firstName) $firstName Error: "Property 'value' cannot be found on this object; make sure it exists and is settable" Doing this doesn't give an error but it doesn't change the variable either: $firstName = "nothing" function Submit([ref]$firstName){ $firstName =

Restlet, An example of a get with parameters

一曲冷凌霜 提交于 2020-01-02 21:59:10
问题 Just startred using restlet with java and was pleasently surprised how easy it was. However this was with puts. I then started to work with get but couldn't work out how to pass infromation with the get. With the put it was easy as: @Put public Boolean store(Contact contact); But when i try and do this with get it doesnt work. From reading around i think i have to not pass it any parameters and just have this: @Get public Contact retrieve(); and then pass the parameters in a url or something?

Pass parameter value to sql file from batch file using batch command

大城市里の小女人 提交于 2020-01-02 14:32:15
问题 I have a sql file update_qde.sql which contains the following code UPDATE profile_const set parameter_value = '04_2015' where profile_name = 'MIDAS_MTH_ALL_Panels' and parameter_name = 'PERIODS_TO'; commit; quit; I have another batch file test.bat I want to pass the parameter_value as a variable from a batch file using batch command. Could you please show me any way to do this? 回答1: Use SQLCMD variables, so change test.bat to call SQLCMD rather than ISQL @echo off sqlcmd -E -S myserver -i

Pass parameter value to sql file from batch file using batch command

喜你入骨 提交于 2020-01-02 14:31:24
问题 I have a sql file update_qde.sql which contains the following code UPDATE profile_const set parameter_value = '04_2015' where profile_name = 'MIDAS_MTH_ALL_Panels' and parameter_name = 'PERIODS_TO'; commit; quit; I have another batch file test.bat I want to pass the parameter_value as a variable from a batch file using batch command. Could you please show me any way to do this? 回答1: Use SQLCMD variables, so change test.bat to call SQLCMD rather than ISQL @echo off sqlcmd -E -S myserver -i

Excel: Passing Array to User Defined Function (VBA)

…衆ロ難τιáo~ 提交于 2020-01-02 06:42:19
问题 edit: solution - see original question below In passing arrays like {1,2,3} to a UDF I found two things to be considered: the locale - see answer 1. The list separator on a german system (usually) is ";" therefore I need to use {1 ; 2 ; 3}. the passed array appears as a 2-dimensional array within the function. Therefore it's n-th element must be targeted as myArray(n, 1 ). Disregarding this gave me the #VALUE! error. Thus, a short "select case"-UDF may look like this: Function SelCase(a1, a2,