Equivalent code in VB for a C# code

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • SalamElias

    #1

    Equivalent code in VB for a C# code

    Hi, I managed to transform a C# class to VB except the following portion of
    the code
    if(dgItem.Cells[i].Controls.Count > 0 && dgItem.Cells[i].Controls[0] is
    LinkButton)
    ..dgItem is a datagrid item.
    What is the equivalkent code in VB
    Thanks in advance
    Salam
  • Herfried K. Wagner [MVP]

    #2
    Re: Equivalent code in VB for a C# code

    "SalamElias " <eliassal@onlin e.nospam> schrieb:[color=blue]
    > Hi, I managed to transform a C# class to VB except the following portion
    > of
    > the code
    > if(dgItem.Cells[i].Controls.Count > 0 && dgItem.Cells[i].Controls[0] is
    > LinkButton)
    > .dgItem is a datagrid item.
    > What is the equivalkent code in VB[/color]

    \\\
    If _
    dgItem.Cells(i) .Controls.Count > 0 AndAlso _
    TypeOf dgItem.Cells(i) .Controls(0) Is LinkButton _
    Then
    ...
    End If
    ///

    This article contains a list of available C# to VB.NET translators:

    Converting code between .NET programming languages
    <URL:http://dotnet.mvps.org/dotnet/faqs/?id=languagecon verters&lang=en >

    The converter of Tangible Software Solutions Inc. produces very accurate
    results. You may want to order a demo version:

    <URL:http://www.tangiblesof twaresolutions. com/Demo_Download/Instant_VB/Request_Demo_In stant_VB.htm>

    --
    M S Herfried K. Wagner
    M V P <URL:http://dotnet.mvps.org/>
    V B <URL:http://classicvb.org/petition/>

    Comment

    • SalamElias

      #3
      Re: Equivalent code in VB for a C# code

      Thanks, all urls work like a charm
      Thanks

      "Herfried K. Wagner [MVP]" wrote:
      [color=blue]
      > "SalamElias " <eliassal@onlin e.nospam> schrieb:[color=green]
      > > Hi, I managed to transform a C# class to VB except the following portion
      > > of
      > > the code
      > > if(dgItem.Cells[i].Controls.Count > 0 && dgItem.Cells[i].Controls[0] is
      > > LinkButton)
      > > .dgItem is a datagrid item.
      > > What is the equivalkent code in VB[/color]
      >
      > \\\
      > If _
      > dgItem.Cells(i) .Controls.Count > 0 AndAlso _
      > TypeOf dgItem.Cells(i) .Controls(0) Is LinkButton _
      > Then
      > ...
      > End If
      > ///
      >
      > This article contains a list of available C# to VB.NET translators:
      >
      > Converting code between .NET programming languages
      > <URL:http://dotnet.mvps.org/dotnet/faqs/?id=languagecon verters&lang=en >
      >
      > The converter of Tangible Software Solutions Inc. produces very accurate
      > results. You may want to order a demo version:
      >
      > <URL:http://www.tangiblesof twaresolutions. com/Demo_Download/Instant_VB/Request_Demo_In stant_VB.htm>
      >
      > --
      > M S Herfried K. Wagner
      > M V P <URL:http://dotnet.mvps.org/>
      > V B <URL:http://classicvb.org/petition/>
      >
      >[/color]

      Comment

      Working...