I have this code in VB from an older application that uses a dll to search a database. Could you please tell me how can I do it in c#.
Pseek is the dll
Dim SeekForm As New PSeek.cSeek
Dim redRow As mscomctl.ListItem
Dim succ As Long
Try
redRow = Nothing
succ = SeekForm.CallSeekForm(My.Settings.PSeekConnectionString, "SELECT id,naziv,adresa,broj,vlez,stan,mesto from vSifrarnik where Firmaid = " & My.Settings.curFirma & " and Siftipid=" & SifTipIDUltraCombo.Value, "id,naziv,adresa,broj,vlez,stan,mesto", redRow, 1, , True, False)
If Not (redRow) Is Nothing Then
SifraIDUltraTextEditor.Text = redRow.Text
SifraIDUltraTextEditor.Focus()
End If
Catch ex As System.Exception
System.Windows.Forms.MessageBox.Show(ex.Message)
End Try