How to update the screen in realtime?

Hey,
i am realy new in Indesign scripting
i want to do a simple client script… the script should receive data and write it to a textbox (or do sth else with it).
Everything works fine the only problem is: I dont know how to make this in realtime… for example every 10 seconds data comes from the server and should be directly displayed in the Indesign file.
I need sothing like update the screen or flush the display…
Thank you!
All the best
Code:
myFrame = app.activeDocument.textFrames.add ();
myFrame.geometricBounds = [30,30,200,200];
reply = "";
conn = new Socket;
while(conn.open("localhost:12345")) {
reply = conn.readln()
$.write(reply)
myFrame.contents = reply;
//update the frame…

Hey thank you, it works but it is too slow,
i try something like a remote control for indesign i am sending values to indesign to - for example- move a frame... rotate etc..
this works more or less:
myFrame = app.activeDocument.textFrames.add ();
myFrame.geometricBounds = [30,30,200,200];
for(;;)
for(var i=0; i<100; i++){
$.sleep(220)
myFrame.move ([i, 16])
myFrame.contents = "    "+i
myFrame.recompose()
but this is too slow, what can i do? i can see all incoming values printed to the console but there is no fluent movement. but i realy need this, any ideas?
myFrame = app.activeDocument.textFrames.add ();
myFrame.geometricBounds = [30,30,200,200];
reply = "";
conn = new Socket;
while(conn.open("localhost:12345")) {
reply = conn.readln()
$.write(reply+".")
myFrame.move ([reply, 50])
myFrame.contents = reply
myFrame.recompose()
thank you !!

Similar Messages

  • How to update the ztable using screen.

    hi experts,
    i have one ztable with 8 fields
    and i created one screen with 8 fields
    how to update the ztable using this screen menas when i press the some push button in my screen the table should update.
    Devi

    hi
    check the link shown below
    Coding & screen shots of how to update a database table from screen(Module poool)
    http://www.scribd.com/doc/15628693/moduleprog090311165111phpapp011
    in the attachment u will find
    data  : begin of i_ysrtmm occurs 0,
            sno type ysrtmm-sno,
            sname type ysrtmm-sname,
            scity type ysrtmm-scity,
            sedu type ysrtmm-sedu,
            spercent type ysrtmm-spercent,
            select(1),
            end of i_ysrtmm.
    in the SE51 click on layout & in that menu goto - secwindow- enter the internal table i_ysrtmm
    and click on get from program.u will get all the fields of the internal table select all of them except
    SELECT  field  and then drag and drop on table control . double click on the table control u see the attributes screen there in the w/colselect enter i_ysrtmm-select for tab selection of table control.
    Regards

  • Ever since I updated my OS, the screen on my Mac will automatically become huge if I keep my mouse on the screen. I can't figure out how to return the screen to a normal size. Any help?

    Ever since I updated my OS, the screen on my Mac will automatically become huge if I keep my mouse on the screen. I can't figure out how to return the screen to a normal size. Any help?

    Hold down the 'ctrl' key and scroll backwards on the mouse.
    Then go to System Preferences > Universal Access > Seeing. Turn off the Zoom feature.
    Similarly in Sys Pref > Mouse uncheck the box for 'Zoom using scroll wheel…'
    If it still occurs after that there may be a corrupt .plist file.

  • How to update the table value in the valuechange event?

    I have an input field in the datatable with the valueChangeListener
    <rich:dataTable id="cart" value="#{cart.cartList}" var="item">
    <h:inputText value="#{item.cost}" id="qty" valueChangeListener="#{items.updateCost}" onchange="submit()">
    <h:outputText value="#{item.errorMsg}"> </h:outputText>
    in the backing bean
         Item item = (Item) model.getRowData();
    // do some update, if the cost too larger, change to max_cost
         item.setCost(max_cost);
         item.setErrorMsg("Error Msg");
    After calling the valuechange method, the screen output doesn't update the cost.
    How to update the table value in the valuechange event?

    As you're misusing the valueChangeListener to set another input field, you need to skip the update model values phase. Otherwise the value set in the valueChangeListener will be overridden by the submitted value. You can do this by calling the FacesContext#renderResponse() inside the valueChangeListener method. This will shift the current phase immediately to the render response phase, hereby skipping the update model values and invoke application phases.

  • When i go to the app store to update the one app that needs to be updated, the screen is blank.  It used to list all the apps that need updating and have a button called update all.  Now nothing.  Just a blank screen.

    when i go to the app store to update the one app that needs to be updated, the screen is blank.  It used to list all the apps that need updating and have a button called update all.  Now nothing.  Just a blank screen.  How can I fix this?

    There's been a problem with this all day.  Seems to be a server problem  -  wait a day and try again, or use itunes on the computer to update, that works.

  • No major shortcomings keyboard arrow key. even if the text part of the message you clicked the arrow keys to update the screen would be great. with an update on my idea, and so it would be more useful

    no major shortcomings keyboard arrow key. even if the text part of the message you clicked the arrow keys to update the screen would be great. with an update on my idea, and so it would be more useful

    greghcrash wrote:
    It Would be great to have keys on the onscreen keyboard.
    Such as a computer keyboard.
    With BACKSPACE, TAB WITH SETTINGS, DELETE, TYPE OF TYPE, BOLD TYPE, UNDERLINE ETC....
    I HAVE A KEYBOARD COVER AND IF I NEED TO USE CERTAIN KEYS I HAVE TO SWITCH TO MY KEYBOARD CASE AND THAT IS VERY INCONVENIENT.
    IT IS ALSO A TIME WASTER.
    When you installed iOS 8 did you read about the new features? Applications can create custom keyboards…
    http://www.imore.com/custom-keyboards-ios-8-explained
    You need to look for an app that has a custom keyboard with the features you require, I suggest you find one without CAPSLOCK
    greghcrash wrote:
    IT IS ALSO AGGRAVATING WHEN TYPING AND IT AUTOMATICALLY CHANGES THE WORDS THAT YOU WANT TO USE.
    THANK YOU FOR YOUR TIME
    Again you need to look at how to manage the device - these settings can be turned off already & you can edit the 'suggestions' too.
    Settings > General > Keyboards > turn Auto-Correction Off.
    Sadly you cannot disable autocorrect temporarily, so it's all or nothing.

  • How to mirror the screen from one ipad2 to another ipad2?

    How to mirror the screen from one ipad2 to another ipad2?
    When writing in f.ex. Pages on one iPad i wish to see it in realtime on the other ipad.
    How is that done???

    That functionality is not built into the iPad, so you'd need a third-party app of some sort. I'm not aware of any app that allows mirroring from one iPad to another iPad, but perhaps someone else will know of something I've missed.
    Regards.

  • How to update the windows cached password after SSPR?

    Scenario: Windows 7 remote user forgets the cached password for her laptop and uses FIM 2010 R2's Reset Password invoked from the login screen. The domain password change is successful, but the user still cannot login to the laptop as the
    cached password has not been updated.
    Question: How to update the cached windows logon password after SSPR to allow user to login with the new password.
    Thanks 

    Please try the following:
    KB2845626 - Cached credentials are not updated when you change your password in Windows
    If you found my post helpful, please give it a Helpful vote. If it answered your question, remember to mark it as an Answer.

  • How to update the condition price in the sales order for all the items

    Hi,
    How to update the condition price for all the itmes in the sales order to carry out the new price automatically through a stand alone program, for all the orders in the billing due list table?
    Thanks,
    Balaram

    Hi,
    There is a change in the requirement.
    Scenario:
    I have created a sales order with some 4 condition types, in that 2 condition types are of class A & B and the other two is of class C. Here I need to update the condition price of class A & B only and the remaining condition types should not get update even though there is an updated price is available.
    For the above scenario, I need to write a standalone program. Do we have any function modules to update the price of the single condition in the sales order? Please tell me how we can update the sales order at item condition level.
    Thanks.
    Balaram

  • How to update the condition price in sales order while creating the invoice

    Hi,
    How to update the condition price in the sales order to carry out the new price while creating the invoice?
    While creating the invoice it should update the condition price in sales order.
    Thanks,
    Balaram

    No, pricing is not there in delivery.
    I found an exit for VF01transaction where we can update the price in order.
    Can you please tell me how to update the price if I have the order, material numbers and conditions number?
    Thanks,
    Balaram

  • How to update the inventory after committing order..?

    How to update the Inventory stock level of a commerce item after committing the order.. in ATG 10.0.1..?
    Thanks in Advance,
    Vishnu & Nithin Kayithi

    you can add the pipeline chain after the processOrder in the commerce pipeline , in the runProcess method call InventoryManager.decreaseStockLevel(String pId, long pNumber);

  • How to reload the screen when changing languages in JavaFX 2?

    I'm beginner with javaFX and i need to change language of the screen. but i have no idea how to reload the screen when the language was changed. The application have a button where have the language available. I want just refresh screen when the user change language.
    Here is the start method to show the stage.
        @Override
        public void start(Stage stage) throws Exception
            this.stage = stage;
            Locale locale = Locale.getDefault();
            ResourceBundle rb = ResourceBundle.getBundle("resources/Label",locale);
            loader = new FXMLLoader(getClass().getResource("FXMLDocument.fxml"),rb);
            root = (Parent)loader.load();
            FXMLDocumentController controller = (FXMLDocumentController) loader.getController();
            controller.setMain(this);
            scene = new Scene(root);
            stage.setScene(scene);
            stage.show();
    here is the function to change the language(in the same class with start function),the rb is the new ResourceBundle:
        public void refresh(ResourceBundle rb)
              //change the language here
    1. I don't want to use the resourceBundle to get value in resource file and set label in scene one by one.like following:
    this.btnLabel.setText(rb.getString(key.test));
    2. I don't want to reload the scene,like following:
        public void refresh(ResourceBundle rb)
             try
                loader = new FXMLLoader(getClass().getResource("FXMLDocument.fxml"),rb);
                root = (Parent)loader.load();
                scene.setRoot(root);
                FXMLDocumentController controller = (FXMLDocumentController) loader.getController();
                controller.setMain(this);
            catch(Exception err)
                err.printStackTrace();
    So do we have a solution to just set the resourceBundle and reload the scene easier?
    Thanks and best regards!

    Your option 2 (reload the FXML for the scene using the new resource bundle as a parameter), is the way this would normally be done and what I would recommend.
    Failing that, you could use option 1 of individually resetting the label text of labeled items (I don't really recommend this).
    Why don't you want to use option 2?
    Perhaps it is because there is some internal state of the UI which differs from the initial state when the the UI is first loaded (e.g. user has typed text in a text field and you want to preserve that).  If that's the case you will need to either go with your option 1 of individually resetting the label text of labeled items, or implement something which preserves the UI state and user data by saving it in memory or to disk, reloading the UI via the FXMLLoader (essentially your option 2), then restoring the UI state and user data to what it was before the language change.  Preserving and restoring the modified state seems complicated to me if you have a lot of state, so I wouldn't really advise this approach unless you really needed it.

  • How to update the data in sqlserver table using procedure in biztalkserver

    Hi,
    Please can any one answer this below question
    how to update the data in sqlserver table using procedure in biztalkserver
    while am using executescalar,typedprocedure getting some warning
    Warning:The adapter failed to transmit message going to send port "SendtoSql1" with URL "mssql://nal126//MU_Stage2?". It will be retransmitted after the retry interval specified for this Send Port. Details
    Please send me asap....
    Thanks...

    Hi Messip,
    A detailed error would have helped us to answer you more appropriately but
    You can follow the post which has step by step instructions, to understand how to use Stored Procedure:
    http://tech-findings.blogspot.in/2013/07/insert-records-in-sql-server-using-wcf.html
    Maheshkumar
    S Tiwari|User
    Page|Blog|BizTalk
    2013: Inserting RawXML (Whole Incoming XML Message) in SQL database

  • How to clear the screen in java?

    Hi,
    How to clear the screen in java without using any loops?
    Thanks

    Just paint with your background color to let the old paintings vanish.

  • Hi, updated my iphone where in the middle of updated the screen showed i must connect to itunes. after connecting iphone was updated but everything was deleted. was first time on itunes , so have no backup. can i recover my pics and contacts? please help

    hi, updated my iphone where in the middle of updated the screen showed i must connect to itunes. after connecting to itunes my  iphone was updated but everything was deleted. was first time on itunes , so have no backup. can i recover my pics and contacts? please help

    If this has happened more than once the problem is likely on your PC.
    See here: http://www.apple.com/support/iphone/assistant/itunes/

Maybe you are looking for

  • My USA purchased iPhone 4S factory unlock is not working in India as it gets no signal bars

    Hi, I got my iPhone 4S from USA, which came with AT&T sim in it. It was sold as factory unlocked but when I inserted Indian sim card in it , there appeared the name of the service provider but no signals. Can anybody help as what best can be done to

  • Best Practice for SSL in Apache/WL6.0SP1 configuration?

    What is the best practice for eanbling SSL in an Apache/WL6.0SP1 configuration? Is it: Browser to Apache: HTTPS Apache to WL: HTTP or Browser to Apache: HTTPS Apache to WL: HTTPS The first approach seems more efficient (assuming that Apache and WL ar

  • Has anyone solved itunes skipping?

    I posted a little while ago about this problem and it seems I was not the only person experiencing the problem of itunes sounding like a skipping cd. A number of different suggestions were made, and I've gone through all of them to no avail, and want

  • Set up

    wireless set up

  • Requisition change order workflow - custom wf not being picked

    Oracle Standard Requisition change order workflow doesnt meet the client requirement. so we had to customize the poreqcha workflow. Steps 1. Changed poreqcha.wft and complied using another name. 2. Associated the workflow in document types. ( Purchas