folks: my programming knowledge is very limited. I am having a hard time with this problem. Hope someone can explain this to help me understand this.
I am trying to use a function which uses for loops. The input to the function is a value derived from an array. Say myvalue=valuewhen(rulepass,High,1); But the for loop does not allow array values to be used in it. Is there a way I can pass the array value(just a single number) to the function input. I tried valuewhen and it doesn't like that as well. Been reading the http://amibroker.com/guide/a_mistakes.html , but not sure if I can convert an array value to numeric. for example: input=10; result=function(input); //this works whereas myvalue=valuewhen(rulepass,High,1); input=myvalue; result=function(input); //this DOES NOT work eventhough output in interpretation window shows myvalue=10 when the result of myvalue is numeric 10, why is that for loop detects it as an array.(since valuewhen returns only a SINGLE value from the array). Any suggestions?. Thanks,Padhu
