6 Replies - 667 Views - Last Post: 15 February 2013 - 08:45 AM Rate Topic: -----

#1 prince0   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 8
  • Joined: 11-February 13

VB Help

Posted 13 February 2013 - 08:01 AM

i am getting this error on BV 2010 when trying to add ID number... its get duplicated which shouldnt have, need to make a error message on the statusstrip "Cannot add duplicate student ID". at the moment i dont gett an error message but ID do get duplicated on the list box which i do not want. help pls... thanks an advance...
Is This A Good Question/Topic? 0
  • +

Replies To: VB Help

#2 lar3ry   User is offline

  • Coding Geezer
  • member icon

Reputation: 314
  • View blog
  • Posts: 1,296
  • Joined: 12-September 12

Re: VB Help

Posted 13 February 2013 - 10:28 AM

Without seeing any of your code, you are not likely to get any meaningful help.
Was This Post Helpful? 0
  • +
  • -

#3 IronRazer   User is offline

  • Custom Control Freak
  • member icon

Reputation: 1498
  • View blog
  • Posts: 3,796
  • Joined: 01-February 13

Re: VB Help

Posted 13 February 2013 - 10:46 AM

Hi prince0,
It would help to see the code that adds the items to the listbox but, if you just want the status strip label to have a message telling you that you tried to enter an id number that the listbox already has in it then try something like this.

    Private Sub Button_AddID_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button_AddID.Click
        If ListBox1.Items.Contains(TextBox_ID.Text) Then
            ToolStripStatusLabel1.Text = "No duplicates allowed"
        Else
            ListBox1.Items.Add(TextBox_ID.Text)
            ToolStripStatusLabel1.Text = ""
        End If
    End Sub


Was This Post Helpful? 0
  • +
  • -

#4 prince0   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 8
  • Joined: 11-February 13

Re: VB Help

Posted 13 February 2013 - 07:08 PM

thanks guys, pls find attached my project...
Was This Post Helpful? 0
  • +
  • -

#5 prince0   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 8
  • Joined: 11-February 13

Re: VB Help

Posted 13 February 2013 - 07:14 PM

i believe my attachment did not go through huh!
Was This Post Helpful? 0
  • +
  • -

#6 lar3ry   User is offline

  • Coding Geezer
  • member icon

Reputation: 314
  • View blog
  • Posts: 1,296
  • Joined: 12-September 12

Re: VB Help

Posted 13 February 2013 - 07:58 PM

View Postprince0, on 13 February 2013 - 08:14 PM, said:

i believe my attachment did not go through huh!

To show us your code, go into the Visual Studio editor, copy the code, then paste it into the message editor here, select the entire block of code you just pasted, and click on the CODE thing above the editor window.
Was This Post Helpful? 0
  • +
  • -

#7 prince0   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 8
  • Joined: 11-February 13

Re: VB Help

Posted 15 February 2013 - 08:45 AM

View Postlar3ry, on 13 February 2013 - 09:58 PM, said:

View Postprince0, on 13 February 2013 - 08:14 PM, said:

i believe my attachment did not go through huh!

To show us your code, go into the Visual Studio editor, copy the code, then paste it into the message editor here, select the entire block of code you just pasted, and click on the CODE thing above the editor window.


thanks...

View Postprince0, on 15 February 2013 - 10:41 AM, said:

View Postlar3ry, on 13 February 2013 - 09:58 PM, said:

View Postprince0, on 13 February 2013 - 08:14 PM, said:

i believe my attachment did not go through huh!

To show us your code, go into the Visual Studio editor, copy the code, then paste it into the message editor here, select the entire block of code you just pasted, and click on the CODE thing above the editor window.


thanks...


i was trying to attach the whole zip file through attachment section (browse). when i do that it give me an error message. but its all good now b'coz i finished my project with help of a another person (1on1) thanks all...
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1