943,864 Members | Top Members by Rank

Ad:
Jul 2nd, 2009
0

Please help me

Expand Post »
Hello my name is intekhab khab persuing BCA final
i have some problem in Visual basic coding as i dont know any thing about Visual basic i know c/c++ php Ajax but i dont familiar with visual basic 6.0.Sir gave me assignment and two days of only please help me ,the question of assignment are

01)Program which takes 10 records from the user, there are two buttons on the form. Display, Modify. On clicking the button display information about the requested record, on clicking modify, information of particular student should be changed.
02)Take Two LISTBOXS. First List box has 10 elements. There are three buttons.
i. >
ii. >>
iii. remove

on clicking first button selected item from first list box should be inserted into second one. If second button is clicked than all items of first should be inserted into second one (no duplicate element in second list box). On clicking third button selected element from the second list box should be deleted.
03) Create a menu
Color Font Case
Red Bold Lower
Green Italic Upper
Blue Bold And Italic
Font Name
Form has one Textbox, on clicking any option properties of textbox should change accordingly.

I know this programmes are too simple i alone do this but i have not familiar with this languages
Thank you

Pixelerator http://intekhab.co.cc
Reputation Points: 10
Solved Threads: 0
Newbie Poster
pixelerator is offline Offline
11 posts
since Jul 2009
Jul 3rd, 2009
0

Re: Please help me

To add items to a list box you use the additem method...
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. List1.AddItem "MyString"
To make your list box allow multiple selections set its multiselect property to true on/in the property box.

To run through the list to test which one(s) have been selected. Use a for loop...
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. Dim ForLoopCounter As Integer
  2. For ForLoopCounter = 0 To List1.ListCount - 1
  3. If List1.Selected(ForLoopCounter) = True Then
  4. 'do something
  5. End If
  6. Next ForLoopCounter
To remove an item or items from a list box. Once again use a for loop but this time do it backwards...
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. Dim ForLoopCounter As Integer
  2. For ForLoopCounter = List1.ListCount - 1 To 0 Step -1
  3. If List1.Selected(ForLoopCounter) = True Then
  4. List1.RemoveItem ForLoopCounter
  5. End If
  6. Next ForLoopCounter
use the menu editor to create your menu items and if you don't know how to use it, there are several tutorials out there, just search the web.

Now to enumerate through all the fonts on the system, use a for next loop...
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. For ForLoopCounter = 0 To Printer.FontCount - 1
  2. List2.AddItem Printer.Fonts(ForLoopCounter)
  3. Next ForLoopCounter


That should be enough to get you started. If you have any more questions google and yahoo are your friends as is this forum.


Good Luck
Reputation Points: 156
Solved Threads: 296
Posting Virtuoso
vb5prgrmr is offline Offline
1,670 posts
since Mar 2009
Jul 3rd, 2009
0

Re: Please help me

Thank you very musch now i am starting the coding
Reputation Points: 10
Solved Threads: 0
Newbie Poster
pixelerator is offline Offline
11 posts
since Jul 2009
Jul 5th, 2009
0

Re: Please help me

I succesfully created all the programmes but only in one programmes
i dont get how to change text of textbox on click event of menu item
upper
lower
Thanks for help
Reputation Points: 10
Solved Threads: 0
Newbie Poster
pixelerator is offline Offline
11 posts
since Jul 2009
Jul 5th, 2009
0

Re: Please help me

if you are talking UPPER CASE and lower case the look at UCASE and LCASE


Good Luck
Reputation Points: 156
Solved Threads: 296
Posting Virtuoso
vb5prgrmr is offline Offline
1,670 posts
since Mar 2009

This thread is solved

Either the thread starter or a moderator has marked this thread as solved. You can most likely trust the responses and answers given. There is most likely no reason for any further responses to be posted here. If you have a related question, please start a new thread in this forum instead.

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Visual Basic 4 / 5 / 6 Forum Timeline: Random color?
Next Thread in Visual Basic 4 / 5 / 6 Forum Timeline: transparent form prob!!





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC