none
Error When I create Carousel Controller RRS feed

  • Question

  • Hi,

    I try to create SuccinitySeries Carousel Controller as Syncfusion Show Case. I can not find this show case design in vb.net, so I try to rebuild this in vb.net and I have error. Please help me to fix this. 

    Try to create:

    The Code:

    Private Sub carousel1_OnCarouselItemFocused(ByVal sender As Object, ByVal e As CarouselItemFocusedArgs)
                If e.FocusedImage = SelectedImage Then
    
                    If filePath.ContainsKey(e.FocusedImage) Then
                        Dim fileName As String = filePath(e.FocusedImage)
                        Dim view As Viewer = New Viewer()
    
                        If fileName = "file0" Then
                            fileName = "jQuery_Succinctly.pdf"
                        ElseIf fileName = "file1" Then
                            fileName = "GIS Succinctly.pdf"
                        ElseIf fileName = "file2" Then
                            fileName = "WindowsStoreApps_Succinctly.pdf"
                        ElseIf fileName = "file3" Then
                            fileName = "HTTP_Succinctly.pdf"
                        ElseIf fileName = "file4" Then
                            fileName = "JavaScript_Succinctly.pdf"
                        ElseIf fileName = "file5" Then
                            fileName = "LightSwitch_Succinctly.pdf"
                        ElseIf fileName = "file6" Then
                            fileName = "aspnetmvc4_Succinctly.pdf"
                        ElseIf fileName = "file7" Then
                            fileName = "iOS_Succinctly.pdf"
                        ElseIf fileName = "file8" Then
                            fileName = "Fsharp_Succinctly.pdf"
                        End If
    
                        view.LoadPdf("../../PDF/" & fileName)
                        view.Text = fileName
                        view.Show()
                    End If
                End If
            End Sub

    ERROR:

    Original C# Code:

    private void carousel1_OnCarouselItemFocused(object sender, CarouselItemFocusedArgs e)
            {
    
              if(e.FocusedImage==SelectedImage)
              {
                  if (filePath.ContainsKey(e.FocusedImage))
                  {
                      string fileName = filePath[e.FocusedImage];
                      Viewer view = new Viewer();
                      if (fileName == "file0")
                      {
                          fileName = "jQuery_Succinctly.pdf";
                      }
                      else if (fileName == "file1")
                      {
                          fileName = "GIS Succinctly.pdf";
                      }
                      else if (fileName == "file2")
                      {
                          fileName = "WindowsStoreApps_Succinctly.pdf";
                      }
                      else if (fileName == "file3")
                      {
                          fileName = "HTTP_Succinctly.pdf";
                      }
                      else if (fileName == "file4")
                      {
                          fileName = "JavaScript_Succinctly.pdf";
                      }
                      else if (fileName == "file5")
                      {
                          fileName = "LightSwitch_Succinctly.pdf";
                      }
                      else if (fileName == "file6")
                      {
                          fileName = "aspnetmvc4_Succinctly.pdf";
                      }
                      else if (fileName == "file7")
                      {
                          fileName = "iOS_Succinctly.pdf";
                      }
                      else if (fileName == "file8")
                      {
                          fileName = "Fsharp_Succinctly.pdf";
                      }
                      view.LoadPdf("../../PDF/" + fileName);
                      view.Text = fileName;
    
                       view.Show();
                  }
    
                }

    Thank You...!!!


    RohanD


    • Edited by RAT_SL Sunday, July 14, 2019 8:37 PM Original C#
    • Moved by Alex Li-MSFT Monday, July 22, 2019 7:15 AM
    Sunday, July 14, 2019 8:35 PM

Answers

  • Hello,

    Sorry but this forum is for Microsoft projects and coding. Best to use the following forums

    https://www.syncfusion.com/forums/windowsforms


    Please remember to mark the replies as answers if they help and unmarked them if they provide no help, this will help others who are looking for solutions to the same or similar problem. Contact via my Twitter (Karen Payne) or Facebook (Karen Payne) via my MSDN profile but will not answer coding question on either.

    NuGet BaseConnectionLibrary for database connections.

    StackOverFlow
    profile for Karen Payne on Stack Exchange

    • Marked as answer by RAT_SL Monday, July 22, 2019 8:58 PM
    Sunday, July 14, 2019 11:08 PM