473,387 Members | 1,492 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Convert VB6 Type To .NET Structure

Dan
Good Day All,

I have the following VB6 Type

Type IAListRecordType
lID As Long
strName As String * IALISTSTRSIZE
End Type

I need to convert this to VB .NET. How do I do this? I have come up with

Structure IATaskListRecordType
Dim lID As Long
Dim strName As String * IATASKLISTSTRSIZE
End Structure

However, the * IATASKLISTSTRSIZE will not compile. I get a message

"End Of Statement Expected"

Any suggestions would be appreciated. Thanks!

Dan
Nov 20 '05 #1
3 3347
The syntax is incorrect, what are you expecting to happen with this line.?

--

OHM ( Terry Burns )
. . . One-Handed-Man . . .
"Dan" <Da*@discussions.microsoft.com> wrote in message
news:6C**********************************@microsof t.com...
Good Day All,

I have the following VB6 Type

Type IAListRecordType
lID As Long
strName As String * IALISTSTRSIZE
End Type

I need to convert this to VB .NET. How do I do this? I have come up with

Structure IATaskListRecordType
Dim lID As Long
Dim strName As String * IATASKLISTSTRSIZE
End Structure

However, the * IATASKLISTSTRSIZE will not compile. I get a message

"End Of Statement Expected"

Any suggestions would be appreciated. Thanks!

Dan

Nov 20 '05 #2
Hi,

The dotnet integer is the same as the old long. Replace any longs with
integers.

Structure IATaskListRecordType
Dim lID As Integer
<VBFixedString(IATASKLISTSTRSIZE)> Dim strName As String
End Structure

Ken
---------------

"Dan" <Da*@discussions.microsoft.com> wrote in message
news:6C**********************************@microsof t.com:
Good Day All,

I have the following VB6 Type

Type IAListRecordType
lID As Long
strName As String * IALISTSTRSIZE
End Type

I need to convert this to VB .NET. How do I do this? I have come up with

Structure IATaskListRecordType
Dim lID As Long
Dim strName As String * IATASKLISTSTRSIZE
End Structure

However, the * IATASKLISTSTRSIZE will not compile. I get a message

"End Of Statement Expected"

Any suggestions would be appreciated. Thanks!

Dan


--
Outgoing mail is certified Virus Free.
Checked by AVG Anti-Virus (http://www.grisoft.com).
Version: 7.0.230 / Virus Database: 263.3.0 - Release Date: 6/12/2004
Nov 20 '05 #3
Dan
Ken,

Thanks for the quick response. That did the trick. I really appreciate it.

Dan

"Ken Tucker [MVP]" wrote:
Hi,

The dotnet integer is the same as the old long. Replace any longs with
integers.

Structure IATaskListRecordType
Dim lID As Integer
<VBFixedString(IATASKLISTSTRSIZE)> Dim strName As String
End Structure

Ken
---------------

"Dan" <Da*@discussions.microsoft.com> wrote in message
news:6C**********************************@microsof t.com:
Good Day All,

I have the following VB6 Type

Type IAListRecordType
lID As Long
strName As String * IALISTSTRSIZE
End Type

I need to convert this to VB .NET. How do I do this? I have come up with

Structure IATaskListRecordType
Dim lID As Long
Dim strName As String * IATASKLISTSTRSIZE
End Structure

However, the * IATASKLISTSTRSIZE will not compile. I get a message

"End Of Statement Expected"

Any suggestions would be appreciated. Thanks!

Dan


--
Outgoing mail is certified Virus Free.
Checked by AVG Anti-Virus (http://www.grisoft.com).
Version: 7.0.230 / Virus Database: 263.3.0 - Release Date: 6/12/2004

Nov 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: phancey | last post by:
I am trying to invoke a web service method dynamically. I have created a generic function that takes a method name, string of parameters and calls the web method using System.Reflection: ...
7
by: Randy Yates | last post by:
Hi, I work in an embedded environment in which we often use a mix of C and assembly code. Thus a recurring requirement is to be able to take a C header file with structure definitions as input...
2
by: Mel WEaver | last post by:
Hello, I have the following delphi structure for a binary file. I'm looking for idea how to read this file. Mel type TMenuDataStruct = packed record exename : string;
9
by: Charles Law | last post by:
Suppose I have a structure Private Structure MyStruct Dim el1 As Byte Dim el2 As Int16 Dim el3 As Byte End Structure I want to convert this into a byte array where
8
by: Carlos | last post by:
I have a strinf with comma separated field. Is is possible to convert it to a Structure ? Thanks
2
by: Jarod_24 | last post by:
Structure myXMLtype Dim Filename As String Dim sql As String End Structure .... Dim obj as New ArrayList ...... return CType(obj.ToArray, myXMLtype) 'This wont work
6
by: Eric | last post by:
.... my eternal gratitude!!! :p Here is the problem. A sample of my original VB6 code : '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Public...
1
by: Peter | last post by:
Does anybody know how to convert a string to a varible? For example, I have defined 2 structures Structure SS dim Name as string dim ID as short end structure Structure TT
7
by: manstey | last post by:
Hi, How do I convert a string like: a="{'syllable': u'cv-i b.v^ y^-f', 'ketiv-qere': 'n', 'wordWTS': u'8'}" into a dictionary: b={'syllable': u'cv-i b.v^ y^-f', 'ketiv-qere': 'n', 'wordWTS':...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.