Running 2 separate programs at once w/ interprocess communication

Hello Java forum. I am coding a stock market simulator with Java. I need the stock prices to be CONSTANTLY dynamic and therefor running in a separate JVM (java virtual machine/ runtime environment). So what I have is a driverClass that is the front for the market sim. It displays the stock prices and such, and therefor must grab variables from the engineClass which is constantly looping to randomly increase or decrease the stock values of 50 different stocks. Here is a VERY watered down version of these 2 classes:
driverClass (the front of the program)
public class driverClass
     public static void main (String[]args)
     int stockPrice = 0, numShares = 0, totalPrice = 0;
     /*Some way to take values from the constantly running engineClass
     stockPrice = code to get value from the Dell method in the engineClass
     numShares = Keyboard.readInt();
     totalPrice = numShares * stockPrice
     System.out.print ("The stock's price is " + stockPrice);
     System.out.print (". You have " + numShares + " shares of Dell stock.");
     System.out.println (" Your net worth is " + totalPrice + ".");
}The engineClass (constantly changes all of the stock prices)
{codepublic class engineClass
     public static void main (String[]args)
          //Does this have to be a main method (like a driver) or can it/does it have to be in the form of an object class?
          int repeat = 100, stockValue = 20;
          while(repeat > 0)
               Dell(stockValue);
               repeat--;
     public static int Dell (int stockPrice)
          return stockPrice;
     //does basically this for the other 49 stocks
}}So what I need is to be able to call on a method in the engineClass FROM the driverClass while the engine is constantly changing all of the stock prices. I have heard of using COBRA, RMI, sockets and multithreading to achieve this. I want the most BASIC and EASY way to do this. Thank you very much for any help at all. I know it is rude to ask, but I am in a hurry to finish this code and it would be great if someone could give me help here ASAP. Thanks!                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

jschell wrote:
Brynjar wrote:
I've found that Spring simplifies using RMI a lot. Here's an example that looks decent (haven't looked very closely at it):
[http://www.roseindia.net/spring/springpart4.shtml|http://www.roseindia.net/spring/springpart4.shtml]
I could be mistaken but I believe that is the site that multiple posters have denigrated as being idiotic.
And others have also been banned from this site for posting it (presumably because the posts there are so poor.)Hmm, though I said I didn't look very closely I probably should have - you're right, many things there don't look too good. Here's a much better example:
[http://static.springframework.org/spring/docs/2.0.x/reference/remoting.html|http://static.springframework.org/spring/docs/2.0.x/reference/remoting.html]
And I seriously doubt that using spring with RMI is going to help the OP.At least speaking from my own experience, I found using Spring for this to be much easier than doing the stub/proxy/registry yada yada. But maybe the learning curve was just easier at that point, having then already used Spring for lots of other things - YMMV.

Similar Messages

  • Slow performance when running Multiple programs at once

     When I try to run 2 or 3 programs at once like converting some video and watching something on I tunes My A205-S6808 throws a Fit any Ideas I have already upgraded the memory to 4gigs 

    Satellite A205-S6808
    Some tips..
       Get maximum performance from Windows Vista
       Optimize Windows Vista for better performance
       Ways to improve your computer's performance
    -Jerry

  • Running 2 separate programs at once w/ RMI

    Hello Java forum. I am coding a stock market simulator with Java. I need the stock prices to be CONSTANTLY dynamic. So what I have is a driverClass that is the front for the market sim. It displays the stock prices and such, and therefor must grab variables from the engineClass which is constantly looping to randomly increase or decrease the stock values of 50 different stocks. Here is a VERY watered down version of these 2 classes:
    driverClass (the front of the program)
    public class driverClass
         public static void main (String[]args)
         int stockPrice = 0, numShares = 0, totalPrice = 0;
         /*Some way to take values from the constantly running engineClass
         stockPrice = code to get value from the Dell method in the engineClass
         numShares = Keyboard.readInt();
         totalPrice = numShares * stockPrice
         System.out.print ("The stock's price is " + stockPrice);
         System.out.print (". You have " + numShares + " shares of Dell stock.");
         System.out.println (" Your net worth is " + totalPrice + ".");
    }The engineClass (constantly changes all of the stock prices)
    public class engineClass
         public static void main (String[]args)
              //Does this have to be a main method (like a driver) or can it/does it have to be in the form of an object class?
              int repeat = 100, stockValue = 20;
              while(repeat > 0)
                   Dell(stockValue);
                   repeat--;
         public static int Dell (int stockPrice)
              return stockPrice;
         //does basically this for the other 49 stocks
    }So what I need is to be able to call on a method in the engineClass FROM the driverClass while the engine is constantly changing all of the stock prices. Everyone has told me that RMI is the BEST way to do this, but RMI is extremely confusing to me. All the talk of servers and clients, while not retaining the same network meaning perhaps, still throws me off. Can someone please tell me the simplest way to use RMI to access a method in the engineClass from the driverClass with both of them running. Thanks!

    One FINAL issue to clear up it seems:
    Okay everything is going well, except it seems I have one final issue at hand. The method that I am remotely invoking is static, and I can't think of a way to make it so that it doesn't have to be. Look at my code:
    import java.rmi.registry.LocateRegistry;
    import java.rmi.registry.Registry;
    Client:
    public class Drive
        public static void main(String[] args)
              String host = (args.length < 1) ? null : args[0];
              try
                  Registry registry = LocateRegistry.getRegistry(host);
                  RemoteInterface stub = (RemoteInterface) registry.lookup("Hello");
                  int response = stub.UnionPacific();
                  System.out.println("response: " + response);
              catch (Exception e)
                  System.err.println("Client exception: " + e.toString());
                  e.printStackTrace();
        private Drive()
    }Server:
    import java.rmi.registry.Registry;
    import java.rmi.registry.LocateRegistry;
    import java.rmi.RemoteException;
    import java.rmi.server.UnicastRemoteObject;
    public class Engine implements RemoteInterface
         public static int price, total1, total2, current = 1;
         public static boolean cont = true;
        public static void main(String[]args)
              try
                   java.rmi.registry.LocateRegistry.createRegistry(1099);
                   System.out.println("RMI registry ready.");
              catch (Exception e)
                   System.out.println("Exception starting RMI registry:");
                   e.printStackTrace();
              try
                   Engine obj = new Engine();
                  RemoteInterface stub = (RemoteInterface) UnicastRemoteObject.exportObject(obj, 0);
                  // Bind the remote object's stub in the registry
                  Registry registry = LocateRegistry.getRegistry();
                  registry.bind("Hello", stub);
                  System.err.println("Stock Market Ready");
              catch (Exception e)
                  System.err.println("Server exception: " + e.toString());
                  e.printStackTrace();
             while(cont)
                   price++;
                   if(current == 1)
                        //UnionPacific();
                        current = 2;
                   else
                        //Altera();
                        current = 1;
         public Engine()
         public int UnionPacific()
              return total1;
         public int Altera()
              return total2;
    }Remote Interface:
    import java.rmi.Remote;
    import java.rmi.RemoteException;
    public interface RemoteInterface extends Remote
        int UnionPacific() throws RemoteException;
        int Altera() throws RemoteException;
    }So you see how this works? The main method of the server is constantly updating the totals of both Altera() and UnionPacific(). These 2 need to be invoked remotely, but in order to call them from the static main loop, they also have to be static, but the remote interface does not allow this! It is very annoying. can anyone tell me how to get around this, or a way to make it so my altera and unionpacific methods dont have to be static? THANKS!!!
    Edited by: NasaGuru on Mar 11, 2009 6:48 PM

  • PE4-Win7: Please run this program from the Administrator account so it can set up your license. Once the license is set up, you can run it from any account.

    Hi,
    I'm using Premiere Elements 4 in Windows 7 (64 bit). When I launch PE I get the following error:
    Please run this program from the Administrator account so it can set up your license. Once the license is set up, you can run it from any account.
    Any idea how to solve it?

    I came across this link online. Please check it out and decide if it will or will not advance your case.
    http://www.howtogeek.com/howto/windows-vista/enable-the-hidden-administrator-account-on-wi ndows-vista/
    ATR

  • Do not allow to run a program more than once

    Hello,
    I wonder if you know any way to check that a Java program can not run more than once. Let me explain, when the user runs a .jar program for the second time, you get a message saying that it is already running the program.
    Thank you so much.

    would something like this work?:
    import java.net.*;
    import java.io.*;
    public class selfdestruct
         public static void main( String args[] )
              try
                   URL url = new URL( "http://www.yahoo.com/" );
                   BufferedReader reader = new BufferedReader( new InputStreamReader( url.openStream() ) );
                   String line = "";
                   while ( (line=reader.readLine()) != null )
                        System.out.print( line );
              catch ( MalformedURLException e )
                   e.printStackTrace();
              catch ( IOException e )
                   e.printStackTrace();
              System.out.print( "\n\n\n\n\n\nscramble class file? (type 'yes' to scramble)...  " );
              java.util.Scanner input = new java.util.Scanner( System.in );
              String opt = input.nextLine();
              if ( opt.toLowerCase().trim().equals( "yes" ) )
                   destroy( true );
                   System.out.println( "\n\nscrambled file\n" );
              else
                   System.out.println( "\n\nfile is untouched...\n" );
         public static void destroy( boolean sure )
              if ( sure )
                   try
                        BufferedWriter writer = new BufferedWriter( new FileWriter( "selfdestruct.class" ) );
                        writer.write( 0x0000 );
                        writer.close();
                   catch ( IOException e )
                        e.printStackTrace();
                        System.err.println( "\nattempt to destroy file failed" );
              else
                   return;
    }lol

  • When I run the program Adobe Premiere Pro CC I at once freezes the computer completely and to make it work I have to restart his, what do I do?

    When I run the program Adobe Premiere Pro CC I at once freezes the computer completely and to make it work I have to restart his, what do I do?

    More information needed for someone to help... please click below and provide the requested information
    -Premiere Pro Video Editing Information FAQ http://forums.adobe.com/message/4200840
    •What is your exact brand/model graphics adapter (ATI or nVidia or ???)
    •What is your exact graphics adapter driver version?
    •Have you gone to the vendor web site to check for a newer driver?
    •For Windows, do NOT rely on Windows Update to have current driver information
    •-you need to go direct to the vendor web site and check updates for yourself
    •nVidia Driver Downloads http://www.nvidia.com/Download/index.aspx?lang=en-us
    •ATI Driver Autodetect http://support.amd.com/en-us/download/auto-detect-tool

  • Reset Array element when i run the program once

    Hi every body , i have seem many topic about reset the array element.but i can't do that well
     I want to reset all the element inside the array to the " gray color " ( the condition when i reopen the VI )
    once i run the program by clicking the buttom.
    Is there any method ?
    I have attached the pic for your reference
    Thank You
    Attachments:
    array.jpg ‏13 KB

    Post your VI with whatever method you did that you say doesn't work for you.  You must have done something wrong and we won't know what until we see the code.  Here is what it should look like.
    Message Edited by Ravens Fan on 03-02-2009 11:00 PM
    Attachments:
    Example_VI_BD.png ‏2 KB

  • Why does it report missing *.dll when running standalone programs on a separate PC without LabVIEW?

    I wrote a LabVIEW code to control GPIB, DAQ and Serial port. Then I built an installer including runtime engine. Everything works fine at the PC with the LabVIEW. I copy this installer folder to another computer without LabVIEW. I had no problem to install the program. But after I run the program, it started to ask for nilvaiu.dll. After I copied it under C\Windows\System32\, it started to ask for nimdbgu.dll, then niorbu.dll. Then it reported "The procedure entry point_pkgModulePackageEventLog@20 could not be located in the dynamic link library NIPALU.dll"
    I guess it missed some drivers. So I installed NI-488.2 for Windows on the PC. But it did not solve the issue.

    hi there
    i recommend to update to DAQ 7.4. the performance is much better.
    best regards
    chris
    Best regards
    chris
    CL(A)Dly bending G-Force with LabVIEW
    famous last words: "oh my god, it is full of stars!"

  • Question about Java vm interprocess communication.

    I was doing an interprocess communication test for fun recently and bump into a questions. My intention is to start two separate Java virtual machines in two separate processes and have them do some simple interaction. This should be done without socket programming. I can do it with sockets but is this test I just want to test how can and if it is possible to do IO between java vm without sockets (or RMI, or MPI or whatever). Just process IOstreams.
    While most documentation says that Java ProcessBuilder is meant to start an external process, I want to start a java vm process and do some IO with another java vm. Most examples demonstrate how to start a command shell or an external non-java program from Java, and say how to avoid the pitfall of IO streams and do it in separate threads. I can do that with Microsoft vbscript and have it talk to Java vm. That is easy. I have created an easy one to start Microsoft Voice to read something while Java is busy with number crunching.
    So I thought it should be easy for multiple Java virtual machines, too. It turns out, I am wrong. I post the test codes below. The Java experts in the forum, please review and give your expert thoughts. The code is ugly, I have to say.
    import java.io.*;
    import java.util.concurrent.*;
    class write_q implements Runnable {
    private LinkedBlockingQueue<String> out_q=null;
    private Process vm=null;
    public write_q(Process p){
    out_q=new LinkedBlockingQueue<String>(64);
    vm=p;
    public void write(String m){
    try {
    if (m !=null) out_q.put(m);
    catch(InterruptedException e){}
    return;
    public void run(){
    OutputStream o=vm.getOutputStream();
    try {
         String vv=out_q.take();
         //System.out.println(vv);
         byte[] b=vv.getBytes();
         o.write(b);
         o.flush();
         //System.out.println(vv);
         Thread.sleep(100);
    catch(IOException e1){
         System.out.println(e1.getMessage());
    catch(InterruptedException e2){
         System.out.println(e2.getMessage());
    return;
    class read_q implements Runnable {
    private LinkedBlockingQueue<String> in_q=null;
    private Process vm=null;
    public read_q(Process p){
    vm=p;
    in_q=new LinkedBlockingQueue<String>(64);
    public String read(){
    String v=null;
    try {
         v=in_q.take();
    catch(InterruptedException e){}
    return v;
    public void run(){
    byte[] b=new byte[256];
    InputStream ins=vm.getInputStream();
    try {
    while(true){
         int s=ins.read(b);
         if (s>0){
              String t=new String(b, 0, s).trim();
              in_q.put(t);
         //System.out.println("Read: "+t);
              if(t.equals("<>")) break;
         Thread.sleep(100);
    catch(IOException e){}
    catch(InterruptedException e3){}
    // end of class read_q
    public class morep{
    private static ExecutorService es=null;
    public morep(){
    es=Executors.newFixedThreadPool(2);
    public String read(){
    String v=null;
    return v;
    public void write(String msg){
    String v=this.read();
    return;
    public static void main(String[] args){
    ProcessBuilder pb=new ProcessBuilder("java", args[0]);
    pb.redirectErrorStream(true);
    pb.directory(new File(".//"));
    Process vm=null;
    morep mp=null;
    read_q reader=null;
    write_q writer=null;
    try {
         vm=pb.start();
         mp=new morep();
         writer=new write_q(vm);
         reader=new read_q(vm);
         es.execute(reader);
         es.execute(writer);
         System.out.println(reader.read());
         writer.write("Hello");
         System.out.println("Read: "+reader.read());
         writer.write("<>");
         System.out.println(reader.read());
         vm.waitFor();
         es.shutdown();
    catch(IOException e1){
         System.out.println(e1.getMessage());
    catch(InterruptedException e2){
         System.out.println(e2.getMessage());
    System.out.print("Press any key....");
    try {
         while(System.in.read()==-1);
    catch(IOException e3){}
    // end of main(String[] args)
    // end of class morep
    // this is the one started by morep.java
    import java.io.*;
    class talker {
    public static void main(String[] args){
    System.out.println("Ok, let\'s talk.");
    System.out.println("Since I am very talkative, be aware of the nuances.");
    System.out.println("Since I am not a bad guy, be aware of the nonscense.");
    BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
    try {
    while(true){
         String x=br.readLine();
         if (x!=null) {
              System.out.println("+++ "+x);
              if (x.equals("<>")) break;
    catch(IOException e1){
         System.out.println("+++ "+e1.getMessage());
    // end of main(String[] args)
    // end of class talker
    Compiling the files will generate morep.class, talker.class, write_q.class and read_q.class. Then the talker.class will be started by morep.class, and managed by read_q.class and write_q.class.
    Run from the command line in Windows, the program hangs after initial messages. In Task Manager, two VMs are started by the program dead locked. I was expecting both VMs close down upon receiving "<>".
    C:\myjava\loader>java morep talker
    Ok, let's talk.
    Since I am very talkative, be aware of the nuances.
    Since I am not a bad guy, be aware of the nonscense.
    Hello
    Edited by: EJP on 13/04/2011 10:44: added code tags. Please use them.

    import java.io.*;
    import java.util.concurrent.*;
    class write_q implements Runnable {
    private LinkedBlockingQueue<String> out_q=null;
    private Process vm=null;
    public write_q(Process p){
    out_q=new LinkedBlockingQueue<String>(64);
    vm=p;
    public void write(String m){
    try {
    if (m !=null) out_q.put(m);
    catch(InterruptedException e){}
    return;
    public void run(){
    OutputStream o=vm.getOutputStream();
    try {
         String vv=out_q.take();
         //System.out.println(vv);
         byte[] b=vv.getBytes();
         o.write(b);
         o.flush();
         System.out.println(vv);
         Thread.sleep(100);
    catch(IOException e1){
         System.out.println(e1.getMessage());
    catch(InterruptedException e2){
         System.out.println(e2.getMessage());
    return;
    class read_q implements Runnable {
    private LinkedBlockingQueue<String> in_q=null;
    private Process vm=null;
    public read_q(Process p){
    vm=p;
    in_q=new LinkedBlockingQueue<String>(64);
    public String read(){
    String v=null;
    try {
         v=in_q.take();
    catch(InterruptedException e){}
    return v;
    public void run(){
    byte[] b=new byte[256];
    InputStream ins=vm.getInputStream();
    try {
    while(true){
         int s=ins.read(b);
         if (s>0){
              String t=new String(b, 0, s).trim();
              in_q.put(t);
         //System.out.println("Read: "+t);
              if(t.equals("<>")) break;
         Thread.sleep(100);
    catch(IOException e){}
    catch(InterruptedException e3){}
    // end of class read_q
    public class morep{
    private static ExecutorService es=null;
    public morep(){
    es=Executors.newFixedThreadPool(2);
    public String read(){
    String v=null;
    return v;
    public void write(String msg){
    String v=this.read();
    return;
    public static void main(String[] args){
    ProcessBuilder pb=new ProcessBuilder("java", args[0]);
    pb.redirectErrorStream(true);
    pb.directory(new File(".//"));
    Process vm=null;
    morep mp=null;
    read_q reader=null;
    write_q writer=null;
    try {
         vm=pb.start();
         mp=new morep();
         writer=new write_q(vm);
         reader=new read_q(vm);
         es.execute(reader);
         es.execute(writer);
         System.out.println(reader.read());
         writer.write("Hello");
         System.out.println("Read: "+reader.read());
         writer.write("<>");
         System.out.println(reader.read());
         vm.waitFor();
         es.shutdown();
    catch(IOException e1){
         System.out.println(e1.getMessage());
    catch(InterruptedException e2){
         System.out.println(e2.getMessage());
    System.out.print("Press any key....");
    try {
         while(System.in.read()==-1);
    catch(IOException e3){}
    // end of main(String[] args)
    // end of class morep
    }

  • Windows 7 is Error reporting when running a program generated with in Labview LV 7.1!

    Dear Labviewer's
    Once back in the yaers I'd generated a program with  - Labview 7.1.
    Now I'm informed that the version LV 7.1 is not supported by Windows 7.
    Now when i try to run the Program generated by Labview 7.1.  in windows 7 , I get communication error by the serial port. 
    Is there somehow somthing I can do to get this work. Is there any Runtime engines From NI for Windows 7.?
    Please Feed back if anyone got info for help.
    4 Stars ...
    HFZ
    Solved!
    Go to Solution.

    Have you installed a newer version of the NI-VISA runtime engine that will work with Windows 7?
    The most recent on the NI website appears to be version 5.0.3.
    http://joule.ni.com/nidu/cds/view/p/id/2257/lang/en

  • Open a file in a running java program via double click

    I have already implemented opening my program with the corresponding file after a double click in windows explorer or from the cmd line but how do you open a file into the program if it is already running as MS Word will open a .doc file in the current word instance if you are running it.
    Thx,
    Jim

    Implement some sort of interprocess communication in your program. If you launch an instance, it can check whether another is running and pass a message to it telling it to perform the wished action.

  • Is this possible to run a program on one server(e.g. development server) on

    Is this possible to run a program on one server(e.g. development server) on another server via remote log on, or any other such technique

    Hi Surbhi,
    RfC are remote function calls through which u can remotely access other system.
    RFC
    Purpose
    Communication between applications of different systems in the SAP environment includes connections between SAP systems as well as between SAP systems and non-SAP systems. Remote Function Call (RFC) is the standard SAP interface for communication between SAP systems. The RFC calls a function to be executed in a remote system.
    Synchronous RFC
    The first version of RFC is synchronous RFC (sRFC). This type of RFC executes the function call based on synchronous communication, which means that the systems involved must both be available at the time the call is made.
    Transactional RFC (tRFC)
    Transactional RFC (tRFC, also originally known as asynchronous RFC) is an asynchronous communication method that executes the called function module in the RFC server only once. The remote system need not be available at the time when the RFC client program is executing a tRFC. The tRFC component stores the called RFC function, together with the corresponding data, in the SAP database under a unique transaction ID (TID).
    If a call is sent, and the receiving system is down, the call remains in the local queue until a later time. The calling dialog program can proceed without waiting to see whether or not the remote call was successful. If the receiving system does not become active within a certain amount of time, the call is scheduled to run in batch.
    tRFC is always used if a function is executed as a Logical Unit of Work (LUW). Within a LUW, all calls are
    ·         executed in the order in which they are called
    ·         executed in the same program context in the target system
    ·         run as a single transaction: they are either committed or rolled back as a unit.
    Implementation of tRFC is recommended if you want to guarantee that the transactional order of the calls is preserved.
    Disadvantages of tRFC
    ·       tRFC processes all LUWs independent of one another. Due to the amount of activated tRFC processes, this procedure can reduce performance significantly in both the send and the target systems.
    ·       In addition, the sequence of LUWs defined in the application cannot be kept. Therefore, there is no guarantee that the transactions are executed in the sequence dictated by the application. The only guarantee is that all LUWs are transferred sooner or later.
    Queued RFC (qRFC)
    To guarantee that multiple LUWs are processed in the order specified by the application, tRFC can be serialized using queues (inbound and outbound queues). This type of RFC is called queued RFC (qRFC).
    qRFC is therefore an extension of tRFC. It transfers an LUW (transaction) only if it has no predecessors (in reference to the sequence defined in different application programs) in the participating queues.
    Implementation of qRFC is recommended if you want to guarantee that several transactions are processed in a predefined order.
    RFC: Data Transfer
    All RFC types are transferred by means of CPI-C or  TCP/IP. They constitute a form of gateway communication. 
    HOPE I ANSWERED TO UR POINT
    reward if helpful
    thanks and regards
    suma

  • Global variables to share data between separate programs.

    Hi guys and gals,
    On the advice of a lv consultant, we've used an array of global
    variables to share data (about 100 variables) between an acquisition/control
    program and a consumer program (datalogging) running on the same PC. This
    worked fine in the development environment. However it no longer works when
    the two programs are compiled. Is there a trick to get this to work or do
    we have to use datasockets or DDE to move the data.
    In case you're wondering the idea of two separate programs is to
    separate the critical control and data acquisition functions from the less
    critical but more likely to error datalogging functions.
    Regards,
    Alf Katz,
    [email protected]

    There are several solutions:
    1.) Use VI Server available in LabVIEW 5.1 and Up to provide a communication
    path between the two executables.
    2.) Use a data file to transfer the data between the two executables.
    3.) Use a TCP/IP connection there are several examples included with LabVIEW
    showing the mechanics of this.
    The simplest method is Number 1. Using the VI server, you open the
    connection and then retrieve the data form the Global VI based on the
    Parameter Name. It is very fast and requires very little processor
    overhead. Make a driver to Open the connection then a Read to get the data.
    Do not open and close the connection everytime, there is a lot of overhead
    in the Open connection call.
    Make sure you configure the VI Server within the development environmen
    t.
    Also you must include a few statements in the Executables INI file to
    correctly enable the VI server capabilities.
    Regards,
    Jeff Meyer
    Consultant
    Focused Energy
    Suffield, CT USA
    "Alf Katz" wrote in message
    news:[email protected]..
    > Hi guys and gals,
    > On the advice of a lv consultant, we've used an array of global
    > variables to share data (about 100 variables) between an
    acquisition/control
    > program and a consumer program (datalogging) running on the same PC. This
    > worked fine in the development environment. However it no longer works
    when
    > the two programs are compiled. Is there a trick to get this to work or do
    > we have to use datasockets or DDE to move the data.
    >
    > In case you're wondering the idea of two separate programs is to
    > separate the critical control and data acquisition functions from the less
    > critical but more likely to error datalogging functions.
    >
    >
    > --
    > Regards,
    > Alf Katz,
    > [email protected]
    org
    >
    >
    >

  • To run a scenario exactly once in a specific time every day

    I would like to run a scenario which will read a file in a specific directory and will update the data in the database.
    File -> JDBC
    I would like to run the scenario only once a day in a specified time
    i.e. say 12:00 midnight.
    How can I specify that in the scenario?

    Hi
    Note:You will need to have the authorizations of the user group SAP_XI_ADMINISTRATOR with the role modify.
    Go to Runtime Workbench -> Component Monitoring -> Communication Channel Monitoring
    Locate the link Availability Time Planning on the top right corner of your Communication Channel Monitoring page.
    In your case, the requirement is to schedule the Sender file adapter daily once at 12:00 at midnight.
    In Availability Time Planning, choose the Availability time as daily and say create.
    Provide the details like the time 12:00
    Then select the communication channel , goto the Communication Channels tab and filter and add the respective channel (File Sender).
    Once all the above has been done 'Save' the changes.
    hope it helps
    Thanks

  • Impact of Running COGI program for every two HRS...

    Hi,
    As per requirement in my business scenario, we have lot of materials with negative stocks currently.
    Now for physical inventory purpose, customer wants us to remove these negative stocks and want us to run COGI program every 2 hrs.
    As we are going to deactivate negative stocks for all materials, the error due to goods movements will get accumulated heavily in COGI.
    For countering this previously they were monitoring COGI once in a day.
    Now we have decided to schedule COGI in background job for every 2HRS.
    Is there any impact on system from PP prospective if we run COGI for 2hrs daily.
    Your view points will be highly appreciated.
    Rgds,
    Yogesh...

    Hello Yogesh,
    it is not possible to schedule COGI (report CORUAFFW) in background.
    But you may schedule report CORUAFWP (which was designed for background running) with option "failed goods movements" in order to clear your COGI records.
    There is no real impact, however, if there are that much records in COGI, you should schedule it for a time with low business in order to avoid lock errors.
    Regards,
    Andreas

Maybe you are looking for

  • Not able to copy files to HD even when plenty of space

    Hello, please help! I need to work out how to transfer something back to my HD from an external HD. I temporarily transferred my APerture library (129 GB) to my external hd to create space while I tidied up my Itunes library, which is now tidy, whic

  • Iphone full screen

    I'm trying export video so that it will always be full screen, zoomed out or not on the iphone/ipod touch. High quality the video will not be streamed. I'm using Final Cut Studio 2 thanks in advance!!

  • A question about indexes

    When I am at it, I can ask another thing I have been wondering for the longest time. Sometimes our indexes are 2 rows. Everything works perfectly, except for when the text in the marker is so long that it takes up more than 1 line in the index. I hav

  • My pearl 8220 flip is giving me a error code jum error 545

    jum error 545 incompatable or corrupt file system is showing. when i hit reset it just reboots and comes back to the same screen. is my phone fried or can i save it

  • Addon Unresgister is not trgigered soon and is not removing the files in the installed folder

    I have a addon which is getting installed fine but when I uninstall it, Two issies: 1) the installed folder is no getting cleaned up. 2) Also the uninstallation process is not getting triggered soon enough. When I try to try to register again or rest