What does a hash do to a variable in VB?

后端 未结 2 2058
野性不改
野性不改 2021-01-24 05:21

I have to refactor a VB6 program to C# and am stuck at understanding the following lines:

Set myFileSystemObject = New FileSystemObject
Set myTextStream = myFile         


        
2条回答
  •  甜味超标
    2021-01-24 05:36

    Print #iFileNumber, myTextStream.ReadAll
    

    While trying to understand this myself, I came across this site that has a section on printing to a printer. They say #some_integer indicates a channel number:

    A channel number is any integer value between 0 and 999, preceded by a pound sign (#); it indi- cates a specific channel to a device.

    A channel is a connection between your program and an input or output device, such as a printer or a file.

提交回复
热议问题