Login Page - Create Account

Support Board


Date/Time: Thu, 28 Mar 2024 11:07:22 +0000



[User Discussion] - Custom dll study has just caused a CPU exception.

View Count: 1051

[2014-12-12 13:17:29]
User54873 - Posts: 1
Hi,

I am facing this error when i add custom study.

i am using following code.I didn't find the solution of this.can anyone help me.

int RequestValuesFromServer(SCStudyInterfaceRef sc)
{
  SCString WebsiteURL;
  int& RequestState = sc.PersistVars->i1;
WebsiteURL="https://google.com/finance";
sc.AddMessageToLog(WebsiteURL.GetChars(), true);
if (!sc.MakeHTTPRequest(WebsiteURL))
  {
   sc.AddMessageToLog("Error making HTTP Request.", true);
   RequestState = HTTP_REQUEST_ERROR;
  }
  else
  {
   RequestState = HTTP_REQUEST_MADE;
   sc.AddMessageToLog("Requesting data from Trading Levels server.",true);
  }
  return 0;

  if (RequestState == HTTP_REQUEST_MADE && sc.HTTPResponse != "")
  {
   RequestState = HTTP_REQUEST_RECEIVED;
   sc.AddMessageToLog("HTTP_REQUEST_RECEIVED",true);
   return 1;
  }
  else if(RequestState == HTTP_REQUEST_MADE && sc.HTTPResponse == "")
  {
    return 0;
  }
  if (RequestState != HTTP_REQUEST_RECEIVED)
    return 0;

  return 1;
}
Date Time Of Last Edit: 2014-12-12 13:18:40

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account