Jump to content
Xtreme .Net Talk

ArchAngel

Members
  • Posts

    7
  • Joined

  • Last visited

Everything posted by ArchAngel

  1. The fill command fills the data into other column that are invisible on the form. the querry only returns the first parameter value and not the rest also it does not catch the exception when it cant find the data to use to fill
  2. OleDbDataAdapter1.Fill(Login21) That handles your question
  3. It was ommited when i was testing to see if that was the error but i do have it in the code that is not working
  4. Hi Guys, I got a slight problem that could be very funny but i need help and fast. I am trying to create a logon page that takes the logon credential from a database but once i am using the multiple parameters the code does not check the parameters and just logs on even with wrong details....... This is the code for select statement Me.OleDbSelectCommand1.CommandText = "SELECT USERNAME, PASSWORD, GROUPTYPE FROM DBUSERS WHERE (PASS" & _ "WORD = ?) AND (USERNAME = ?)" Me.OleDbSelectCommand1.Parameters.Add(New System.Data.OleDb.OleDbParameter("USERNAME", System.Data.OleDb.OleDbType.VarChar, 20, "USERNAME")) Me.OleDbSelectCommand1.Parameters.Add(New System.Data.OleDb.OleDbParameter("PASSWORD", System.Data.OleDb.OleDbType.VarChar, 20, "PASSWORD")) Me.OleDbSelectCommand1.Parameters.Add(New System.Data.OleDb.OleDbParameter("GROUPTYPE", System.Data.OleDb.OleDbType.VarChar, 20, "GROUPTYPE")) This is the text retrieval and fill code OleDbDataAdapter1.SelectCommand.Parameters("USERNAME").Value = txtusername.Text OleDbDataAdapter1.SelectCommand.Parameters("PASSWORD").Value = txtPwd.Text OleDbDataAdapter1.SelectCommand.Parameters("GROUPTYPE").Value = gptype.Text Login21.Clear() Try OleDbDataAdapter1.Fill(Login21) Catch ex As Exception MessageBox.Show("Logon Failed", "Logon Error") End Try what am i doing wrong? i have to present this application at Uni tomorrow help!!!!!!!!!!!!!!!!!!!!! :o :o :o :o
  5. Yes i have an instance open...... The MDi parent is already open so i dont need to create a new instance of it. The problem seems to be using variables to reference the mdi parent i.e. frm1.mdiparent = frm0 if i was writting the code on the frmMainMdi it would not have this problem because i would not use a variable i would use "me" ,,,,, :confused: guys pls get back to me..... i am dieing here.
  6. Dim frm0 as frmMainMdi Dim frm1 As New frmAsset_new frm1.MdiParent = frm0 frm1.Show() Me.Close() Boys and Girls it is obvious that i am no genius but can anyone explain why i cannot frmAsset_new as a Mdi child under frm0 i. i seem to only to be able to do it using either the menu item click ..... with frm1.Mdiparent = me..... is there a variable i could use that will aloow me do this? thanks guys :confused: :confused: :confused:
×
×
  • Create New...