Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

chr$(0) does not get transmitted(modem)

Posted on 2002-06-24
3
Medium Priority
?
187 Views
Last Modified: 2010-05-02
Hi,
I've found that chr$(0) does not get transmitted over the modem using microsoft's newvbterm.exe or any other such programs.HELP!
0
Comment
Question by:sudeepn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 3

Accepted Solution

by:
PNJ earned 200 total points
ID: 7107610
NULLs DO get transmitted and other non-printables. It just depends how the program (NEWVBTERM and so on) is handling the data. NULLs can be used a string terminators (as per C) so you may have to use the MSCOMM control and code it yourself. Out of interest, check out the help for Nulldiscard and InputMode. This code fragment may help as well:

   With comPort
      .Handshaking = comNone
      .InputMode = comInputModeText
      .CommPort = 2
      .Settings = "1200,E,8,1"
      .InputLen = 0            ' Tell the control to read entire buffer when Input
                               ' is used.
      .PortOpen = True         ' Open the port.
      .InputLen = 0            ' Read all of the text
      .RThreshold = 1          ' Interrupt every character
   End With

   Dim Temp As Variant ' Do not use a byte array as this intersperses NULLs
   Dim Text As String

   Text = "Hello" & Chr$(0) & " World"
   ' Send the message
   Temp = Text
           
   comPort.Output = Temp

This should work - it's from our crane handling system.
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7962965
Hi sudeepn,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will ask a Community Support Moderator to:

    Accept PNJ's comment(s) as an answer.

sudeepn, if you think your question was not answered at all or if you need help, just post a new comment here; Community Support will help you.  DO NOT accept this comment as an answer.
==========
DanRollins -- EE database cleanup volunteer
0
 
LVL 5

Expert Comment

by:Netminder
ID: 8038970
Per recommendation, force-accepted.

Netminder
EE Admin
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question