We have been working very hard since 2009 to facilitate in your learning Read More. We can't keep up without your support. Donate Now.

www.bit.ly/vucodes

+ Link For Assignments, GDBs & Online Quizzes Solution

www.bit.ly/papersvu

+ Link For Past Papers, Solved MCQs, Short Notes & More

CS506 - Web Design and Development Assignment no 02 Solution And Discussion due date Dec 11, 2015


+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)

+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)

+ Click Here to Search (Looking For something at vustudents.ning.com?)

+ Click Here To Join (Our facebook study Group)


Views: 21715

Attachments:

Replies to This Discussion

mujh kuch samj ni arha.........

koi to cs506 my meri help karo............

jdk install kese karna he. aur code ko run kese karna he. pllllz anyone tell.

plzzz .java file upload kre koe

im having this error :( :( :(

koi Allah ka banda proper solution dy dy....

Error is becuase you are all not having these three files in same folder 

there should be three files in same folders like make a folder name mc130400939

in folder there should be three files Test.java then Student.java and input.txt file

then write command in cmd like that

c:\User\dastgeer>cd desktop

c:\User\dastgeer>desktop>cd mc130400939>

c:\User\dastgeer>desktop>cd mc130400939>javac Student.java

c:\User\dastgeer>desktop>cd mc130400939>javac Test.java

its will run 


import java.io.PrintStream;

import javax.swing.JFrame;
import javax.swing.JTextField;
import javax.swing.text.BadLocationException;
import javax.swing.text.Document;
import javax.swing.text.JTextComponent;
import javax.swing.text.View;

public class Main
{
  public static void main(String[] args)
  {
    JFrame f = new JFrame("Text Field View");
    JTextField tf = new JTextField();
    TextView input = (new TextView [findViewById]);R.id.textView1);
    TextView input = (new Textview [findViewById]);R.id.textView2);
      
    String buildings = getinput.txt("/home/mjehangir/Desktop/input.txt=True");

    //inputObject inputObject = new inputObject(buildings);
    inputArray queryArray = new inputArray(buildings);
    //queryArray = queryArray.getinputArray(0);
    List<String> list = new ArrayList<String>();
    for (int i=0; i<queryArray.length(); i++)
    {
      list.add( queryArray.getString(i) );
    }
    String text = list.get(0).toString();
    String arr[] = text.split(" ");
    arr[0] = arr[0].trim();
    for(int i=0;i>queryArray.length();++i)
    {
      input.setText(list[i]);
    }
    try
    {
      //tf.setText("name:Ali,Rollnumer:1)
      //tf.setText("name:Ahmad,Rollnumer:2,Marks:60");
      //tf.setText("name:Aysha,Rollnumer:3,Marks:80");
      //tf.setText("name:Hina,Rollnumer:4,Marks:90");
      // tf.setText("name:sana,Rollnumer:5,Marks:50");
      f.getContentPane().add(tf);
      f.pack();
      //f.setVisible(true);
      f.setSize(400, 200);
         
      f.setVisible(true);
     ViewDisplayer.displayViews(tf, System.out);
   }catch(Exception e){}
 }
}

class ViewDisplayer {
  public static void displayViews(JTextComponent comp, PrintStream out) {
    View rootView = comp.getUI().getRootView(comp);
    displayView(rootView, 0, comp.getDocument(), out);
  }

  public static void displayView(View view, int indent, Document doc,
      PrintStream out) {
    String name = view.getClass().getName();
    for (int i = 0; i < indent; i++) {
      out.print("\t");
    }

    int start = view.getStartOffset();
    int end = view.getEndOffset();
    out.println(name + "; offsets [" + start + ", " + end + "]");
    int viewCount = view.getViewCount();
    if (viewCount == 0) {
      int length = Math.min(32, end - start);
      try {
        String txt = doc.getText(start, length);
        for (int i = 0; i < indent + 1; i++) {
          out.print("\t");
        }
        out.println("[" + txt + "]");
      } catch (BadLocationException e) {
      }
    } else {
      for (int i = 0; i < viewCount; i++) {
        displayView(view.getView(i), indent + 1, doc, out);
      }
    }
  }
}

but srror come pls any one help me

program k end me mazeed } ye bracket lagao end of file while parsing wala error khatam ho jaye ga

to jdk net beans mai kya compile krna hai ??

bhai Average calculate ka code chahey..or ya code input wali file may likhna hy ya test.java wali file main

RSS

Latest Activity

Haram Iftekhar updated their profile
13 minutes ago
+M.Tariq Malik replied to +M.Tariq Malik's discussion ENG001 Elementary English GDB No 01 Fall 2020 Solution / Discussion Last Date: 04-12-2020 in the group ENG001 Elementary English
16 minutes ago
Sobia Abbasi liked +M.Tariq Malik's group MGT610 Business Ethics
16 minutes ago
+M.Tariq Malik replied to +M.Tariq Malik's discussion ENG001 Elementary English GDB No 01 Fall 2020 Solution / Discussion Last Date: 04-12-2020 in the group ENG001 Elementary English
17 minutes ago
+M.Tariq Malik liked +M.Tariq Malik's discussion ENG001 Elementary English GDB No 01 Fall 2020 Solution / Discussion Last Date: 04-12-2020
17 minutes ago
+M.Tariq Malik added a discussion to the group ENG001 Elementary English
17 minutes ago
Profile IconShahid Abbas, Alina nawaz, Sikandar and 8 more joined Virtual University of Pakistan
18 minutes ago
+M.Tariq Malik replied to +M.Tariq Malik's discussion CS601 Assignment 01 Fall 2020 Solution / Discussion in the group CS601 Data Communication
28 minutes ago
Sobia Abbasi posted a status
"mgt 610 ki gdb ki ksi ny"
29 minutes ago
Profile IconSobia Abbasi, Misbii Khan and иαвєєℓ αнмє∂ joined +M.Tariq Malik's group
32 minutes ago
+M.Tariq Malik replied to +M.Tariq Malik's discussion MGMT614 Supply Chain Management GDB No 01 Fall 2020 Solution / Discussion in the group MGMT614 Supply Chain Management
43 minutes ago
+M.Tariq Malik liked +M.Tariq Malik's discussion MGMT614 Supply Chain Management GDB No 01 Fall 2020 Solution / Discussion
43 minutes ago

Looking For Something? Search Here

© 2020   Created by +M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service

.