307 Assignment

download 307 Assignment

of 12

Transcript of 307 Assignment

  • 8/3/2019 307 Assignment

    1/12

    TYBCA-307 | Practical based on 302 and 303VB Definitions (Final)

    Intrinsic controls and VB control structure basics:1 Create a new VB Project (welcome.prj). Place a button on the form and show welcome message on

    the click of the button using msgbox() function.2 Accept two numbers using Inputbox on the click of the button and display SUM of these twonumbers using Msgbox.

    3 Write down the program that changes the title of the Form. In this new title is entered usingInputbox.

    4 Design a form as shown below and perform the operations on the numbers entered.

    5 Accept two strings from two textboxes, join it and display its result in another textbox.

    6 Calculate the simple interest = p*r*n / 100 & power of the given number.

    7 Design a form as shown below to calculate the sum of N natural numbers and factorial of N. Usescrollbar to decide the value of N. Range of scrollbar is 1 to 10. Display result as per the optionbutton selected.

    Calculate the sum and factorial with the help of function.Function prototypes:Private function NaturalSum(ByVal n as Integer) as LongPrivate function Factorial(ByVal n as Integer) as Long

    8 Write the program that prints the prime numbers between the given range.

    9 Enter the string and convert it into Lower, Upper & Proper caseI/P: this is the TESTING of VBO/P: this is the testing of vb (When button for Lowercase clicked)

    THIS IS THE TESTING OF VB (When button for Uppercase clicked)

    This Is The Testing Of Vb (When button for Propercase clicked)10 Write the program that checks whether the given no. is binary or not. If the given no. is binary then

    display its equivalent Decimal value.

  • 8/3/2019 307 Assignment

    2/12

    11 Design a VB form as shown below to read the student data and generate the mark-sheet data.Clear the data when user clicks the Clear button. When user click on Exit then end the execution.

    12 Build a simple text editor as show below.

    13 Create form that have two text box for ID & NAME, two option button for MALE & FEMALE forgender and- ID should start from M or F letter.- If ID start form M then male option should automatically selected.- If ID start form F then female option should automatically selected.

    14 Create form that has text boxes for Uppercase, Lowercase & Number. Accept only valid key pressin each text box.

    15 Develop a VB Application to show image/picture. Design two forms as shown below one to acceptthe file and another to display the image. On click of the Display Picture and Display Imagebuttons show file open form to read the file name.

    Image Form Open File Form

    16 Design the digital watch using Timer Control.

  • 8/3/2019 307 Assignment

    3/12

    17 Develop an application that demonstrates CUT, COPY AND PASTE command in CLIP BOARDOBJECT

    18 Create form as shown below. When user clicks add button add the name in list box (Friend), usinglist box (Friend) enter selected name in another list box (Invite), also remove-selected name fromlist box.

    19 Develop an application that demonstrates OLE container control (Excel sheet & MSPaint object)

    20 Design the following calculator.

    21 Design the following form & perform various validations. All field values are compulsory. Acceptvalid values only.

    22 Design the Login Form as shown below.

  • 8/3/2019 307 Assignment

    4/12

    Show welcome message if user supplies both user id and password as Admin. And load mainform of the same project.Compare string values with case sensitive comparison.For invalid values ask again only for three times after that close application automatically.

    23 Design the following form. Whenever user enters the new city in text box & when use clicks onADD button then it will be added into the combo box.

    24 Design the following form using horizontal scrollbar. In this, when user click on particular scroll barthen back color of Form should change to the color using the Red, Green & Blue color values.

    25 Create form that has text boxes for Email Id & access code.- Accept only valid Email Id. An email is valid when

    o It contains only one @ and at least one . (dot) after @.

    o It [a-z, 0-9, .(dot) and _ (underscore)] characters only.

    o Example: [email protected] (valid) john.mathew@abccorp (invalid)

    - Valid access code must have three characters & first character should be numeric.o Example: AB (invalid), 1ty (invalid), abc (valid)

    - Display appropriate message for invalid entries.

    26Array handling in VB

    27 Sort the 1-D array elements in ascending / descending order by creating user defined Sort functionand print the original & outputted array.

    28 Enter 2 dimensional matrixes & find out their Sum, Subtraction & Multiplication & print the originaland outputted matrixes.

    29 Design a simple calculator using Control Array of Command Buttons.

    File Handling and Advanced Controls

  • 8/3/2019 307 Assignment

    5/12

    30 Create MDI form that has File & Edit Menu. Design a form to edit the text files. Allow the user toopen, modify and save text files. User common dialog box to read the file name for open and save.Provide facility of Cut, Copy, Paste, Insert Date Time, Upper Case, Lower Case from Edit Menu.Design the application so that it can open multiple files at same time.

    31 Design the following Form using Random Access file handling, in this when user clicks on WriteInto File button then content will be written into the file & when click on Read From the File then it

    will be displayed in the labels.

    32 Modify Application 30 and perform following.1. Add a toolbar control on the MDI form to perform operation like Open, Save, Close, Cut, Copy,

    Paste. And perform the operations when user clicks the toolbar. Add a menu item Options inthe MDI form with a checked submenu for Show Toolbar. When the toolbar is shown thismenu should be labeled as Hide Toolbar other wise Show Toolbar. On clicking this menushow/hide the toolbar appropriately.

    2. Add a status bar in the MDI form. Divide it in four panels and File Name, Last Operation,Date+Time (dd/mm/yyyy hh:mm am/pm) and Num lock status.

    33 Design a vb application to maintain hierarchical items using tree view as shown below:

    Apply various images to the nodes using ImageList control.

  • 8/3/2019 307 Assignment

    6/12

    34 Design a VB application to maintain the list of contacts using ListView control as shown below:

    Change the view when user selects a different view option from the combobox. Change the size ofthe listview control when user changes the form size. Provide Imagelist for the images of differentlistitem icons.

    35 Design the following form that shows the use of Slider control.

    36 Create form, perform specified operation using Rich Textbox Control.

    Choose font, size from combo box and provide its effect on the selected text.

    Provide fore color using scroll bars.

    Perform string operations.

  • 8/3/2019 307 Assignment

    7/12

    Database Programming37 Develop an application that demonstrates DAO with following buttons to navigate and maintain the

    data. Create an MS-Access Database Student.MDB with a Student table with followingstructure(Stud_no, Stud_name, Stud_bdt, mark1, mark2, mark3, total)

    1) To go to first record

    2) To go to last record3) To go to next record4) To go to previous record5) To go to find any record6) To add new record7) To edit existing record8) To cancel modification that Added or edited by mistaken

    38 Write a VB Application to maintain the records of EMP table in Oracle using ADODC Control.

    39 Create application to maintain the details of the Empolyee and Dept tables using ADODB code. Itincludes functionality of Navigation, Search, Add, Edit, Delete, Save, Cancel and Print appropriatelist.

    40 Develop a VB application to generate an invoice form as shown below using Adodc & DataGridcontrol. Use Combo Box for Addition or Deduction from Total and get Net amount.

    Inv_No

  • 8/3/2019 307 Assignment

    8/12

    41 Create an application that connects to employee table. The values for department field are fetchedfrom Department table through Data Combo. It includes commands for Adding and Saving data into employee database and Exiting. (Use DataCombo for Department)

    Use ADODC Control for the table data management.

    42 Create the table named as Student having the following fields:

    Filed Type Width Constraints/Validations

    Stud_No Num 3 Primary key. Only numbers are allowed

    Stud_Name VC2 40 Only alphabets & space.

    Year Num 4 Only numbers are allowed

    BCA301 Num 3 Only numbers are allowed

    BCA302 Num 3 Only numbers are allowed

    BCA303 Num 3 Only numbers are allowed

    BCA304 Num 3 Only numbers are allowed

    BCA305 Num 3 Only numbers are allowedTotal Num 3 Only numbers are allowed

    Create the following MDI form which contains the following design:

    In above form, Information menu bar contains Data Entry of Students. Data Entry form containscontrols to mange the entries of the student table. Each text box contains specific length of data.Calculate the total using programming.

    By selecting report, it will display following report for the given year.

  • 8/3/2019 307 Assignment

    9/12

    43 Create application for managing the data of EMP and DEPT tables.Then design the following MDI form, EMP and DEPT data entry forms. Forms for the reportparameters as shown below:In this user has to add the information of only Employee using coding while information ofDepartment is entered directly into the table.Add Add information only Emp table with all validations.

    Edit In this, user can select the employee number from Combo Box & appropriate data will bedisplay in textboxes.Delete In this, user can select the employee number from Combo Box. So user can delete onlyselected data.Search In this, user can enter the employee number in Text box if that data is available indatabase then that will be displayed in the Labels else display proper message.

    Employee Information : Display only Employee no, name, date of joining, designation, departmentname & salary.

    Dept Wise Report : Display Department No, Employee no, name, date of joining, designation,department name & salary. In this, user has to select the department no from the combo box &pass it as parameter. The format is given below :

    In this report, Sr no & Total Salary is calculated by user through programming. It displays currentdate.

    Designation Wise Report : Display Department No, Employee no, name, date of joining,

    designation, department name & salary. In this, user has to select the designation from the combobox & pass it as parameter.

    Joining Date Wise Report : This displays only those data whose joining date lies between the twogiven dates. Here, the both dates are selected using date picker control only.

    Exit: End of program.

    4

    4

    Create the following project. That contains MDI form and data entry forms. Design menu in MDIform as shown below.

    Also provide a status bar with panels as shown below:

  • 8/3/2019 307 Assignment

    10/12

    Design the data entry forms to maintain the table values using ADODB code.

    1. For entry of date use date picker control2. In first panel of status bar display your name.

    For address use the multiline text box

    3. Each text box contains specific length of data with validations for valid values only.4. Provide DATACOMBO for customer value in the Invoice Entry form.5. For primary key value use generalized AutoID() from genfunctions module.

    Add a module (PublicVars.bas) for public variables. Declare a public variable to store theconnection string, which will be used by the data entry forms to connect to the database. [Initialize itsvalue in the Load Event of the MDI form.]

    Add a module (GenFunctions.bas) for some general public functions and public variables forfollowing purpose:

    1. Autogenerate Primary key value

    Public Function AutoID(sConnStr as String, sPKFieldName as String, sTableName as String) as Long

    2. Find value of a particular field of given table matching crieteria.

    Public Function GetFieldValue(sConnStr as String, sPKFieldName as String, _sTableName as String, sCrieteria as String) as Variant

    While in Report bar there are 3 types of reports. Invoice, Customer Information & Item information.The format of Invoice report is given as below.

    While in Customer & Item information you have to display all information from respective mastertables & make the report in proper format.

    Invoice Report :Invoice report is displayed by passing particular Invoice number.When user click on Exit menu then end of project will be done.

    Table designs for this application is as described here:

  • 8/3/2019 307 Assignment

    11/12

    Customer table:

    Filed Type Width Constraints/Validations

    Custno(Customer Number) Number 3 Primary key. Must be start with C &0 to 9 numbers only.

    Custname(Customer Name) Varchar 40 Only alphabets & dot.

    Add Varchar 50 Alphanumeric

    City Varchar 15 Only alphabets & dot.

    Item table:

    Filed Type Width Constraints/Validations

    Ino(Item number) Number 3 Primary key. Must be start with I &0 to 9 numbers only.

    Iname (Item Name) Varchar 25 Alphanumeric

    Rate Number 9,2 Alphanumeric

    InvMaster table:

    Filed Type Width Constraints/Validations

    InvNo (Invoice number) Number 4 Primary key. 0 to 9 numbers only.

    Date (Invoice Date) Date - Date

    CustNo (Customer Number) Number 3 Must be start with C & 0 to 9numbers only.

    Total_amt Number 10,2

    InvDetail table:

    Filed Type Width Constraints/Validations

    InvNo (Invoice number) Number 4 0 to 9 numbers only.

    Ino (Item Number) Date - Must be start with I & 0 to 9 numbersonly.

    Qty (Quantity) Number 3 0 to 9 numbers only.

    Rate Number 9,2

    Amount Number 10,2

    Active X Controls: (Not to be included in practical exams)1 Design an ActiveX control using a textbox that types all characters in Capital only.

    2 Modify above control to provide a property (CharacterCasing) that decides character casing (Upper,Lowe, Mix).

    3 Design an ActiveX control using a textbox that allows only numeric values to be entered.

    4 Design an ActiveX control for calculator.

    FLASH: (Symbols are not included)1 Design a flash animation with 10 frames and put digits 0 to 9 one on each frame to give effect of

    changing digits from 0 to 9. (Manual animation without any tweening).

    2 Design a flash animation to scroll your name at the top of the stage from left to right, your collegename at the bottom of the stage from right to left. (Motion Tween)

    3 Design a flash animation to move two square objects on diagonal positions and also rotate themwhile moving as shown below.

  • 8/3/2019 307 Assignment

    12/12

    4 Create an animation which converts circle to square. (Shape Tween)

    5 Design a flash animation to move a circle/square object on the edges of the stage as shown below.Change the color as it reaches next corner.

    6 Develop a Flash program that shows the morphing effect on the text to image morph. (You can takeany text and any image).

    7 Develop a Flash program in which the letters of your name should be come from the differentdirections (one from left, one from right, one from top, one from bottom, one from top-left corneretc.) and form your name into the center of the screen.

    8 Create a movie that displays the formation of the water by using two Hydrogen and one Oxygenatom (H2O). One H atom comes from the left, another from the right, and the oxygen atom from thebottom. All are combine and form H2O and then convert it into the water picture by using morphing.

    9 Create a Birthday card, in which Happy Birthday is written on the top of the card. Threre is one

    candle in the side. And balloons are flying over from the card.10 Design a flash animation to generate effect of 3 rotating electrons in the orbit of an atom.

    11 Create an object kite & the kite should fly on a specific path. Create the appropriate environment.

    12 Create a ball and the ball should jump from left to right.

    H H

    O

    H2O WATER