Exemple #1
0
        public bool downloadSMA(string folderPath, string scriptName, bool bIsTestOn, bool bSaveData)
        {
            string interval = ddlSMA_Interval.SelectedValue;
            string period   = textboxSMA_Period.Text;
            string series   = ddlSMA_Series.SelectedValue;

            if (StockApi.getSMAAlternate(folderPath, scriptName, day_interval: interval, period: period, seriestype: series,
                                         bIsTestModeOn: bIsTestOn, bSaveData: bSaveData, apiKey: Session["ApiKey"].ToString()) == null)
            {
                textboxMessage.Text = Environment.NewLine + "SMA data not available for selected script.";
                return(false);
            }

            //if (StockApi.getSMA(folderPath, scriptName, day_interval: interval, period: period, seriestype: series,
            //                    bIsTestModeOn: bIsTestOn, bSaveData: bSaveData, apiKey: Session["ApiKey"].ToString()) == null)
            //{
            //    textboxMessage.Text = Environment.NewLine + "SMA data not available for selected script.";
            //    return false;
            //}
            return(true);
        }