Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 6. - page 780

 

Hello Dear Professionals. The question is that in the old build 509 there was the following function

#import "wininet.dll"
   int InternetOpenA(string a0, int a1, string a2, string a3, int a4);
   int InternetOpenUrlA(int a0, string a1, string a2, int a3, int a4, int a5);
   int InternetReadFile(int a0, string a1, int a2, int& a3[]);
   int InternetCloseHandle(int a0);

int function1inet() {
   int IOURez;
   bool Rez = TRUE;
   string IOAgent= "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; Q312461)";
   bool IOAccess = FALSE;
   int IOSes = InternetOpenA(IOAgent, IOAccess, "0", "0", 0);
   if (IOSes != 0) {
      IOURez = InternetOpenUrlA(IOSes, "http://www.site.ru", "0", 0, -2080374528, 0);
      if (IOURez == 0) Rez = FALSE;
      else InternetCloseHandle(IOURez);
      InternetCloseHandle(IOSes);
   } else Rez = FALSE;
   return (Rez);
}

Since in the new builds strings are now a sequence of Unicode characters and now I have to use InternetOpenW and InternetOpenUrlW .

I read a couple of articles on this forum, but despite the examples, I cannot change the function for the new build. If you can, please modify it for the new build. THANK YOU!


 
T-G:
Check out WebRequest
 

Good afternoon. please advise how to set the number of indexes of an array variable . I would be very grateful.

void OnStart()

{

int f=5;

int g[f];

}

 
apparently moderators and other professionals are not interested in this forum, they do not want to help newcomers!!! Who can tell me where and on which forum beginners are appreciated?
 
soroko:

Good afternoon. please advise how to set the number of indexes of an array variable . I would be very grateful.

void OnStart()
 {
  int f=5;
  int g[f];
 }
void OnStart()
 {
  int f=5;
  int g[5];
  ArrayResize(g, f);
 }
logut:
apparently the moderator and the other pros are not interested in this forum already do not want them to help newbies!!! who can tell me where and on which forum do they appreciate newbies!?
What is the point?
 
You mean the point of valuing the newbies?
 
logut:
You're saying appreciating the newbies is one thing?
Appreciating newbies is one thing. Rewriting documentation in here is another thing...
 
logut:
Probably the moderator and the other professionals are not interested in this forum, they do not want to help newcomers!!! Who can tell me where and on which forum beginners are appreciated?
The value of a beginner is not in his ignorance but in freshness of mind, ideas, unmediatedness! For that you must learn many platitudes, be inquisitive and curious! In the meantime, you resemble a loser looking for hints, peek-a-boo, hoping now for this time to sculpt an advisor and, finally, to cut the dough and enjoy idleness.
 

AlexeyVik:
Ценить новичков, это одно. А переписывать сюда документацию совсем другое дело...

i need to write a stop loss order, i asked all you Professionals to tell me how to do it, i reread the tutorial, i didn't understand everything.

i managed to do it myself with some effort, it took me a month!!! now i want to prescribe it so the stop loss would move to a distance i had set.

i read the tutorial again and see how other EAs are written!!!

 

logut:

I had to write a stop on a profit, I had to do it myself, it took me a month!

I could barely do it myself, it took me a month!!! Now I want to write a code so the stop loss would move to a distance I set when I took a profit.

i read the textbook again and look at how other EAs are written!!!

I can't get it to work. You have to write something, just show it here, explaining what you want to get and what's wrong.

And to write for you all the code "turnkey" - it's not here, it's in Freelance.

Reason: