Need java help urgent plzzz

Ive never visited a Java forum other than this one and its been over 2 years now. Out of curiosity I just went to JavaRanch.
Ive seen a lot of heated flaming from both sides (on these forums)
but i figured id take a look today.
The FIRST post i look at someone asks what the purpose of an
interface is and one of the responses he gets is:
"Please revise your display name to meet the JavaRanch Naming Policy. To maintain the friendly atmosphere here at the ranch, we like folks to use real (or at least real-looking) names, with a first and a last name.
You can edit your display name here. Thank you for your prompt attention!"
i wish i could go to 33 pt font: WTF IS THAT?
WEIRD!
Thats just way to creepy for me and im out... as if the brown and the
meesen (brian regan joke) everywhere werent enough.
Anyone know any other good ones?
http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi?ubb=get_topic&f=33&t=019908

JavaRanch scares me as well. Yea i think the ranch is making an army of cattle.
Ill check out devshed.
http://www.javaranch.com/name.jsp
SO F*CKING SCARY:
"I understand that in some cultures there is no such thing as "first name and last name" - there is just one name. If you are one of these people, I WOULD LIKE TO HUMBLY ASK YOU TO SACRIFICE A PIECE OF YOUR CULTURE to help me build this culture."
apparently the cows love the policy though:
http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi?ubb=get_topic&f=10&t=001017

Similar Messages

  • I need you help urgently my job is on the line

    I really need you help it is very urgent as my job is in trouble! In may my I phone got lost I had all back up on my me account and Managed to save my contact list on my I pad however the next day after my I phone got stolen , the mobile me was closed and when I started using I cloud I could not find my list.
    I never update my I pad to I tunes but recently when I got my I phone 5 and my mini I pad by mistake when I was synchronizing all the list got deleted ! Please help me I need to get it bk! If you can manage to find it somewhere please help me find the contact list.
    Thank you

    If you were syncing your contacts with your computer via MobileMe then your contacts should be in the contact manager you sync with on your computer.
    If not, and you haven't maintained offline backups of your contacts, or didn't move your account to iCloud before last June, and haven't ever synced your devices to your computer then your data is gone. It can't be retrieved because it doesn't exist anywhere else, as you haven't followed Apple's directions for backing up and syncing.

  • Convert C++ prog into Java( I m new in java)help urgent

    hi all,
    i am very new in java. i have code of C++.i have to convert it in to Java.please help me on urgent basis.plz provide me solution.
    I am looking for positive response.code is below:
    #include <stdio.h>
    #include <string.h>
    #include <stdlib.h>
    #include <sys/stat.h>
    #include <fstream.h>
    #include <iostream.h>
    //#include <sha.h> //24112003
    //#include<wincrypt.h>
    char ntc(unsigned char n){
    if (n<26) return 'A'+n;
    if (n<52) return 'a'-26+n;
    if (n<62) return '0'-52+n;
    if (n==62) return '+';
    if (n==63)return '/';
    unsigned char ctn(char c){
    if (c=='/') return 63;
    if (c=='+') return 62;
    if ((c>='A')&&(c<='Z')) return c-'A';
    if ((c>='a')&&(c<='z')) return c-'a'+26;
    if ((c>='0')&&(c<='9')) return c-'0'+52;
    if (c=='~') return 80;
    return 100;
    int b64decode(char from,char to,int length){
    unsigned char c,d,e,f;
    char A,B,C;
    int i;
    int add;
    char *tot=to;
    for (i=0;i+3<length;){
    add=0;
    A=B=C=0;
    c=d=e=f=100;
    while ((c==100)&&(i<length)) c=ctn(from[i++]);
    while ((d==100)&&(i<length)) d=ctn(from[i++]);
    while ((e==100)&&(i<length)) e=ctn(from[i++]);
    while ((f==100)&&(i<length)) f=ctn(from[i++]);
    //if (f==100) return -1; /* Not valid end */
    if (c<64) {
    A+=c*4;
    if (d<64) {
    A+=d/16;
    B+=d*16;
    if (e<64) {
    B+=e/4;
    C+=e*64;
    if (f<64) {
    C+=f;
    to[2]=C;
    add+=1;
    to[1]=B;
    add+=1;
    to[0]=A;
    add+=1;
    to+=add;
    if (f==80) return to-tot; /* end because '=' encountered */
    return to-tot;
    int b64get_encode_buffer_size(int l,int q){
    int ret;
    ret = (l/3)*4;
    if (l%3!=0) ret +=4;
    if (q!=0){
    ret += (ret/(q*4));
    /* if (ret%(q/4)!=0) ret ++; */ /* Add space for trailing \n */
    return ret;
    int b64strip_encoded_buffer(char *buf,int length){
    int i;
    int ret=0;
    for (i=0;i<length;i++) if (ctn(buf)!=100) buf[ret++] = buf [i];
    return ret;
    int b64encode(char from,char to,int length,int quads){
    // 3 8bit numbers become four characters
    int i =0;
    char *tot=to;
    int qc=0; // Quadcount
    unsigned char c;
    unsigned char d;
    while(i<length){
    c=from[i];
    *to++=ntc(c/4);
    c=c*64;
    i++;
    if (i>=length) {
    *to++=ntc(c/4);
    *to++='~';
    *to++='~';
    break;
    d=from[i];
    *to++=ntc(c/4+d/16);
    d=d*16;
    i++;
    if (i>=length) {
    *to++=ntc(d/4);
    *to++='~';
    break;
    c=from[i];
    *to++=ntc(d/4+c/64);
    c=c*4;
    i++;
    *to++=ntc(c/4);
    qc++; /* qz will never be zero, quads = 0 means no linebreaks */
    if (qc==quads){
    *to++='\n';
    qc=0;
    /* if ((quads!=0)&&(qc!=0)) to++='\n'; / /* Insert last linebreak */
    return to-tot;
    char* mEncryptPassword(char* mPassword)
    char mEncryptedPassword[200]; // To hold encrypted password.
    //char* mEncryptedPassword = new char[200];
    char mPrimEncryptedPassword[200];
    char * temp = new char[200];
    //unsigned char* md; // 19122003
    //md = new unsigned char[100]; // 19122003
    memset(mEncryptedPassword, '\0', sizeof(mEncryptedPassword));
    memset(mPrimEncryptedPassword, '\0', sizeof(mPrimEncryptedPassword));
    strcpy(mPrimEncryptedPassword, mPassword);
    //strcpy(mPrimEncryptedPassword, (char*) SHA1((unsigned char*) mPassword, strlen(mPassword), NULL));
    //strcpy(mEncryptedPassword, (char*) SHA((unsigned char*) mPassword, strlen(mPassword), md)); // 19122003
    //strcpy(mEncryptedPassword, (char*) SHA((unsigned char*) mPassword, strlen(mPassword), md)); //19122003
    b64encode(mPrimEncryptedPassword, mEncryptedPassword, strlen(mPrimEncryptedPassword), 0);
    // If successfully encrypts..
    if (mEncryptedPassword != NULL)
    //char * temp = new char[strlen(mEncryptedPassword)+1];
    strcpy(temp,mEncryptedPassword);
    // strcpy(mRetVal,mEncryptedPassword);
    return (char*)temp;
    //return (mEncryptedPassword);
    //return (char*) md; // 19122003
    else
    return ("Error");
    char* mDecryptPassword(char* mPassword)
    char mDecryptedPassword[200]; // To hold decrypted password.
    char mPrimDecryptedPassword[200];
    char * temp = new char[200];
    // 02032007
    memset(mDecryptedPassword, '\0', sizeof(mDecryptedPassword));
    memset(mPrimDecryptedPassword, '\0', 200);
    strcpy(mPrimDecryptedPassword, mPassword);
    b64decode(mPrimDecryptedPassword, mDecryptedPassword, strlen(mPrimDecryptedPassword));
    // If successfully decrypts..
    if (mDecryptedPassword != NULL)
    //char * temp = new char[strlen(mEncryptedPassword)+1];
    strcpy(temp,mDecryptedPassword);
    // strcpy(mRetVal,mDecryptedPassword);
    return (char*)temp;
    //return (mEncryptedPassword);
    //return (char*) md; // 19122003
    else
    return ("Error");
    void main(int argc, char* argv[])
    cout << mEncryptPassword(argv[1])<<endl<<flush;
    cout << mDecryptPassword(mEncryptPassword(argv[1]))<<endl<<flush;
    Anubhav

    endasil wrote:
    I just thought of how ridiculous this would sound in any other profession:
    Surgeons:
    plz plz help I have patient dying need to insert new kidney into 90yr old patient plz someone come do itLawyers:
    Help client guilty need good defense (I m new in law)help urgentHow come we get stuck with the lazy low-lifes?Because there's no legal requirement that a software developer must be licensed

  • VB Programmer needs java help

    I am a VB programmer and have started to learn Java a little bit. I need this program to be written anytime by Monday, but it must be written in java because they plan to use it on multiple platforms. Our java programmer quit and I don't know enough to write it in java. The program is to figure payroll. The user will input their name and remove the check in the hourly check box if they are salaried. If the employee is hourly, then any hours worked over 40 are time and a half. If they are salaried, they must choose what company level they are. I have included the three salary levels below. The program then needs to print to the screen in the bottom text box their yearly salary computed for a 40 hour work week. Can anyone help me and write the program? Whoever will do this for me, I will award 34 duke dollars. That is all I have.
    Thank you so much for your help,
    Kori
    Name:
    Text box here for name
    (check box) Hourly
    Hours:
    Text box here for hours
    (option button) Level 1
    (option button) Level 2
    (option button) Level 3
    (option button) Level A
    (option button) Level B
    Total Pay:
    Number Processed:
    (command button) (command button)
    Calculate Pay__________Clear
    (text box)
    shows "payoll report"
    Level 1 = 6.25f
    Level 2 = 8.15f
    Level 3 = 10.85f
    Level A = 27000f
    Level B = 42000f
    Max hours is 80.0f

    I am a VB programmer and have started to learn Java a
    little bit. I need this program to be written anytime
    by Monday, but it must be written in java because they
    plan to use it on multiple platforms.Do this this little toy program in VB so you have a working solution on one platform by Monday. Show it to your boss and say you did a rapid prototype first for people to evaluate. Then take your time and convert it to Java.
    /Ulrika the pragmatical.

  • Oracle developer needs Java help

    I develop applications in Oracle 8i on NT4. As part of a trigger, I need to perform an update to an extremely large table which takes many minutes. Because it's tied to a web page, I can't wait for the update to complete. Oracle natively doesn't support system calls -- I use the Shell() command in VB -- but Oracle DOES support Java stored procedures. I'm hoping that a Java stored procedure will be able to spawn/execute a new process/program specified by a command line instruction (ie: "C:\SQLPLUS.EXE SCOTT/TIGER @update.sql") and return immediately - without waiting for the process to complete. There doesn't need to be any handle for or call back from the process - just fire and forget. Can anyone provide me some direction, or better some existing Java code that does this? THANKS!

    Hi "todmcg",
    I'm not sure that I have understood your question correctly, but here goes anyway...
    Yes you can create a java stored procedure and have a trigger execute that procedure. In order to execute system commands in java, you usually use the "exec()" method of class "java.lang.Runtime". It is also easy to spawn new threads using java. So yes, you can have your java stored procedure execute a system command in a background thread.
    In my opinion, the Oracle documentation explains very well how to create a java stored procedure. The documentation is available from:
    http://tahiti.oracle.com
    Also, examples of how to call system commands from java stored procedures are available at this Web site:
    http://asktom.oracle.com
    You may also find relevant information at:
    http://metalink.oracle.com
    and
    http://technet.oracle.com
    Of-course, you can also use JDBC from your java stored procedure to execute your "update.sql" script -- without the need to execute a system command.
    Basic code skeleton:
    [NOTE: Untested and may contain syntax errors.]
    public class SystemCommand implements Runnable {
      private static String cmd;
      public void run() {
        Runtime runtime = Runtime.getRuntime();
        runtime.exec(cmd);
      public static void execCommand(String cmd) {
        this.cmd = cmd;
        new Thread(new SystemCommand()).start();
    }Hope this helps you.
    Good Luck,
    Avi.

  • Writting to file(need yr help)--- URGENT

    HI , i need the data "text field " from data base to be in one line with "@!" if more than 36000 char it will be apend "@@" but still i am not able to get the output.
    i need the only col "text" tobe in one line . and attached the code.
    CAN ANY ONE HELP ME OUT.........
    private void writeField(BufferedWriter w, String dbfield, int width) throws Exception {
                   if (dbfield == null) {
                             dbfield = " ";
                   w.write(dbfield);
                   int diff = 0;
                   if (dbfield.length() < width) {
                             diff = width - dbfield.length();
                             for (int i = 1; i <= diff; i++)
                                       w.write(" ");
    // i am calling the write method.
    private boolean writeData() {
                   String columnType = null;
                   String val = null;
                   try {
                        BufferedWriter w = new BufferedWriter(
                                  new OutputStreamWriter(
                                            new FileOutputStream(
                                                      "C:\\Documents and Settings\\mdash\\Desktop\\java_Project_work\\TEXT2.ftm"),
                                            "8859_1"));
                        while (rs.next()) {
                             for (int i = 1; i <= noOfColumns; i++) {
                                  val = (String)rs.getString(metaData.getColumnName(i));
                                  if (((String)colNameAL.get(i-1)).equals("text")) {
                                       if (val!=null)
                                            val=val.replaceAll("\n", "\r");
                                            val =val.replaceAll("\r", "@!").trim();
                                       writeField(w, val, 36000);
                                  } else {
                                       if (val!=null)
                                       //     val=val.replaceAll("\n", "\r");
                                            val=val.replaceAll("\n", "@@");
                                       writeField(w, val,(int)metaData.getColumnDisplaySize(i));
                                  if (i != noOfColumns)
                                       w.write(" ");
                             w.write("\n");
                        w.flush();
                        w.close();
                        if (con != null) {
                             try {
                                  con.close();
                             } catch (SQLException e) {
                                  e.printStackTrace();
                        System.out.println("Done");
                        return true;
                   } catch (Exception e) {
                        e.printStackTrace();
                        return false;
              }

    this code is writting 2 files with and the files have to come in one line text , but it is comming in multiple line . thinking some problem in the
    if (((String)colNameAL.get(i-1)).equals("text")) {
                                       if (val!=null)
                                            val=val.replaceAll("\n", "\r");
                                            val =val.replaceAll("\r", "@!");
                                       writeField(w, val, 36000);
                                  } else {
                                       if (val!=null)
                                       //     val=val.replaceAll("\n", "\r");
                                            val=val.replaceAll("\n", "@@");
                                       writeField(w, val,(int)metaData.getColumnDisplaySize(i));
                                  }//// i am trying to repalce with " \r " still it is throwing error.

  • Newbie needs java help

    Hi,
    I have used Captivate for a while, but have no idea where to
    begin to insert JavaScript into Captivate. Everyone talks about it,
    but I can't find a very basic beginner explanation for this. I
    don't even know WHERE to put the JavaScript.

    Dear Altruistic
    Thanks for the link to the Netbeans quickstart webpage sadly it does not contain any visual cues as to what proceedures are neccessary to implement the instructions.
    For someone like me ( learning disability) this can cause difficulties I learn in a slightly different way to those who are able to assimilate written instructions.
    The text might as well have been ancient Greek ...
    I really need a discriptive walk through lets give an exampleso you will understand my needs ... say I wanted to open a Microsoft word document on the desktop of a windows PC (ok not a good choice but there you are ) here is how I would begin to write the proceedure
    1. look at the bottom left hand side of your screen
    can you see a windows symbol with start displayed ?
    yes ..
    Hold your mouse over the start icon and left click .. then use the cascading menu feature to select office 2003 ...
    Do you get the general idea about what I need here ....?
    So have a look at the link on my original post that points to David Eck's website where he lists some Java source code and if possible give me the proceedure of how to run this from within the Netbeans environment.
    Once I can do this I will be able to teach myself ....
    I guess in a nutshell what I am saying is why on earth is their not just a simple feature on the GUI that allows you to import some code and for Netbeans to run in Demo mode ! I know their is sample projects included within the application but here again this does not solve my problem of notbeing able to find a way to run source code from the application.
    I hope this makes sense !

  • Need java help

    hi, i hope this is the right place to put this question. i have a optiplex gxi with a 3geg. hardrive. and 64mb of ram.with windows me. when i download java to play on pogo the games will load but they drag and freeze up. the only java download i can get is jre 5.0 update 16 i think i have uninstalled it compleatly.because i keep getting all kinds of errors one i get is ie6 will hang and i get a send to microsoft error report. when i try to update java i get an error number 1723 windows installer error. i can not update the windows installer or even download net framework. please can someone help. (i miss pogo) i have tried to install msjvm but that doesn't work either. sorry for my typeing skills i hope you can help thank you.

    brightsmile29 wrote:
    thank you for your reply however my computer is not compatable with ie7 i have windows me. whice is not supported. and i can not download java so therefore i have no java installed. any help would be gratefull.That ME based system is beyond it's life span at this point in time. You can use JRE's that were developed about that time--Up to 1.4x (I think, you may get away with early 5).
    So basically you have to face reality--that OS, machine, and JVM's have fallen off the grid for the most current games.
    If you have completely uninstalled Java, then run regclean several times and then load the last usable version of Java that you have had installed in the past--and realize, the newer stuff is not made for that era of machine.

  • Help URGENTLY PLZZZ on JTEXTFIELD

    How can I prevent my JTextfeld to accept any other values except numbers? I want that it shouldn't except any string value or special characters. But it should accpet only numbers? I also want to fix the number of digits that can be entered into the above-mentioned JTextfield. Can anyone help me in doing this?

    Hi
    import javax.swing.*;
    import java.awt.event.*;
    import javax.swing.text.*;
    import java.awt.*;
    public class Mfield extends JTextField
    public Mfield()
        super(1);
    protected Document createDefaultModel()
         return new EngDocument();
    public class EngDocument extends PlainDocument
    public void insertString(int offs, String str, AttributeSet a)
                              throws BadLocationException
         for (int i=0 ;i < str.length(); i++)
              if (Character.isDigit(str.charAt(i)))
                     super.insertString(offs+i, str.substring(i,i+1) ,a);
    Noah

  • Need ur Help (Urgent)

    Hi all,
    Please give me a solution to the below problem.
    I’m executing an interactive report is executed for extracting the total cost value of product hierarchy, at first time the total cost is correct.
    But when we go back from 5th list to the 4th list and once again select the part number for viewing the total cost doubled and shows the incorrect cost for the part number.
    If once again I go back and select the part number to view the cost, then the cost value is Thrice to the original value and shows the incorrect cost for the part number.
    Thanks,
    Kanth

    Hi Kanth,
    The cost value needs to be cleared (initialized to zero) each time an action is performed.
    Use a CLEAR statement to clear the variable at the beginning.
    CLEAR <var1>
    This will always initialize the value to zero every time an activity takes place, and the value will not get doubled or tripled.
    Cheers.

  • Need Java Help on a Mortgage program

    I keep getting the following error.
    java:20: illegal start of expression
    public Scanner myScanner = new Scanner(System.in);
    /*Danielle Safonte*/
    /* Week 2 Mortgage Calculator*/
    import java.util.Scanner;
    import java.io.*;
    import java.text.*;
    public class Week2Assignment
    int principle = 200000;
    float interest = .0575;
    int term = 30;
    int months;
    float paymentdue;
    float calculation;
    public static void months()
    public Scanner myScanner = new Scanner(System.in);
    System.out.print("What month of the loan is this?" + months);
    if (months = term) {
    System.out.print("You have paid off your loan");
    else
         months = myScanner.next();
         float Jinterest = (interest / (months*100));
         calculation = principle * (Jinterest/(1-(1+Jinterest)^(-months))); /*Monthly payment*/
         float Minterest = principle * Jinterest; /*This months interest*/
         float Mprinciple = calculation - Minterest; /*This months principle*/
         float newBalance = principle - Mprinciple; /*This calculates the new principle*/
         if (newBalance = princple) {
              System.out.print("You have paid off your loan");
         else
              System.out.print("This months payment is: $", calculation); /*Displays the current months payment*/
              System.out.print("You have $", newBalance," left on your loan"); /*Displays the new principle balance*/
              System.out.print("This months principle is: $", Mprinciple ); /*Displays the new principle balance*/
    }

    It is in my post at 10:02, but here it is again:
    These are the errors that I am left with. I worked through the rest.
    .java:29: '.class' expected
    months = myScanner.next(int);
    ^
    .java:29: ')' expected
    months = myScanner.next(int);
    ^
    2 errors
    Tool completed with exit code 1
    import java.util.Scanner;
    import java.io.*;
    import java.text.*;
    public class Week2Assignment
    int principle = 200000;
    double  interest = .0575;
    int term = 30;
    int months;
    float paymentdue;
    float calculation;
    public void months()
    Scanner myScanner = new Scanner(System.in);
       System.out.print("What month of the loan is this?" + months);
    if (months == term) {
       System.out.print("You have paid off your loan");
    else
         months = myScanner.next(int);
         double Jinterest = (interest / (months*100));
         calculation = principle * (Jinterest/(1-(1+Jinterest)^(-months))); /*Monthly payment*/
         float Minterest = principle * Jinterest; /*This months interest*/
         float Mprinciple = calculation - Minterest; /*This months principle*/
         float newBalance = principle - Mprinciple; /*This calculates the new principle*/
         if (newBalance == princple) {
                 System.out.print("You have paid off your loan");
         else
                 System.out.print("This months payment is: $", calculation); /*Displays the current months payment*/
                 System.out.print("You have $", newBalance," left on your loan"); /*Displays the new principle balance*/
                 System.out.print("This months principle is: $", Mprinciple ); /*Displays the new principle balance*/
    }

  • Need for help urgently

    i use set which child(int childnum)
    but it doesn't draw the selected child
    it draws the last selected child in for loop
    don't when satsify the condition draw the child of this condition
    it draws the the child of last satsified condition at function draw flow
    i want to know the reason and how i solve it?
    package MockPrototype;
    import java.io.*;
    import java.lang.reflect.Array;
    import java.applet.Applet;
    import java.awt.*;
    import java.awt.event.*;
    import java.util.ArrayList;
    import java.util.BitSet;
    import java.util.Hashtable;
    import javax.media.j3d.*;
    import javax.swing.JFrame;
    import javax.vecmath.*;
    //import ExSwitch.NameChildMask;
    import com.sun.j3d.utils.geometry.*;
    import com.sun.j3d.utils.universe.*;
    import com.sun.j3d.loaders.Scene;
    import com.sun.j3d.loaders.objectfile.ObjectFile;
    import com.sun.j3d.loaders.ParsingErrorException;
    import com.sun.j3d.loaders.IncorrectFormatException;
    import com.sun.j3d.utils.behaviors.vp.*;
    import com.sun.j3d.utils.behaviors.interpolators.*;
    import com.sun.org.apache.xalan.internal.xsltc.cmdline.Transform;
    * This program demonstrates the use of KBRotPosScaleSplinePathInterpolator
    * in order to to do spline animation paths using Kochanek-Bartels (also
    * known as TCB or Tension-Continuity-Bias ) splines. A cone red cone
    * is animated along a spline path specified by 5 knot points, which
    * are showns as cyan spheres.
    * Use the left mouse button to changes orientation of scene.
    * Use the middle mouse button to zoom in/out
    * Use the right mouse button to pan the scene
    public class FlowProcess extends JFrame implements ActionListener,
                                                      AdjustmentListener,
                                                      ItemListener
        // 3D Canvas
        Canvas3D           canvas;
        // UI Components
        Panel              controlPanel;
        Panel              canvasPanel;
        Button             animateButton;
        Choice             interpChoice;
        Scrollbar          speedSlider;
        Label              speedLabel;
        Label              interpLabel;
        // Scene Graph
        BoundingSphere     bounds;
        BranchGroup        sceneRoot;
        BranchGroup        behaviorBranch;
        Transform3D        sceneTransform;
        TransformGroup     sceneTransformGroup;
        ArrayList <Transform3D>        objTransform0;
        ArrayList <Transform3D>        objTransform1;
        ArrayList <Transform3D>        objTransform2;
        ArrayList <TransformGroup>     objTransformGroup0;
        ArrayList <TransformGroup>     objTransformGroup1;
        ArrayList <TransformGroup>     objTransformGroup2;
        Transform3D        lightTransform1;
        Transform3D        lightTransform2;
        TransformGroup     light1TransformGroup;
        TransformGroup     light2TransformGroup;
        Color3f aColor     = new Color3f(0.2f, 0.2f, 0.2f);
        Color3f eColor     = new Color3f(0.0f, 0.0f, 0.0f);
        Color3f sColor     = new Color3f(1.0f, 1.0f, 1.0f);
        Color3f coneColor  = new Color3f(0.9f, 0.1f, 0.1f);
        Color3f coneColor1  = new Color3f(0.0f, 0.1f, 0.1f);
        Color3f coneColor2  = new Color3f(0.7f, 0.1f, 0.1f);
        Color3f sphereColor= new Color3f(0.1f, 0.7f, 0.9f);
        Color3f bgColor    = new Color3f(0.0f, 0.0f, 0.0f);
        Color3f lightColor = new Color3f(1.0f, 1.0f, 1.0f);
        // Key Frames & Interpolator
        int                                  duration = 5000;
        Alpha                                animAlpha;
        Transform3D                          yAxis;
        KBKeyFrame[]                         linearKeyFrames = new KBKeyFrame[2];
        KBRotPosScaleSplinePathInterpolator  linearInterpolator;
        // Data: Knot positions & transform groups
        Vector3f            pos0 = new Vector3f (0.0f, 0.0f, 0.0f);
        Vector3f            pos1 = new Vector3f (0.0f,  20.0f, 0.0f);
        Vector3f            pos2 = new Vector3f ( 20.0f,  0.0f, 0.0f);
       /* Vector3f            pos3 = new Vector3f ( 0.0f, -5.0f,  0.0f);
        Vector3f            pos4 = new Vector3f ( 5.0f, -5.0f,  0.0f);
        Vector3f            pos5 = new Vector3f ( 5.0f,  5.0f,  0.0f);*/
        Point3f []po = new Point3f[3];
        po[0]=new Point3f(pos0);
        po[1]=new Point3f(pos1);
        po[2]=new Point3f(pos2);
        TransformGroup     k0TransformGroup;
        TransformGroup     k1TransformGroup;
        TransformGroup     k2TransformGroup;
        TransformGroup     k3TransformGroup;
        TransformGroup     k4TransformGroup;
        TransformGroup     k5TransformGroup;
        Group scene;
        protected TransformGroup exampleViewTransform = null;
         protected TransformGroup exampleSceneTransform = null;
         private DirectionalLight headlight = null;
         private SharedGroup column = new SharedGroup( );
         public final static Color3f White    = new Color3f( 1.0f, 1.0f, 1.0f );
         private boolean shouldCompile = true;
         private Switch swtch0 = null;
         private Switch swtch1 = null;
         private Switch swtch2 = null;
         private int currentSwitch = 0;
        // Flags
        boolean            animationOn = false;
        boolean            linear      = false;
    //   private SimpleUniverse u = null;
        int [][][]customerFlow;
        int unitsno;
       /* public FlowProcess() {
        public FlowProcess(int [][][]customerFlowNO,int unit) {
             customerFlow=customerFlowNO;
             this.setLayout(new FlowLayout());  
             objTransform0=new ArrayList(0);
             objTransform1=new ArrayList(0);
             objTransform2=new ArrayList(0);
            objTransformGroup0=new ArrayList(0);
            objTransformGroup1=new ArrayList(0);
            objTransformGroup2=new ArrayList(0);
            // Create the canvas and the UI
            canvasPanel = new Panel();
            controlPanel = new Panel();
            createCanvasPanel(canvasPanel);
            this.add(canvasPanel);
            createControlPanel(controlPanel);
            this.add(controlPanel);
            this.setVisible(true);
            this.setDefaultCloseOperation(EXIT_ON_CLOSE);
            this.setSize(500,600);
            unitsno=unit;
        public void destroy() {
         //u.cleanup();
         * This creates the control panel which contains a choice menu to
         * toggle between spline and linear interpolation, a slider to
         * adjust the speed of the animation and a animation start/stop
         * button.
        private void createControlPanel(Panel p) {
            GridBagLayout      gl  = new GridBagLayout();
            GridBagConstraints gbc = new GridBagConstraints();
            p.setLayout (gl);
            gbc.weightx = 100;  gbc.weighty = 100;
            gbc.fill = GridBagConstraints.BOTH;
            gbc.gridx = 0;  gbc.gridy = 5;
            gbc.gridwidth = 2;  gbc.gridheight = 1;
            animateButton = new Button("Stop Animation");
            p.add(animateButton, gbc);
            animateButton.addActionListener (this);
         * This creates the Java3D canvas
        private void createCanvasPanel(Panel p) {
            GridBagLayout      gl  = new GridBagLayout();
            GridBagConstraints gbc = new GridBagConstraints();
            p.setLayout(gl);
            gbc.gridx = 0;  gbc.gridy = 0;
            gbc.gridwidth = 5;  gbc.gridheight = 5;
            GraphicsConfiguration config =
               SimpleUniverse.getPreferredConfiguration();
            canvas = new Canvas3D(config);
            canvas.setSize(490,490);
            p.add(canvas,gbc);
         public Group buildScene( )
              Group scene = new Group( );
              KBKeyFrame []KKF;
              swtch0 = new Switch( );
              swtch1 = new Switch( );
              swtch2 = new Switch( );
              swtch0.setCapability( Switch.ALLOW_SWITCH_WRITE );
              swtch1.setCapability( Switch.ALLOW_SWITCH_WRITE );
              swtch2.setCapability( Switch.ALLOW_SWITCH_WRITE );
              swtch0.setCapability( Switch.ALLOW_SWITCH_READ );
              swtch1.setCapability( Switch.ALLOW_SWITCH_READ );
              swtch2.setCapability( Switch.ALLOW_SWITCH_READ );
              objTransform0.add(0,new Transform3D());
             objTransformGroup0.add(0,new TransformGroup(objTransform0.get(0)));
             objTransformGroup0.get(0).setCapability(TransformGroup.ALLOW_TRANSFORM_WRITE);
             Material m1 = new Material(coneColor, eColor, coneColor, sColor, 100.0f);
             Appearance a1 = new Appearance();
             m1.setLightingEnable(true);
             a1.setMaterial(m1);
             Sphere sp1 = new Sphere(0.2f);
             sp1.setAppearance(a1);
             objTransformGroup0.get(0).addChild(sp1);
              swtch0.addChild(objTransformGroup0.get(0));
              objTransform1.add(0,new Transform3D());
             objTransformGroup1.add(0,new TransformGroup(objTransform1.get(0)));
             objTransformGroup1.get(0).setCapability(TransformGroup.ALLOW_TRANSFORM_WRITE);
             Material m5 = new Material(coneColor, eColor, coneColor, sColor, 100.0f);
             Appearance a5 = new Appearance();
             m5.setLightingEnable(true);
             a5.setMaterial(m5);
             Sphere sp5 = new Sphere(0.3f);
             sp5.setAppearance(a5);
             objTransformGroup1.get(0).addChild(sp5);
              swtch0.addChild(objTransformGroup1.get(0));
              objTransform2.add(0,new Transform3D());
             objTransformGroup2.add(0,new TransformGroup(objTransform2.get(0)));
             objTransformGroup2.get(0).setCapability(TransformGroup.ALLOW_TRANSFORM_WRITE);
             Material m7 = new Material(coneColor, eColor, coneColor, sColor, 100.0f);
             Appearance a7 = new Appearance();
             m7.setLightingEnable(true);
             a7.setMaterial(m7);
             Sphere sp7 = new Sphere(0.6f);
             sp7.setAppearance(a7);
             objTransformGroup2.get(0).addChild(sp7);
              swtch0.addChild(objTransformGroup2.get(0));
              //swtch.setBounds(bounds);
              scene.addChild( swtch0 );
              //scene.addChild( swtch1 );
              //scene.addChild( swtch2 );
              return scene;
         * This creates the scene with 5 knot points represented by cyan
         * spheres, a cone obejct that will be transformed, and two directional
         * lights + and ambient light.
        public void createSceneGraph() {
             SimpleUniverse universe=new SimpleUniverse (canvas);
              Viewer viewer = universe.getViewer( );
              ViewingPlatform viewingPlatform = universe.getViewingPlatform( );
              exampleViewTransform = viewingPlatform.getViewPlatformTransform( );
              OrbitBehavior orbit = new OrbitBehavior(canvas,OrbitBehavior.REVERSE_ALL);          
              //BoundingSphere allBounds = new BoundingSphere(new Point3d(0.0, 0.0, 0.0), 100.0);
              BoundingSphere bounds =
                  new BoundingSphere(new Point3d(0.0, 0.0, 0.0), 100.0);
              orbit.setSchedulingBounds(bounds);
              viewingPlatform.setViewPlatformBehavior(orbit);
    //                Build the scene root
                    sceneRoot = new BranchGroup( );
                   // Build a transform that we can modify
                   exampleSceneTransform = new TransformGroup( );
                   exampleSceneTransform.setCapability(
                        TransformGroup.ALLOW_TRANSFORM_READ );
                   exampleSceneTransform.setCapability(
                        TransformGroup.ALLOW_TRANSFORM_WRITE );
                   exampleSceneTransform.setCapability(
                        Group.ALLOW_CHILDREN_EXTEND );
                   Group scene = this.buildScene( );
                   exampleSceneTransform.addChild( scene );
                   sceneRoot.addChild( exampleSceneTransform );
    //                Create transforms such that all objects appears in the scene
                    sceneTransform = new Transform3D();
                    sceneTransform.setScale(0.14f);
                    Transform3D yrot = new Transform3D();
                    yrot.rotY(-Math.PI/5.0d);
                    sceneTransform.mul(yrot);
                    sceneTransformGroup = new TransformGroup(sceneTransform);
                    sceneTransformGroup.setCapability(TransformGroup.ALLOW_TRANSFORM_WRITE);
                    sceneTransformGroup.setCapability(TransformGroup.ALLOW_TRANSFORM_READ);
                    sceneRoot.addChild(sceneTransformGroup);
    //                Create bounds for the background and lights
                    bounds =  new BoundingSphere(new Point3d(0.0,0.0,0.0), 100.0f);
                    // Set up the background
                    Background bg = new Background(bgColor);
                    bg.setApplicationBounds(bounds);
                    sceneTransformGroup.addChild(bg);
                    // Create the transform group node for the lights
                    lightTransform1 = new Transform3D();
                    lightTransform2 = new Transform3D();
                    Vector3d lightPos1 =  new Vector3d(0.0, 0.0, 2.0);
                    Vector3d lightPos2 =  new Vector3d(1.0, 0.0, -2.0);
                    lightTransform1.set(lightPos1);
                    lightTransform2.set(lightPos2);
                    light1TransformGroup = new TransformGroup(lightTransform1);
                    light2TransformGroup = new TransformGroup(lightTransform2);
                    sceneTransformGroup.addChild(light1TransformGroup);
                    sceneTransformGroup.addChild(light2TransformGroup);
                    // Create lights
                    AmbientLight ambLight = new AmbientLight(aColor);
                    Light        dirLight1;
                    Light        dirLight2;
                    Vector3f lightDir1 = new Vector3f(lightPos1);
                    Vector3f lightDir2 = new Vector3f(lightPos2);
                    lightDir1.negate();
                    lightDir2.negate();
                    dirLight1 = new DirectionalLight(lightColor, lightDir1);
                    dirLight2 = new DirectionalLight(lightColor, lightDir2);
                    // Set the influencing bounds
                    ambLight.setInfluencingBounds(bounds);
                    dirLight1.setInfluencingBounds(bounds);
                    dirLight2.setInfluencingBounds(bounds);
                    // Add the lights into the scene graph
                    sceneTransformGroup.addChild(ambLight);
                    sceneTransformGroup.addChild(dirLight1);
                    sceneTransformGroup.addChild(dirLight2);
                   // Create transform groups for each knot point
                    // knot point 0
                    Transform3D t3dKnot = new Transform3D();
                    t3dKnot.set (pos0);
                    TransformGroup k0TransformGroup = new TransformGroup(t3dKnot);
                    Material m4 = new Material(new Color3f(Color.YELLOW), eColor,new Color3f(Color.YELLOW), sColor, 100.0f);
                    Appearance a4 = new Appearance();
                    m4.setLightingEnable(true);
                    a4.setMaterial(m4);
                    Box box = new Box(2.0f,2.0f,2.0f,a4);
                    box.setAppearance(a4);
                   // column.addChild(box);
                    k0TransformGroup.addChild(box/*new Link(column)*/);
                    sceneTransformGroup.addChild(k0TransformGroup);
                    // knot point 1
                    t3dKnot = new Transform3D();
                    t3dKnot.set (pos1);
                    TransformGroup k1TransformGroup = new TransformGroup(t3dKnot);
                    Material m5 = new Material(new Color3f(Color.CYAN), eColor, new Color3f(Color.CYAN), sColor, 100.0f);
                    Appearance a5 = new Appearance();
                    m5.setLightingEnable(true);
                    a5.setMaterial(m5);
                    Box box1 = new Box(2.0f,2.0f,2.0f,a5); 
                    box1.setAppearance(a5);
                    k1TransformGroup.addChild(box1);
                    sceneTransformGroup.addChild(k1TransformGroup);
                    // knot point 2
                    t3dKnot = new Transform3D();
                    t3dKnot.set (pos2);
                    TransformGroup k2TransformGroup = new TransformGroup(t3dKnot);
                    Material m6 = new Material(new Color3f(Color.GREEN), eColor, new Color3f(Color.GREEN), sColor, 100.0f);
                    Appearance a6 = new Appearance();
                    m6.setLightingEnable(true);
                    a6.setMaterial(m6);
                    Box box2 = new Box(2.0f,2.0f,2.0f,a6);
                    box2.setAppearance(a6);
                    k2TransformGroup.addChild(box2);
                    sceneTransformGroup.addChild(k2TransformGroup);
                   drawflow();
          // Colors for lights and objects
          if ( shouldCompile )
                   sceneRoot.compile( );
              universe.addBranchGraph( sceneRoot );
              reset( );
        public void reset( )
              Transform3D trans = new Transform3D( );
              exampleSceneTransform.setTransform( trans );
              trans.set( new Vector3f( 0.0f, 0.0f, 10.0f ) );
              exampleViewTransform.setTransform( trans );
              //setNavigationType( navigationType );
         * This sets up the key frame data for the spline interpolator. Each knot
         * point has a scale and rotation component specified. The second argument
         * to KBKeyFrame (in this case 0) tells the interpolator that this is
         * to be interpolated using splines. The last three arguments to
         * KBKeyFrame are Tension, Continuity, and Bias components for each
         * key frame.
         * This sets up the key frame data for the linear interpolator. Each knot
         * point has a scale and rotation component specified. The second argument
         * to KBKeyFrame (in this case 1) tells the interpolator that this is
         * to be interpolated linearly. The last three arguments to TCBKeyFrame
         * are Tension, Continuity, and Bias components for each key frame.
        private KBKeyFrame[] setupLinearKeyFrames (int begin,int end) {
          // Prepare linear keyframe data
          Point3f p =new Point3f(po[begin]);
          System.out.print("positions is"+p+"\n");
          float head  = 0.0f;                          // heading
          float pitch = 0.0f;                          // pitch
          float bank  = 0.0f;                          // bank
          Point3f s = new Point3f(1.0f, 1.0f, 1.0f);   // uniform scale
          KBKeyFrame[] linearKeyFrames=new KBKeyFrame[2];
          linearKeyFrames[0] =
             new KBKeyFrame(0.0f, 1, p, head, pitch, bank, s, 0.0f, 0.0f, 0.0f);
          p =new Point3f(po[end]);
          System.out.print("positions is"+p+"\n");
          linearKeyFrames[1] =
             new KBKeyFrame(1.0f, 1, p, head, pitch, bank, s, 0.0f, 0.0f, 0.0f);
          return linearKeyFrames;
         * This sets up alpha for the interpolator
        private Alpha setupAnimationData (int times,int duration) {
          yAxis = new Transform3D();
          Alpha animAlpha = new Alpha (times,Alpha.INCREASING_ENABLE,0,0,duration,0,0,0,0,0);
          return animAlpha;
         * create a spline and a linear interpolator, but we will activate only
         * one in startInterpolator()
        private void createInterpolators (TransformGroup t,KBKeyFrame[] k,Alpha a)
             KBKeyFrame[] kk=new KBKeyFrame[2];
             kk[0]=k[0];
             kk[1]=k[1];
          BranchGroup behaviorBranch = new BranchGroup();
          KBRotPosScaleSplinePathInterpolator linearInterpolator =
             new KBRotPosScaleSplinePathInterpolator(a, t,new Transform3D(),kk);
          BoundingSphere bounds =  new BoundingSphere(new Point3d(0.0,0.0,0.0), 100.0f);
          linearInterpolator.setSchedulingBounds(bounds);
          behaviorBranch.addChild(linearInterpolator);
          t.addChild(behaviorBranch);
         * This activates one of the interpolators depending on the state of the
         * linear boolean flag which may be toggled by the user using the choice
         * menu.
        public void startInterpolator ()
            //linearInterpolator.setEnable(true);
         * Toggle animation 
        public void actionPerformed (ActionEvent event) {
          Object source = event.getSource();
          if (source == animateButton) {
            try {
              // toggle animation
              if (!animationOn) {
                animationOn = true;
                swtch0.setWhichChild(Switch.CHILD_NONE);
                //linearInterpolator.setEnable(false);
                animateButton.setLabel("Start Animation");
              } else {
                animationOn = false;
                startInterpolator();
                GridBagLayout      gl  = new GridBagLayout();
                GridBagConstraints gbc = new GridBagConstraints();
                canvasPanel.setLayout(gl);
                gbc.gridx = 0;  gbc.gridy = 0;
                gbc.gridwidth = 5;  gbc.gridheight = 5;
                GraphicsConfiguration config =
                    SimpleUniverse.getPreferredConfiguration();
                 canvas = new Canvas3D(config);
                 canvas.setSize(490,490);
                 canvasPanel.add(canvas,gbc);
                //linearInterpolator.setEnable(true);
                animateButton.setLabel("Stop Animation");
                createSceneGraph();
               // drawflow();
            } catch (Exception e) {
               System.err.println ("Exception " + e);
               e.printStackTrace();
         * Toggle the interpolators 
        public void itemStateChanged (ItemEvent event) {
          Object source = event.getSource();
          ItemSelectable ie = event.getItemSelectable();
          if (source == interpChoice) {
            try {
              if (ie.getSelectedObjects()[0] == "Spline") {
                linear = false;
              if (ie.getSelectedObjects()[0] == "Linear") {
                linear = true;
              startInterpolator();
            } catch (Exception e) {
               System.err.println ("Exception " + e);
         * Adjust the speed of the animations
        public void adjustmentValueChanged (AdjustmentEvent e) {
          int value = e.getValue();
          duration = 6000 - (500 * value);
          animAlpha.setIncreasingAlphaDuration(duration);
        public void drawflow()
             for(int i=0;i<unitsno;i++)
                  for(int j=0;j<2;j++)
                       for(int k=0;k<2;k++)
                            System.out.print(customerFlow[j][k]+"\n");
                        //System.out.print("i'm third loop ");
                        if(customerFlow[j][k][i]>0&&customerFlow[j][k][i]<5)
                             System.out.print("i'm small ball");
                             if(animationOn==true)
                                  break;
                             System.out.print("i'm small ball");
                             for(int x=0;x<1;x++)
                                  KBKeyFrame []KKF;
                                  KKF=setupLinearKeyFrames(j,k);
                                  Alpha a=setupAnimationData(1,5000);
                                  createInterpolators(objTransformGroup0.get(x),KKF,a);
                             //for(int t=0;t<3;t++)
                             System.out.print("i'm small ball");
                                  swtch0.setWhichChild(0);
                                  //swtch0.getChild(0).setPickable(true);
                             //swtch1.setWhichChild(Switch.CHILD_NONE);
                             //.setWhichChild(Switch.CHILD_NONE);
                             /*swtch0.setWhichChild( options[0].child );
                             swtch0.setChildMask( options[0].mask );*/
                        else if(customerFlow[j][k][i]>5&&customerFlow[j][k][i]<25)
                             if(animationOn==true)
                                  break;
                                  KBKeyFrame []KKF;
                                  KKF=setupLinearKeyFrames(j,k);
                                  Alpha a=setupAnimationData(1,5000);
                                  createInterpolators(objTransformGroup1.get(0),KKF,a);
                                  System.out.print("i'm mid ball");
                                  //swtch0.setWhichChild(Switch.CHILD_NONE);
                             //swtch2.setWhichChild(Switch.CHILD_NONE);
                             /*swtch0.setWhichChild( options[1].child );
                                  swtch0.setChildMask( options[1].mask );*/
                             swtch0.setWhichChild(1);
                             System.out.print("i'm mid ball");     
                        else if(customerFlow[j][k][i]>24)
                             if(animationOn==true)
                                  break;
                                  KBKeyFrame []KKF;
                                  KKF=setupLinearKeyFrames(j,k);
                                  Alpha a=setupAnimationData(1,10000);
                                  createInterpolators(objTransformGroup2.get(0),KKF,a);
                                  //swtch1.setWhichChild(Switch.CHILD_NONE);
                             swtch0.setWhichChild(2);
                                  /*swtch0.setWhichChild( options[2].child );
                                  swtch0.setChildMask( options[2].mask );*/
    private class NameChildMask
              public String name;
              public int child;
              public BitSet mask;
              public NameChildMask( String n, int c, int m )
                   name = n;
                   child = c;
                   mask = new BitSet(3);
                   if( (m&1) != 0 )     mask.set( 0 );
                   if( (m&2) != 0 )     mask.set( 1 );
                   if( (m&4) != 0 )     mask.set( 2 );
    private NameChildMask[] options =
              //new NameChildMask( "CHILD_ALL", Switch.CHILD_ALL,     0 ),
              //new NameChildMask( "CHILD_NONE", Switch.CHILD_NONE,     0 ),
              new NameChildMask( "Child 0",     0,               0 ),
              new NameChildMask( "Child 1",     1,               0 ),
              new NameChildMask( "Child 2",     2,               0 )};

    ORA-01722:     invalid number
    Cause:     The attempted conversion of a character string to a number failed because the character string was not a valid numeric literal. Only numeric fields or character fields containing numeric data may be used in arithmetic functions or expressions. Only numeric fields may be added to or subtracted from dates.
    Action:     Check the character strings in the function or expression. Check that they contain only numbers, a sign, a decimal point, and the character "E" or "e" and retry the operation.
    Cheers,
    Prasanna

  • Hi friends i need ur help (urgent)

    Hi friends,
    i have one requirment  any one can please suggest me how can it do
    i have one <b>planing hirarachy</b> like
    in one internal table or table i have the data like
    internal table (itab)
    <b>fields are                    a                     b                   c             
    data                        bike                herohonda       splender
                                  bike                herohonda        pulsar     
                                 scooty                  aaaa             xxxxx
                                  scooty                  bbbbb           yyyy</b>
    in the selection screen when the user selects the <b>a filed as</b>
      <b> bike</b>    he has to get <b>herohonda</b>  in <b>b</b> field  only    .in the third field he gets <b>splender and pulsar</b> only <b>not xxxxx and yyyy</b>    
    if user selects <b>scooty</b> in <b>a</b> filed the possible entries in <b>b</b> filed
    shoul be <b>aaaa and bbbbb</b> if he selects <b>aaaa</b> in the <b>b</b> field the possible entrie in c field should be xxxxx only.
    if he selects <b>bbbbb</b> in <b>b field</b> the possible entrie in c field should be <b>yyyy</b> only.
    Please send me how to do it
    Regards,
    balu.

    Hello Balu,
    See if this program helps, it is roughly based on the same concept
    REPORT  ztest987 MESSAGE-ID zpp .
    TYPE-POOLS: vrm, slis.
    DATA: lifnr LIKE lfa1-lifnr.
    DATA: v_repid LIKE sy-repid .
    DATA: plnt(10) TYPE n, flg TYPE i.
    DATA: name TYPE vrm_id,
    mrp(55) TYPE c,
    list TYPE vrm_values,
    var1(10) TYPE c,
    var2(30) TYPE c,
    value LIKE LINE OF list.
    DATA:BEGIN OF itabt024d OCCURS 0,
    dispo LIKE t024d-dispo,
    dsnam LIKE t024d-dsnam,
    conc(55) TYPE n,
    END OF itabt024d.
    DATA:BEGIN OF strumarc,
    matnr LIKE marc-matnr,
    maktx LIKE makt-maktx,
    END OF strumarc.
    DATA: i_fieldcat TYPE slis_t_fieldcat_alv WITH HEADER LINE.
    DATA: itabmarc LIKE strumarc OCCURS 0 WITH HEADER LINE.
    DATA:itabt001w LIKE TABLE OF t001w WITH HEADER LINE.
    RANGES: r_werks FOR t001w-werks,
    r_mrpdesc FOR itabt024d-dispo .
    r_werks-option = 'EQ'.
    r_werks-sign = 'I'.
    r_mrpdesc-option = 'EQ'.
    r_mrpdesc-sign = 'I'.
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
    PARAMETERS: plant LIKE r_werks AS LISTBOX VISIBLE LENGTH 10
    USER-COMMAND
    c1 MODIF ID pln.
    PARAMETERS: vendor LIKE r_mrpdesc AS LISTBOX VISIBLE LENGTH 50 MODIF ID
    det USER-COMMAND c1.
    SELECTION-SCREEN END OF BLOCK b1.
    INITIALIZATION.
      flg = 1.
      IF flg = 1.
        CLEAR vendor.
        CLEAR plant.
      ENDIF.
    AT SELECTION-SCREEN.
    AT SELECTION-SCREEN OUTPUT.
      PERFORM fetch_plant.
    AT SELECTION-SCREEN ON plant.
      PERFORM fetch_mrp.
    AT SELECTION-SCREEN ON vendor.
      PERFORM materials.
    START-OF-SELECTION.
      REFRESH i_fieldcat.
      i_fieldcat-col_pos = 1 .
      i_fieldcat-fieldname = 'MATNR'.
      i_fieldcat-seltext_m = 'Part No'.
      i_fieldcat-outputlen = 30.
      i_fieldcat-fix_column = 'X'.
      APPEND i_fieldcat.
      CLEAR i_fieldcat.
      i_fieldcat-col_pos = 2 .
      i_fieldcat-fieldname = 'MAKTX'.
      i_fieldcat-seltext_m = 'Part Description'.
      i_fieldcat-outputlen = 30.
      i_fieldcat-fix_column = 'X'.
      APPEND i_fieldcat .
      CLEAR i_fieldcat.
      v_repid = sy-repid.
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
          i_callback_program = v_repid
          i_grid_title       = 'Parts Under Selected MRP Controller'
          it_fieldcat        = i_fieldcat[]
        TABLES
          t_outtab           = itabmarc.
    *&      Form  ASSIGN_LISTBOX_VALUES
    *       text
    FORM assign_listbox_values .
      REFRESH list.
      IF flg = 1.
        LOOP AT r_werks.
          name = 'PLANT'.
          value-key = r_werks-low.
          value-text = r_werks-low.
          APPEND value TO list.
        ENDLOOP.
        CALL FUNCTION 'VRM_SET_VALUES'
          EXPORTING
            id     = name
            values = list.
        CLEAR plant.
      ELSEIF flg = 0.
        CLEAR itabt024d-conc.
        LOOP AT itabt024d.
          name = 'VENDOR'.
          value-key = itabt024d-dispo.
          value-text = itabt024d-conc.
          APPEND value TO list.
        ENDLOOP.
        CALL FUNCTION 'VRM_SET_VALUES'
          EXPORTING
            id     = name
            values = list.
      ENDIF.
    ENDFORM. " ASSIGN_LISTBOX_VALUES
    *&      Form  GET_LIST_DATA
    *       text
    FORM get_list_data .
      REFRESH list.
      IF flg = 1.
        SELECT DISTINCT werks FROM t001w INTO r_werks-low.
    *    WHERE kunnr EQ 'TSL' OR kunnr EQ '0000050001'.
          APPEND r_werks.
        ENDSELECT.
        CLEAR r_werks.
        SORT r_werks ASCENDING.
        DELETE ADJACENT DUPLICATES FROM r_werks.
        CLEAR r_werks.
      ELSEIF flg = 0.
        CLEAR itabt024d.
        CLEAR itabt024d-conc.
        SELECT dispo dsnam INTO TABLE itabt024d FROM t024d
        WHERE werks EQ plant.
        CLEAR itabt024d.
        SORT itabt024d ASCENDING.
        DELETE ADJACENT DUPLICATES FROM itabt024d.
        CLEAR itabt024d.
        LOOP AT itabt024d.
          CONCATENATE itabt024d-dispo ' - ' itabt024d-dsnam INTO itabt024d-conc.
          MODIFY itabt024d.
        ENDLOOP.
      ENDIF.
    ENDFORM. " get_list_data
    *&      Form  FETCH_PLANT
    *       text
    FORM fetch_plant .
      REFRESH list.
      IF flg = 1.
        LOOP AT SCREEN.
          IF screen-group1 = 'DET'.
            screen-input = '0'.
            MODIFY SCREEN.
          ENDIF.
        ENDLOOP.
        PERFORM get_list_data.
        PERFORM assign_listbox_values.
        flg = 0.
      ENDIF.
    ENDFORM. " fetch_plant
    *&      Form  FETCH_MRP
    *       text
    FORM fetch_mrp .
      REFRESH list.
      CLEAR vendor.
      IF flg = 0 .
        CONDENSE plant.
        IF plant NE ' '.
          LOOP AT SCREEN.
            IF screen-group1 = 'DET'.
              screen-active = '0'.
              MODIFY SCREEN.
            ENDIF.
          ENDLOOP.
          PERFORM get_list_data.
          PERFORM assign_listbox_values.
        ENDIF.
        flg = 2.
      ENDIF.
    ENDFORM. " fetch_mrp
    *&      Form  MATERIALS
    *       text
    FORM materials .
      IF flg = 2.
        IF vendor NE ' '.
          CONDENSE vendor.
          SELECT matnr INTO CORRESPONDING FIELDS OF
          TABLE itabmarc FROM marc WHERE werks EQ plant
          AND dispo EQ vendor.
          CLEAR itabmarc.
          LOOP AT itabmarc.
            SELECT maktx FROM makt INTO (itabmarc-maktx) WHERE matnr =
            itabmarc-matnr.
              MODIFY itabmarc.
            ENDSELECT.
          ENDLOOP.
          CLEAR itabmarc.
        ENDIF.
      ENDIF.
    ENDFORM. " materials

  • Recovery Softwares needed, please help urgent.

    By mistake a user from the company format his secondary HDD (Data HDD) which content all his data.
    Please can anyone help me to restore this HDD.
    He formats it using Don't eras data mode, so the data is still on the HDD but unreachable.
    Please any ideas or hint.
    Thanks in advance

    Hi,
    my first (and maybe only choice) would be DiskWarrior http://www.alsoft.com/DiskWarrior/index.html
    Or Drive Genius 2 http://www.prosofteng.com/products/drive_genius.php
    Both should help with that problem.
    Good Luck
    Stefan

  • Letter/report generation...morgalr, i need your help!!

    may i know the details or some sample source code of how to generate the html and import it to MS Word...i need your help urgently...may i have your email to contact u?.....please help, it is urgent!!!

    You need not use an applet to write an HTML file, any application file will do fine, actually applications may be prefered due to system security and file creation. Basically the html files are just text files using HTML. Look at any book on HTML and you will be able to get the style and form down along with the syntax.
    As for calling MS word, do a search on the web for a product called JPrint. It is done by a company called Neva and they also have a product called "coroutine". It is coroutine that you want. Coroutine is a native level interface for Java to Comm. The docs that come with coroutine should be saficient to get you going on the project.

Maybe you are looking for

  • Test of forum edit problem by a Moderator

    Adding some test text in a quetion. Possibly forum quotes feature has damaged editing feature. ''edited by the-edmeister - 01-02-2015 17:47 CST'' blah blah blah Also are we shooting ourselves in the foot, giving a warning and effectively blocking our

  • EJB 2.0 & auto-increment

    How to implement EJB 2.0 Entity bean for auto increment DB filed, let's say I have table person(ID, name), ID is auto-increment PK, I have ejbCreate(ID, name), if I send null for ID that won't work (exception), if I have ejbCreate(name) that won't wo

  • Selected row style on load

    I have a style for selected rows. When the page loads the default row is 0 (correct?), I would like this row to use the selected style - which it will do once it is clicked - but not when the page first loads. The current page: squarehead.myvnc.com/U

  • Adding a label

    how can i swap a label on a jpanel with another? i am able to successfully remove the label component from the jpanel, but attempting to add another afterwards does not do anything, even with repaint(); my labels have ImageIcons. thanks in advance

  • Markzware's Quark-to-InDesign Plugin

    I saw someone mention the Markzware plugin on here a while back. Glad I saw that post! We just got new computers at work, and no one could find the QuarkXpress installation CDs to install it on my new computer. I don't design in Quark any more, but I