Buffer vs. Char Variable
davidv
Posts: 90
What is the fundamental difference in storing data into a buffer or storing char data into a char variable?
Can you store data to either or is it specific applications?
Can you store data to either or is it specific applications?
0
Comments
dvDEVICE = 5001:1:0
CHAR Buffer[50]
Create_Buffer dvDEVICE, Buffer
This is used to buffer incoming data from a serial port. You can also use DATA.TEXT for this purpose.
JB
Yes this is true, but since they fixed DATA.TEXT many years ago I never use it. Just extra work to set it up.
JB
DATA.TEXT is defined in the NetLinx.axi with a lenght of 2048.
you can modify this too. I don't since it handles most thing more than well enough. For large buffers and/or web page scraping, I switchh over to CREATE_BUFFER. We learned in PROG III (part deaux) that there is no problem with either method and they are both acceptable.
If you need to append data to a var larger than 15999 you can just use string to var function that AMXJeff posted a while back.