Click here to Skip to main content
15,898,134 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How to validate a socket descripter Pin
jschell9-Mar-12 5:07
jschell9-Mar-12 5:07 
QuestionProblem with button on Win7 Pin
john56326-Mar-12 21:05
john56326-Mar-12 21:05 
AnswerRe: Problem with button on Win7 Pin
enhzflep7-Mar-12 7:08
enhzflep7-Mar-12 7:08 
QuestionHow to request cookies to servers Pin
Joneeky6-Mar-12 15:45
Joneeky6-Mar-12 15:45 
QuestionSyntax for template specialization Pin
VentsyV5-Mar-12 10:43
VentsyV5-Mar-12 10:43 
AnswerRe: Syntax for template specialization Pin
VentsyV5-Mar-12 12:01
VentsyV5-Mar-12 12:01 
GeneralRe: Syntax for template specialization Pin
«_Superman_»5-Mar-12 14:48
professional«_Superman_»5-Mar-12 14:48 
Questionsoftware update concepts, resolving a name to a ip address Pin
jkirkerx5-Mar-12 6:34
professionaljkirkerx5-Mar-12 6:34 
I need to add a software update check to my program. I started by writing a winsock function and making a call to my web site to get a document using

C
trncpy_s( sendbuf, 1024, "GET /updates/siteAdministrator.exe.txt HTTP/1.0\r\n", strlen( "GET /updates/siteAdministrator.exe.txt HTTP/1.0\r\n") );
    strncat_s( sendbuf, 1024, "Host: www.website.com\r\n", strlen( "Host: www.website.com\r\n" ) );
    strncat_s( sendbuf, 1024, "\r\n", strlen( "\r\n" ) );


My Question 1 is:

Without downloading other pre-fabricated programs that does this, or trying to reverse engineer other programs,

What would you recommend that I connect to just to get going at a beginners level. Perhaps a web service that returns the current version, or just a text file that contains the current version, and what information should I return?

If it's a text file, what recommended format would you suggest?

Question 2:

I'm looking for a way to resolve a URL to an IP Address, for this part of my winsock. I don't want to hard code it, because inside my LAN, I use private numbers, and outside my LAN is public numbers.

C#
sTargetDevice.sin_family = PF_INET;
sTargetDevice.sin_addr.s_addr = inet_addr( ipAddress );
sTargetDevice.sin_port = htons((unsigned short) ipPort);

QuestionRe: software update concepts, resolving a name to a ip address Pin
David Crow5-Mar-12 7:45
David Crow5-Mar-12 7:45 
AnswerRe: software update concepts, resolving a name to a ip address Pin
jkirkerx5-Mar-12 7:56
professionaljkirkerx5-Mar-12 7:56 
AnswerRe: software update concepts, resolving a name to a ip address Pin
Jochen Arndt5-Mar-12 7:50
professionalJochen Arndt5-Mar-12 7:50 
GeneralRe: software update concepts, resolving a name to a ip address Pin
jkirkerx5-Mar-12 7:59
professionaljkirkerx5-Mar-12 7:59 
AnswerRe: software update concepts, resolving a name to a ip address Pin
Chuck O'Toole5-Mar-12 9:52
Chuck O'Toole5-Mar-12 9:52 
GeneralRe: software update concepts, resolving a name to a ip address Pin
jkirkerx5-Mar-12 11:35
professionaljkirkerx5-Mar-12 11:35 
AnswerRe: software update concepts, resolving a name to a ip address Pin
Chuck O'Toole5-Mar-12 9:49
Chuck O'Toole5-Mar-12 9:49 
GeneralRe: software update concepts, resolving a name to a ip address Pin
jkirkerx5-Mar-12 11:38
professionaljkirkerx5-Mar-12 11:38 
QuestionSome native or raw C++ compilers Pin
Brandon-X120001-Mar-12 14:53
Brandon-X120001-Mar-12 14:53 
QuestionRe: Some native or raw C++ compilers Pin
Maximilien2-Mar-12 2:47
Maximilien2-Mar-12 2:47 
AnswerRe: Some native or raw C++ compilers Pin
Brandon-X120002-Mar-12 10:14
Brandon-X120002-Mar-12 10:14 
GeneralRe: Some native or raw C++ compilers Pin
CPallini4-Mar-12 21:55
mveCPallini4-Mar-12 21:55 
GeneralRe: Some native or raw C++ compilers Pin
Brandon-X120005-Mar-12 2:38
Brandon-X120005-Mar-12 2:38 
GeneralRe: Some native or raw C++ compilers Pin
CPallini5-Mar-12 2:50
mveCPallini5-Mar-12 2:50 
GeneralRe: Some native or raw C++ compilers Pin
Brandon-X120005-Mar-12 2:59
Brandon-X120005-Mar-12 2:59 
GeneralRe: Some native or raw C++ compilers Pin
CPallini5-Mar-12 3:06
mveCPallini5-Mar-12 3:06 
GeneralRe: Some native or raw C++ compilers Pin
Brandon-X120005-Mar-12 12:26
Brandon-X120005-Mar-12 12:26 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.