Click here to Skip to main content
15,886,026 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionHow to change EXCEL 2007 Chart Series Color in a xlCylinderBarStacked in VB.Net Pin
mrbd082-Jul-09 10:02
mrbd082-Jul-09 10:02 
Questionmacro code that prompt for password or display message each time MS word is opened Pin
ChiSmile2-Jul-09 4:57
ChiSmile2-Jul-09 4:57 
AnswerRe: macro code that prompt for password or display message each time MS word is opened Pin
Dave Kreskowiak2-Jul-09 8:40
mveDave Kreskowiak2-Jul-09 8:40 
GeneralRe: macro code that prompt for password or display message each time MS word is opened Pin
ChiSmile2-Jul-09 17:34
ChiSmile2-Jul-09 17:34 
GeneralRe: macro code that prompt for password or display message each time MS word is opened Pin
Dave Kreskowiak2-Jul-09 18:33
mveDave Kreskowiak2-Jul-09 18:33 
GeneralRe: macro code that prompt for password or display message each time MS word is opened Pin
ChiSmile2-Jul-09 22:07
ChiSmile2-Jul-09 22:07 
JokeRe: macro code that prompt for password or display message each time MS word is opened Pin
dan!sh 2-Jul-09 8:45
professional dan!sh 2-Jul-09 8:45 
QuestionSocket programming Pin
Cory Kimble2-Jul-09 4:20
Cory Kimble2-Jul-09 4:20 
I am having difficulty communication through a socket. I am new to this, so bare with me.

I am trying to pass string control protocols to a device like a display sign.

Here is how I have connected to the sign. I think this has worked because I don't get an error. Plus, when I try to connect again it says that I am already connected.

Private endpoint as new IPEndPoint(ipaddress, port)
private socket as new socket(endpoint.addressFamily, SocketType.Stream, ProtocolType.Tcp)


--Sub
socket.connect(endpoint)


--end sub

The issue is when I try to send the protocol text string to the sign. I need help formatting the string.

EXAMPLE: The documentation says to send <0x01>Z00<0x02>AA<0x1C>1<0x1D>B3This is where message is.<0x04>

So I changed it to hex:
dim signmsg = This is where message is.
dim signstring = &H1.tostring + "Z00" + &H2.tostring + "AA" + &H28.tostring + "1" + &H29.tostring + "B3" + signmsg + &H4.toString


First, can you see if I am doing any thing wrong above.

Second, What is the easiest way to get this data formatted correctly and sent to the socket.
Will this work?
dim Buffer() as Byte = System.text.acsciiencoding.ascii.getbytes(signString)


To send I use

socket.send(Buffer, buffer.length, Sockets.SocketFlags.none)


But I get nothing from the sign.

What am I doing wrong?

I can't think of anything cool and nerdy to say.

AnswerRe: Socket programming Pin
Luc Pattyn2-Jul-09 4:31
sitebuilderLuc Pattyn2-Jul-09 4:31 
GeneralRe: Socket programming Pin
Cory Kimble2-Jul-09 4:54
Cory Kimble2-Jul-09 4:54 
GeneralRe: Socket programming Pin
Luc Pattyn2-Jul-09 5:05
sitebuilderLuc Pattyn2-Jul-09 5:05 
GeneralRe: Socket programming Pin
Cory Kimble2-Jul-09 6:07
Cory Kimble2-Jul-09 6:07 
GeneralRe: Socket programming Pin
Luc Pattyn2-Jul-09 6:12
sitebuilderLuc Pattyn2-Jul-09 6:12 
GeneralRe: Socket programming Pin
Dave Kreskowiak2-Jul-09 9:09
mveDave Kreskowiak2-Jul-09 9:09 
QuestionCompile error Pin
hamed20092-Jul-09 2:13
hamed20092-Jul-09 2:13 
AnswerRe: Compile error Pin
TheMrProgrammer2-Jul-09 3:49
TheMrProgrammer2-Jul-09 3:49 
AnswerRe: Compile error Pin
Dave Kreskowiak2-Jul-09 4:32
mveDave Kreskowiak2-Jul-09 4:32 
Question3D Image Pin
bhargava24092-Jul-09 2:03
bhargava24092-Jul-09 2:03 
AnswerRe: 3D Image Pin
TheMrProgrammer2-Jul-09 4:02
TheMrProgrammer2-Jul-09 4:02 
AnswerRe: 3D Image Pin
Dave Kreskowiak2-Jul-09 4:31
mveDave Kreskowiak2-Jul-09 4:31 
QuestionCrystal Reports 8.5 to email a batch of reports Pin
Raghvendra Kumar Roy2-Jul-09 1:33
Raghvendra Kumar Roy2-Jul-09 1:33 
QuestionImporting html code using HTMLProject object [modified] Pin
Harold_Wishes2-Jul-09 1:00
Harold_Wishes2-Jul-09 1:00 
Questionhow to drag video from the webbrowser and download it on a button control Pin
bhumika_singh2-Jul-09 0:58
bhumika_singh2-Jul-09 0:58 
Questionprint prview problem Pin
JC.KaNNaN2-Jul-09 0:29
JC.KaNNaN2-Jul-09 0:29 
AnswerRe: print prview problem Pin
Eddy Vluggen2-Jul-09 2:28
professionalEddy Vluggen2-Jul-09 2:28 

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.