Hi...
I want to send over tcp/ip some data, i have the data in hexadecimal, and when i try to send it, i have a few problems.
I give the data as a parameter to the program... argv[1]
Example of argv[1] = "0518EF5600AD"
This is hexadecimal data (05 18 EF 56 00 AD)
The main problem for me is the Send function...
Code:
int send(
__in SOCKET s,
__in const char* buf,
__in int len,
__in int flags
);
How can i send this data if the 2 parameter in the send funcion is a CHAR... and i need to send some null strings like Hex(00)...
I would like to send this:
Code:
unsigned char info[] =
{
0x84, 0xFA, 0xEF, 0x00,
0x01, 0xEF, 0x05, 0x31,
0x01, 0x01, 0x01, 0x20,
0xF9, 0xC7, 0xDC, 0x79,
0x80, 0x99, 0xF1, 0xF2,
0xF3
};
I been trying with some like this:
Code:
string sento;
sento=HexToAscii('02 01 EF 05 31 00 01 00 20 F9 06 02 01 EF 05 33')
nBytesSent = send(Socket, sento.data(), sizeof(sento), 0);
And works, but the other side, all the hex data over 79 change... EF >> 6F... check this:
send: 02 01 EF 05 31 00 01 00 20 F9 06 02 01 EF 05 33
recv : 02 01 6F 05 31 00 01 00 20 79 06 02 01 6F 05 33
...dunno why. With C_Str si the same. I did the same code in Delphi and works perfect... but in C++ i cant. The problem is when i send !
How can i send the value of "info[]" or correct my program?
User feedback after MySQL query has been executed
Hi all, I've just registered on PHPFreaks because I've got a question that I simply can't work out by myself.Im developing a web based reporting application, based upon PHP/MySQL. At some point the
Ajax not working on IE 6 for Windows CE
I've created a webpage which uses the classis Ajax in following format:view plaincopy to clipboardprint?function mytest() { try { xmlHTTP = new XMLHttpRequest(); } catch (e) {
Auto-populating dropdowns and multiple forms.
Here's what I have so far:First drop down = select a state (works)This populates the second drop down (works)Second drop down = select a city (works)This populates the third drop down with local
Operator precedence assistance.
I did a quick Google search and couldn't quite find the answer I wanted in terms I could understand, so, if I may, I'd like to ask quite a specific question.I'm creating a contact form, and I need to
re calling a function without including file
Hi,i am new to programming in php, i was just checking the wordpress code and found out in the wordpress code they are calling the function get_header(); at the top of every page but above calling
Print 'a' to 'z' via for loop
A very simple problem..How Can I print a to z NOT a to y ?It is a part of a code where | $alpha= 'a';for($alpha='a';$alpha!='z';$alpha++){echo $alpha.' ';} Output: a b c d e f g h i j k l m n o p q
present value of sequence?
Hi
Display search result
Hi!I have a SQL database with information about albums and track (music). This is where the user inputs a search term(entersearch.php): Code: <form name="form"
Problem!
I have another problem, when i run this code i get this error "Parse error: syntax error, unexpected T_ELSE in /home/a1408362/public_html/admin.php on line 41". I can't see why in the code
BAPI BBP_INB_DELIVERY_CREATE - material number missing in delivery
Hi Experts,