How Can I get ObjectName for each object if I have couple objects with different names ?

 

I have many up and down arrows , I want to get candle number for each arrow and run a function when I click on it, there are two actions that they need candle number to run that function for that specific candle


My arrow ObjectName's are like these for example : ArrDown_32  , ArrUp_21


a prefix with candle number : "ArrDown_"+Candle_number    -      "ArrUp_"+Candle_number

please help me 

 
mohammad shajary:

I have many up and down arrows , I want to get candle number for each arrow and run a function when I click on it, there are two actions that they need candle number

please help me 

Example: you can use this in loop that will give each a candle number as object name

+IntegerToString(i)
Arrow("Bearish_Arrow_"+IntegerToString(i),
time ,
value ,clr,arrrowcode,anchor);
 
mohammad shajary: I have many up and down arrows , I want to get candle number for each arrow and run a function when I click on it, there are two actions that they need candle number. please help me 
You have provided insufficient information for us to be able to give you any valuable advice. Please understand that we cannot read your mind nor see you computer, so you need to provide more details, such as screenshots and sample code of what you have tried to code yourself so far.
 
Fernando Carreiro #:
You have provided insufficient information for us to be able to give you any valuable advice. Please understand that we cannot read your mind nor see you computer, so you need to provide more details, such as screenshots and sample code of what you have tried to code yourself so far. 

Dear Fernando Carreiro ,

I suppose I need to access each arrow in OnChartEvent to run my function after clicking for each one

sparam in  OnChartEvent needs exact ObjectName , how can I access to full ObjectName ? or do this by other way

I need dynamic way because candle numbers are not the same on each currency pair or ...
Fernando Carreiro
Fernando Carreiro
  • 2023.03.09
  • www.mql5.com
Trader's profile
 
Fernando Carreiro #:
You have provided insufficient information for us to be able to give you any valuable advice. Please understand that we cannot read your mind nor see you computer, so you need to provide more details, such as screenshots and sample code of what you have tried to code yourself so far.

How could we better explain that to people requesting help !?! In a great percentage of the cases, we have to repeat we need technical details, again and again.

Still we explain it...and again they answer without technical details. "I need", "I want", "How can I ..." following by a cryptic question.

Reason: