30 Replies - 682 Views - Last Post: 04 March 2012 - 08:22 PM
#16
Re: Conversion from C# to VB
Posted 03 March 2012 - 03:04 PM
#17
Re: Conversion from C# to VB
Posted 03 March 2012 - 03:06 PM
#19
Re: Conversion from C# to VB
Posted 03 March 2012 - 03:12 PM
" 'SalesRepID_'is not a member of 'UsedCarsSales.UsedCarsSales.SalesRep' "
Private Sub LoadGroupData()
Try
Dim reader As New CSVReader()
Dim result = From s In reader.GetSales() _
Join c In reader.GetSalesRep() _
On s.SalesRepID Equals c.SalesRepID_
Order By c.SalesRepID_
DimitriV, on 03 March 2012 - 03:10 PM, said:
Thanks you guys more than helped.
#20
Re: Conversion from C# to VB
Posted 03 March 2012 - 03:15 PM
#21
Re: Conversion from C# to VB
Posted 03 March 2012 - 03:21 PM
#22
Re: Conversion from C# to VB
Posted 03 March 2012 - 03:25 PM
#23
Re: Conversion from C# to VB
Posted 03 March 2012 - 03:29 PM
DimitriV, on 03 March 2012 - 03:25 PM, said:
This should be it :
Imports System Imports System.Collections.Generic Imports System.Linq Imports System.Text Imports System.ComponentModel Namespace UsedCarsSales Public Class SalesRep Public Property SalesRepID() As Integer Get Return m_SalesRepID End Get Set m_SalesRepID = Value End Set End Property Private m_SalesRepID As Integer Public Property LastName() As String Get Return m_LastName End Get Set m_LastName = Value End Set End Property Private m_LastName As String Public Property FirstName() As String Get Return m_FirstName End Get Set m_FirstName = Value End Set End Property Private m_FirstName As String Public Property PhotoFile() As String Get Return m_PhotoFile End Get Set m_PhotoFile = Value End Set End Property Private m_PhotoFile As String Public Property StartDate() As String Get Return m_StartDate End Get Set m_StartDate = Value End Set End Property Private m_StartDate As String Public Property Sales() As List(Of Sales) Get Return m_Sales End Get Set m_Sales = Value End Set End Property Private m_Sales As List(Of Sales) End Class End Namespace
#24
Re: Conversion from C# to VB
Posted 03 March 2012 - 03:36 PM
Order By c.SalesRepID_
I think you were confusing the compiler into thinking that you were referring to a member named c.SalesRepID_ when you were trying to put a line break. Aren't you meant to precede them by a space?
Order By c.SalesRepID _
#25
Re: Conversion from C# to VB
Posted 03 March 2012 - 03:48 PM
This post has been edited by AdamSpeight2008: 03 March 2012 - 03:50 PM
#26
Re: Conversion from C# to VB
Posted 03 March 2012 - 09:53 PM
AdamSpeight2008, on 03 March 2012 - 03:48 PM, said:
You guys rock. Thanks a bunch. It is so easy when the problem is pointed out.
I have this other Error if you guys can tell me what it means, i will appreciate it.
Error : Properties is not a member of 'UsedCarsSales'
' toolStripButtonSave
'
Me.toolStripButtonSave.Image = Global.UsedCarsSales.Properties.Resources.Save
Me.toolStripButtonSave.ImageTransparentColor = System.Drawing.Color.Magenta
Me.toolStripButtonSave.Name = "toolStripButtonSave"
Me.toolStripButtonSave.Size = New System.Drawing.Size(35, 35)
Me.toolStripButtonSave.Text = "Save"
Me.toolStripButtonSave.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText
AddHandler Me.toolStripButtonSave.Click, AddressOf Me.toolStripButtonSave_Click
'
#27
Re: Conversion from C# to VB
Posted 03 March 2012 - 11:33 PM
#28
Re: Conversion from C# to VB
Posted 03 March 2012 - 11:38 PM
DimitriV, on 03 March 2012 - 11:33 PM, said:
Hmm...so do you advice i create a "Properties class" ?
#29
Re: Conversion from C# to VB
Posted 04 March 2012 - 07:59 PM
#30
Re: Conversion from C# to VB
Posted 04 March 2012 - 08:19 PM
DimitriV, on 04 March 2012 - 07:59 PM, said:
Oh i set it to the path of an Image (Folder_Open)
Me.toolStripButtonOpenFile.Image = Global.UsedCarsSales.Properties.Resources.Folder_Open
But it still gives me the 'Properties' is not a member of 'UsedCarsSales'
I wonder what am doing wrong.
|
|

New Topic/Question
Reply




MultiQuote



|