DataGridView and DSN connection

Posted on 2006-04-02
Last Modified: 2008-03-17
I have received a user defined connection string from a MSDASC datalink.  Now I need to have this connection string open the data in a data grid.  Could I please get some help on this, I am a little lost.  It is a windows form.  Thank you,
Question by:dhathsato
    LVL 4

    Accepted Solution


    Author Comment

    This is what I have so far.  Basically it brings the dialog box up for the customer to select or create their connection.  I reveiwed the link above and still a little confused on how I would go about implementing a DataGridView with the returned connection string.

        Private Sub DataSourceToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles DataSourceToolStripMenuItem.Click
            Dim mydlg As New MSDASC.DataLinks()
            Dim ADOcon As New ADODB.Connection()

            ADOcon = mydlg.PromptNew
                If ADOcon.State = 1 Then
                    'connection string returned from dialog box
                    MsgBox("Connection Failed")
                End If

            Catch ex As Exception

            End Try

        End Sub

    Featured Post

    Better Security Awareness With Threat Intelligence

    See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

    Join & Write a Comment

    1.0 - Introduction Converting Visual Basic 6.0 (VB6) to Visual Basic 2008+ (VB.NET). If ever there was a subject full of murkiness and bad decisions, it is this one!   The first problem seems to be that people considering this task of converting…
    Parsing a CSV file is a task that we are confronted with regularly, and although there are a vast number of means to do this, as a newbie, the field can be confusing and the tools can seem complex. A simple solution to parsing a customized CSV fi…
    Need more eyes on your posted question? Go ahead and follow the quick steps in this video to learn how to Request Attention to your question. *Log into your Experts Exchange account *Find the question you want to Request Attention for *Go to the e…
    In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

    728 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now