Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7989987
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T12:53:17+00:00 2026-06-04T12:53:17+00:00

I have a wpf application which has combo box and multiple text boxes. On

  • 0

I have a wpf application which has combo box and multiple text boxes.

On the window load event the combo box is filled with the Employee IDs. When I select any ID then the below text boxes should display the name, city, zip, country of the selected “Id”.
I did wrote the below code for filling in the values in text boxes.
Private Sub dataview1(ByVal GUID As String)
Try

        Dim viewDs As New DataSet()
        Dim Query As String
        Query = "Select * from tblEmployeeInfo Where ID = '" & GUID.Trim & "'"
        viewDs = GetData(Query, True)

        Dim dv As DataView = New DataView(viewDs.Tables(0))
        Dim Notify As String = String.Empty
        If dv.Count > 0 Then

            If Not IsDBNull(dv(0)("ID")) Then
                txtGUID.Text = dv(0)("ID")
            Else
                txtGUID.Text = String.Empty
            End If

           If Not IsDBNull(dv(0)("StreetName"))     Then
                txtStName.Text = dv(0)("StreetName")
            Else
                txtStName.Text = String.Empty
            End If
        End If
    Catch ex As Exception
        MsgBox("No Values Found")
    End Try
End Sub

And called the above function on Selection Changed Event of Combo Box as below:

Private Sub ID CB_SelectionChanged(sender As System.Object, e As System.Windows.Controls.SelectionChangedEventArgs) Handles IDCB.SelectionChanged
    StreetCB.IsEnabled = False
   DataView1(IDCB.SelectedItem)

Though it hits the ViewMode Function but it never populates any values in my text boxes.

Am I missing any thing in it?

Is there any way I could achieve?

Any help will be much appreciated.

Thank you so much!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T12:53:18+00:00Added an answer on June 4, 2026 at 12:53 pm

    Though it hits the ViewMode Function but it never populates any values in my text boxes.

    Step through this in the debugger. This could happen if your query returns no results, which is, I suspect, the issue in this case.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a WPF application which has a main window composed from several custom
I am working on WPF application. I have a window which has Combobox and
In my WPF application, I have a main window (Branch.xaml) which has a button
I have a DataGrid in a WPF application which has for its ItemsSource a
I have a WPF application which has a DirectX component within it. This component
I have a WPF application which so far has been client only, but now
I have an WPF application which has a local rdlc report which show receipt
I have created an application which has a client (WPF) and the Server (WCF),
I have a WPF 3.5 MVVVM application which has a TextBlock in a ScrollViewer.
I have a WPF application with Main Window which is not a tool window

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.