Click here to Skip to main content
15,908,673 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Rant[REPOST] ISSUE - TCP/IP sockets in MFC VS2017 Pin
Richard Deeming21-Nov-17 3:00
mveRichard Deeming21-Nov-17 3:00 
QuestionRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
Richard MacCutchan21-Nov-17 3:01
mveRichard MacCutchan21-Nov-17 3:01 
AnswerRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
D.Manivelan21-Nov-17 17:41
D.Manivelan21-Nov-17 17:41 
GeneralRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
Richard MacCutchan21-Nov-17 21:18
mveRichard MacCutchan21-Nov-17 21:18 
GeneralRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
D.Manivelan22-Nov-17 0:01
D.Manivelan22-Nov-17 0:01 
GeneralRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
Richard MacCutchan22-Nov-17 0:46
mveRichard MacCutchan22-Nov-17 0:46 
AnswerRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
Graham Breach21-Nov-17 21:14
Graham Breach21-Nov-17 21:14 
AnswerRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
Victor Nijegorodov22-Nov-17 10:07
Victor Nijegorodov22-Nov-17 10:07 
Just to extend the reply of Graham Breach:
move the
union USendLive
    {
        struct SSend
        {
            float fTestValue1;
            float fTestValue2;  
            char cChr;          
        }S;                     
        unsigned char Buffer[LIVEUNISIZE];
    }UNI;
to the CSendValue class ctor to make the UNI a class member.

Then your CSendValue :: SendLiveValues() would look like
unsigned char* CSendValue :: SendLiveValues()
{
    float fLocalValue;
    float fTest;

    fTest               = 190.000015f;

    fLocalValue         = fTest;<br />
    UNI.S.cChr          = 'c';<br />
    UNI.S.fTestValue1   = fTest;<br />
    UNI.S.fTestValue2   = 190.000015f;  

        return UNI.Buffer;    
}

QuestionFiguring Out How to Test Code Pin
Member 1352762517-Nov-17 16:48
Member 1352762517-Nov-17 16:48 
AnswerRe: Figuring Out How to Test Code Pin
Richard MacCutchan17-Nov-17 21:43
mveRichard MacCutchan17-Nov-17 21:43 
GeneralRe: Figuring Out How to Test Code Pin
Member 1352762519-Nov-17 10:34
Member 1352762519-Nov-17 10:34 
GeneralRe: Figuring Out How to Test Code Pin
Victor Nijegorodov19-Nov-17 21:07
Victor Nijegorodov19-Nov-17 21:07 
GeneralRe: Figuring Out How to Test Code Pin
Richard MacCutchan19-Nov-17 21:49
mveRichard MacCutchan19-Nov-17 21:49 
GeneralRe: Figuring Out How to Test Code Pin
CPallini21-Nov-17 21:51
mveCPallini21-Nov-17 21:51 
AnswerRe: Figuring Out How to Test Code Pin
jschell20-Nov-17 6:26
jschell20-Nov-17 6:26 
AnswerRe: Figuring Out How to Test Code Pin
ThatsAlok20-Nov-17 20:10
ThatsAlok20-Nov-17 20:10 
QuestionC++ formatting into a buffer - why so elephanting difficult? Pin
charlieg16-Nov-17 3:15
charlieg16-Nov-17 3:15 
AnswerRe: C++ formatting into a buffer - why so elephanting difficult? Pin
Jochen Arndt16-Nov-17 3:51
professionalJochen Arndt16-Nov-17 3:51 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
charlieg16-Nov-17 5:20
charlieg16-Nov-17 5:20 
AnswerRe: C++ formatting into a buffer - why so elephanting difficult? Pin
Richard MacCutchan16-Nov-17 4:00
mveRichard MacCutchan16-Nov-17 4:00 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
charlieg16-Nov-17 5:21
charlieg16-Nov-17 5:21 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
Richard MacCutchan16-Nov-17 21:28
mveRichard MacCutchan16-Nov-17 21:28 
AnswerRe: C++ formatting into a buffer - why so elephanting difficult? Pin
Maximilien16-Nov-17 5:45
Maximilien16-Nov-17 5:45 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
charlieg16-Nov-17 11:11
charlieg16-Nov-17 11:11 
AnswerRe: C++ formatting into a buffer - why so elephanting difficult? Pin
jschell16-Nov-17 13:27
jschell16-Nov-17 13:27 

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.