tcomputerchip
Newcomer
Ok this one may be difficault for some of you.
This is the problem. I have a converter program that converts binary data to text formated data. The class was written in VB6. I would like to convert the class to VBNET.
The problem is I don't know anything about Structures except that it replaces Type declerations.
Now, when I convert the Type over to structure I have many errors still in my dimentioned varialbles.
Example: VB6
Change to VBNET:
If someone could modify the code below, or parts of it and give me example of how I should convert the code to VBNET that would be great.
Code Working On:
This is the problem. I have a converter program that converts binary data to text formated data. The class was written in VB6. I would like to convert the class to VBNET.
The problem is I don't know anything about Structures except that it replaces Type declerations.
Now, when I convert the Type over to structure I have many errors still in my dimentioned varialbles.
Example: VB6
Visual Basic:
Type bLineData
ByteOfData As String * 1 '1 Char only
LotsOfData(25) As Byte '25 bytes only
End Type
Change to VBNET:
Visual Basic:
Structure bLineData
Dim ByteOfData As String * 1 'Not Working
Dim LotsOfData(25) as Byte 'Not Working
End Structure
If someone could modify the code below, or parts of it and give me example of how I should convert the code to VBNET that would be great.
Code Working On:
Visual Basic:
Module modConvert
Type LabelArea
DateTimeValue(5) As Byte
FileName As String * 8 ' Redundent but here
DeviceName As String * 10 ' Name of part or part number
Operator As String * 10 ' Person that ran/collected test data
TestingMode As Byte ' first bit 0 = TBB, 1 = TBS
StationName As String * 1 ' Station A,B,C,D and F
LotName As String * 10 ' Lot for device that were tested
Comment As String * 50 ' Comments of test
TimePoint As Integer ' Test number mostly for HiRel applications\
SetQuantity As Integer ' Number of device that were tested
LoggingRate As Integer ' Results sorted after N test 1 in 5, 2 in 10
TestMax As Integer ' Number of test used to collect data
DataBlockNum As Integer ' Not used currently
LoggedQuantity As Integer ' Actual Logged quantity
IndexMax As Integer ' Device Index
Reserved(17) As Byte ' Future use
End Type
Type TestItemArea
TestNumber As Byte 'Test Number
ItemGroupCode As Byte 'Item Group Code
ItemCode As Integer 'Item Code
BEConditionFlag As Byte 'BE Condition & Flag
ResultBiasFlag As Byte 'Result as BIAS Flag
LimitItemName As String * 6 'Limit Item Name
LimitUnit As Integer 'Limit Unit, second byte not used
LimitValue As Single 'Limit Value
LimitMax As Single 'Limit Min
LimitMin As Single 'Limit Max
bias1Name As String * 4 'Bias 1 Name
bias1Unit As String * 2 'Bias 1 Unit
bias1Value As Single 'Bias 1 Value
bias2Name As String * 4 'Bias 2 Name
bias2Unit As String * 2 'Bias 2 Unit
bias2Value As Single 'Bias 2 Value
TimeCondition As String * 4 'Time Condition Name
TimeUnit(1) As Byte 'Time Unit
TimeValue As Single 'Time Value
DLIFlags As Byte 'DL Inhibit Flags
Reserved(6) As Byte 'Reserved
End Type
Type WafferData
wafferID As Byte 'Always 'W'
wafferNumber As Byte 'Waffer Number
NumberOfDevices As Integer 'Number of devices
Reserved As Integer 'Reserved
End Type
Type DeviceData
deviceID As Byte 'Always 'D'
ZeroZero As Byte 'Always '00'
SerialNumber As Integer 'Number of devices
BinNumber As Integer 'Reserved
End Type
Type TestData
TestNumber As Byte 'TestNumber
Flags As Byte 'Flags
TestValue As Single 'Test Resualt Value
End Type
Type bLineData
ByteOfData As String * 1 'Extract data for check
End Type
End Module