عرض مشاركة واحدة
قديم 08-03-2013, 02:47 PM   المشاركة رقم: 9
الكاتب
MOVING_AVERAGE
عضو فضى
الصورة الرمزية MOVING_AVERAGE

البيانات
تاريخ التسجيل: Feb 2012
رقم العضوية: 8190
الدولة: algeria
العمر: 41
المشاركات: 2,223
بمعدل : 0.49 يوميا

الإتصالات
الحالة:
MOVING_AVERAGE غير متواجد حالياً
وسائل الإتصال:

كاتب الموضوع : MOVING_AVERAGE المنتدى : منتدى المؤشرات و الاكسبيرتات
افتراضي رد: ورشة برمجة مؤشر بافكار متجددة

التصريح بالمستوي خارج الدالة start

[PHP]
extern int RSI_buy_level=50;
extern int RSI_sell_level=50;
[/PHP]

والكود لحد الان هو

[PHP]
#property indicator_separate_window
#property indicator_buffers 2
#property indicator_color1 Red
#property indicator_color2 Green


double ExtMapBuffer1[];
double ExtMapBuffer2[];

extern int RSI_buy_level=50;
extern int RSI_sell_level=50;
//+------------------------------------------------------------------+
//| Custom indicator initialization function |
//+------------------------------------------------------------------+
int init()
{
//---- indicators
SetIndexStyle(0,DRAW_HISTOGRAM,0,3);
SetIndexBuffer(0,ExtMapBuffer1);
SetIndexStyle(1,DRAW_HISTOGRAM,0,3);
SetIndexBuffer(1,ExtMapBuffer2);
//----
return(0);
}
//+------------------------------------------------------------------+
//| Custom indicator deinitialization function |
//+------------------------------------------------------------------+
int deinit()
{
//----

//----
return(0);
}
//+------------------------------------------------------------------+
//| Custom indicator iteration function |
//+------------------------------------------------------------------+
int start()
{
int x,i;
int counted_bars=IndicatorCounted();
if(counted_bars<0) return(-1);
if(counted_bars>0) counted_bars--;
x=Bars-counted_bars;

for(i =0 ; i<x ; i++)
{



}

return(0);
}
//+------------------------------------------------------------------+
[/PHP]



التوقيع

نقره لعرض الصورة في صفحة مستقلة







عرض البوم صور MOVING_AVERAGE  
رد مع اقتباس
  #9  
قديم 08-03-2013, 02:47 PM
MOVING_AVERAGE MOVING_AVERAGE غير متواجد حالياً
عضو فضى
افتراضي رد: ورشة برمجة مؤشر بافكار متجددة

التصريح بالمستوي خارج الدالة start

[PHP]
extern int RSI_buy_level=50;
extern int RSI_sell_level=50;
[/PHP]

والكود لحد الان هو

[PHP]
#property indicator_separate_window
#property indicator_buffers 2
#property indicator_color1 Red
#property indicator_color2 Green


double ExtMapBuffer1[];
double ExtMapBuffer2[];

extern int RSI_buy_level=50;
extern int RSI_sell_level=50;
//+------------------------------------------------------------------+
//| Custom indicator initialization function |
//+------------------------------------------------------------------+
int init()
{
//---- indicators
SetIndexStyle(0,DRAW_HISTOGRAM,0,3);
SetIndexBuffer(0,ExtMapBuffer1);
SetIndexStyle(1,DRAW_HISTOGRAM,0,3);
SetIndexBuffer(1,ExtMapBuffer2);
//----
return(0);
}
//+------------------------------------------------------------------+
//| Custom indicator deinitialization function |
//+------------------------------------------------------------------+
int deinit()
{
//----

//----
return(0);
}
//+------------------------------------------------------------------+
//| Custom indicator iteration function |
//+------------------------------------------------------------------+
int start()
{
int x,i;
int counted_bars=IndicatorCounted();
if(counted_bars<0) return(-1);
if(counted_bars>0) counted_bars--;
x=Bars-counted_bars;

for(i =0 ; i<x ; i++)
{



}

return(0);
}
//+------------------------------------------------------------------+
[/PHP]




رد مع اقتباس