Page 1 of 1

[PB 5.42 LTS] Bad Constant Value

Posted: Tue Mar 01, 2016 2:05 pm
by hesitate
Upgraded to 5.42
Tried to compile a program that uses WinHTTP

Got error: Constant already declared with a different value: #INTERNET_SCHEME_HTTP

My prog has the correct values:
#INTERNET_SCHEME_HTTP = 1
#INTERNET_SCHEME_HTTPS = 2

These now seem to come predefined with PureBasic 5.42, but the values are wrong (3 and 4, instead of 1 and 2)

Re: [PB 5.42 LTS] Bad Constant Value

Posted: Tue Mar 01, 2016 2:24 pm
by User_Russian

Re: [PB 5.42 LTS] Bad Constant Value

Posted: Tue Mar 01, 2016 2:35 pm
by hesitate
According to this page: https://msdn.microsoft.com/en-us/librar ... s.85).aspx the correct values are 1 and 2

And I've been running the software for months and it works correctly with values 1 and 2.

Re: [PB 5.42 LTS] Bad Constant Value

Posted: Tue Mar 01, 2016 2:37 pm
by Thunder93
Both are right. One is for WinINet, the other is for WinHTTP.

Re: [PB 5.42 LTS] Bad Constant Value

Posted: Tue Mar 01, 2016 2:46 pm
by hesitate
Ok. I'll change the constant name as I'm using WinHTTP.