How to create a grid with arrays and booleans?

As part of a bigger project, I'm trying to create a sub-VI which will allow me to move a "cursor" in a 3x3 array.
There should be 2 boolean inputs, one for moving down in the array, and the other for moving to the right. Once the edge of the array has been reached, the "cursor" will start back from the beginning.
I have a vague idea of a 2 dimensional array with LED's. Once "down" has been pressed, the LED corresponding to (0,0) will turn off, turning (0,1) on. Same goes for the "right" button. When "down" is pressed at (0,2), the LED should turn off, and LED (0,0) should turn on.
I'm sure it has something to do with initializing arrays, but i can't seem to find the right way to do it.
Any kind of assistance is much appreciated. Thanks!
Solved!
Go to Solution.

Maybe this will help.
Oh, I just noticed that I could have done the "Clear True" outside of the inner case structure and some other things too, but oh well - it works.
Help the forum when you get help. Click the "Solution?" icon on the reply that answers your
question. Give "Kudos" to replies that help.
Attachments:
grid_png.vi ‏14 KB

Similar Messages

  • How to create a chart with x and y input arrays

    I am trying to create a chart that receives chunks of data from a while loop.  I know how to create a chart in order to append new data points to those points already in the display, but a regular chart doesn't let me specify the x axis data points.  Is there a way to create a chart with x and y array inputs?
    Thanx,
    Tom

    It's called an XY Graph. If you need an XY graph to behave like a chart, look at the shipping example called XY Chart.

  • How to Create a Table with Merge and partitions in HANA

    Hi,
    What is the best way to create a Table with MERGE and PARTITION and UNLOAD PRIORITIES.
    Any body can you please give me some examples.
    Regards,
    Deva

    Ok,
    1) the UNLOAD PRIORITY has nothing to do with the order of data loads in your ETL process
    2) Unloading of columns will happen automatically. Don't specify anything specific for the tables, then SAP HANA will take care about it
    3) Not sure where you get your ideas from, but there is no need to manually "flush" tables or anything like that. SAP HANA will take care of memory housekeeping.
    4) Partitioning and how to specify it for tables has been largely documented. Just read up on it.
    5) Delta Merge will happen automatically, as long as you don't prevent it (e.g. by trying to outsmart the mergedog rules)
    Seriously, I get the impressions that this list of requirements is based on some hear-say and lack of actual information and experience with SAP HANA. There are a couple of extensive discussions on data loading optimization available here in SCN and on SAPHANA.COM. Please read those first.
    All this had been discussed broadly a couple of times.
    - Lars

  • How to create a playlist with podcasts AND music?

    I created a playlist with both podcasts and music in it. The thing is when I try to shuffle it, only music plays. When I start playing podcasts, none of my music plays. How can I make them both play at the same time and shuffle on the same playlist?

    In iTunes, you created a playlist (with songs and podcasts), and then synced that playlist to the iPod?  Or you manually created a playlist on the iPod, and manually added songs and podcasts to that playlist?  It needs to be an actual playlist that is on the iPod, not simply songs and podcasts on the iPod.
    If you have a playlist on the iPod....  In shuffle mode, only songs play.  Set the iPod to play-in-order (not shuffle).  Then, select the playlist on the iPod (by selecting Music -> Playlists from the Home screen).  With the playlist selected, press Play/Pause.  The playlist plays the song and podcasts in the order shown for that playlist in iTunes.

  • How to create the document with originals and checkin that document

    I am using this 2 bapi for creating DMS ,
    BAPI_DOCUMENT_CREATE2
    BAPI_TRANSACTION_COMMIT
    BAPI_DOCUMENT_CHECKIN2
    BAPI_TRANSACTION_COMMIT
    at last we want to c in DRAO table the created doc no should be updated here.
    But it not updating.how can i update in the table..
    Please tell via code..

    How do you call BAPI_DOCUMENT_CREATE2?
    I just tried with the example given in the documentation and with a little adjustment I created a document with an original which appears in the DMS_DOC_FILES table.
      DATA: ls_doc    LIKE bapi_doc_draw2,
            ls_return LIKE bapiret2.
      DATA: lf_doctype    LIKE bapi_doc_draw2-documenttype,
            lf_docnumber  LIKE bapi_doc_draw2-documentnumber,
            lf_docpart    LIKE bapi_doc_draw2-documentpart,
            lf_docversion LIKE bapi_doc_draw2-documentversion.
      DATA: lt_files LIKE bapi_doc_files2 OCCURS 0 WITH HEADER LINE,
            lt_drat  LIKE bapi_doc_drat OCCURS 0 WITH HEADER LINE.
      ls_doc-documenttype    = 'Z01'.
      ls_doc-documentversion = '01'.
      ls_doc-documentpart    = '000'.
      ls_doc-statusextern   = 'DR'.
      ls_doc-laboratory     = '001'.
      REFRESH lt_files.
      CLEAR lt_files.
      lt_files-docfile      = 'c:\BP\test.docx'.
      APPEND lt_files.
      CLEAR lt_drat.
      REFRESH lt_drat.
      lt_drat-language    = 'EN'.
      lt_drat-description = 'Info Rec Description'.
      APPEND lt_drat.
      CALL FUNCTION 'BAPI_DOCUMENT_CREATE2'
            EXPORTING: documentdata         = ls_doc
            IMPORTING: documenttype         = lf_doctype
                       documentnumber       = lf_docnumber
                       documentpart         = lf_docpart
                       documentversion      = lf_docversion
                       return               = ls_return
           TABLES: documentdescriptions = lt_drat
                   documentfiles        = lt_files.
      IF ls_return-type CA 'EA'.
        ROLLBACK WORK.
        MESSAGE ID '26' TYPE 'I' NUMBER '000'
                WITH ls_return-message.
      ELSE.
        COMMIT WORK.
      ENDIF.
    Best Regards,
    Martin

  • How to create Date relationship with Fact and DimDate on Tabular model?

    I have two tables in SQL Server 2014 SSAS Tabular model.
    DimDate(defined as data table) have date column (format is 1.7.2010 00:00:00) This table have been impoted from AdventureWorks.
    FactSales have SalesDate column (format is 25.03.2015 18:08:05). This table have been imported from Excel. Colums is defined as date in Excel.
    When I set Data Type as date in Tabular I get error:
    "Datatype conversion failed for table...Value:'25.03.2015 18:08:05'"
    I have tried to create calculated colums like =DATEVALUE([SalesDate]) and =DATE(YEAR([SalesDate]),MONTH([SalesDate]), DAY([SalesDate])), but getting error.
    What should I do so that I can create relationship between Date column?
    Kenny_I

    Hi Kenny_l,
    According to your description, you fail to convert the data type into date after creating calculated column with expression. Right?
    In Analysis Services, the tabular will detect the source data type to determine which data type can be converted to. If you want to convert a data into date type, no matter this data is from database or a file, you must make sure this data can be recognized
    as a date in SQL Server. In this scenario, the format '25.03.2015 18:08:05' can't be recognized as date even you apply DAX functions. So please change the format of the column in excel like "03.25.2015 18:08:05".
    PS: For testing, you can create a temp table and insert sample text into a date column, because the date format in SQL Server depends on the location selection when installing.
    After retrieving data from data source and all values within column are correct format, you can change the data type into Date, and select the format you expect.
    If you have any question, please feel free to ask.
    Best Regards,
    Simon Hou
    TechNet Community Support

  • How to create Base Dimensions with MaxL and Text File?

    Hi,
    Doing a scratch rebuild of a cube every month. Don't want to have a 'dummy' outline with base dimensions to copy over every build. Instead want to build from text file somehow. Thus my plan is to: 1) Delete the existing app/db 2) Create a new blank app/db 3) Create the base dimensions in the outline via text file and 4) Build entire outline via a text file. I'm stuck on #3 how to get the 'base dimensions' built via text file. I need:
    ACCOUNTS
    PERIOD
    VALUE
    VIEWS
    SCENARIO
    CUSTOM4
    YEAR
    CUSTOM3
    CUSTOM2
    ENTITY
    CUSTOM1
    I see this MaxL, but it uses a 'rules file' and I never have built a rules file to create base dims so I'm confused if it's possible or not...
    import database sample.basic dimensions
    from data_file '/data/calcdat.txt'
    using rules_file '/data/rulesfile.rul'
    on error append to '/logs/dimbuild.log';

    We rebuild our Departments and Organization from an enterprise hierarchy master each week.
    The way we implemented (what you call #3) was to not do #1 and #2, but to have a "destructive" load rule for each of these dimensions using a text file. (in the "Dimension Build Settings" for the load rule, select "Remove Unspecified" to make it destructive)
    The text file just has the dimension name (parent) and any children we needed defined in a parent/child relationship. For instance
    "Sales Departments" "0100-All Departments"
    This essentially works the same as deleting the app because the destructive load rules will drop all the blocks of data that were unspecified.
    Then we run our SQL load rule to build the rest of the dimensions from the Location Master.
    We perform a level-0 export prior to this process, then reload the level-0 data and execute all the consolidation scripts to get the data back (now in a current enterprise defined hierarchy)

  • Urgent:HOW TO CREATE A PROGRAMME WITH MENUS AND MENUITEMS IN AWT?

    hi am new to java..............and i know very less about java
    can anyone help me by sending the code for creating menu with file,edit ,view and menuitems as open,save,exit.
    and also plss help me how to get a filedialog box in the same programme when i click the open in filemenu.
    in AWT.....................plsss urgent

    sangi wrote:
    hi am new to java..............and i know very less about javaredundant and barely intelligible
    can anyone help me by sending the code for creating menu with file,edit ,view and menuitems as open,save,exit.have you tried a Swing demo? aside from the fact that this code has likely been written and published hundreds of times on the web, a simple tutorial would have shown you how to do this.
    and also plss help me how to get a filedialog box in the same programme when i click the open in filemenu.
    in AWTslow down, one thing at a time
    go do the tutorials first
    .....................plsss urgentstating your task is urgent is offensive here
    learn how to communicate lest you get flamed
    good luck

  • How to create Clipping Masks with Shapes and Text?

    Hi there! I am new to Illustrator and am currently attempting to learn it. I am creating a logo that has text and has a shape that goes through the text to make the text appear as if it has claw marks in it.
    I have two layers. The layer with the shape "claw" marks, and a layer with the text. The shape layer is currently above and the text layer is currently below. If I select both layers and click on Make Clipping Mask it has the text displayed within the little claw marks, how do I reverse that? Because when I try to change the order of the layers it doesn't clip anything?
    Thank you so much!
    Aaron

    Hi Monika,
    Sorry for taking so long to reply... This is what I am trying to accomplish. I tried following your directions above, but that only made the text invisible and I tried moving the claw layers above and below the text... and it only appeared as if the claws per se were filling up with the text color.
    Here is what I am trying to accomplish:

  • How to create process chain with dso and infocube at a time

    hi friends,
      i have a FLATFILE in application server and i need to upload it to STANDARD DSO and i created a INFO PACKAGE and DTP for DSO.
    i have a STANDARD INFOCUBE to upload data from above DSO. here DSO is the source.  i want to schedule  this process in process chain. how could i do this. any one please give me solution.
         can any one explain me the options in RSPC and how they work and where we exactly use. this is very helpful to me. please give me guidance. thank you.
    thanks,
    sree

    First make sure you have already created the infopackage to load the data from server to the DSO and the DTP to load data from DSO to the Cube.
    Now goto Tcode RSPC.
    Choose Create process Chain option. provide appropriate technical name and description.
    Drag "Execute infopackage" process type from left hand side pane in RSPC.  Choose the infopackage to load the data from Server to DSO. you can find this infopackage using the F4 help in the above selected process type.
    Drag the "data transfer process" process type to load data from the Flat file data source above to the DSO.
    Then Drag the "Activate DataStore Request"  process type and select the DSO in which you would load the data  using the above DTP.
    Drag the "data transfer process" process type to load data from DSO to the Cube.
    Save, activate  and schedule the process chain according to appropriate time.

  • How to create a prerequisities with VS2013 and Installshield LE ?

    Hello,
    I want to create a new installer with an existing application. I use VS2013 with Installshield LE.
    I've any problem with the requirments : I would like to do a software requirment with another programm (driver), than I use a registry key inside HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\programToTest
    And then I test a value : DisplayVersion
    I use "registry entry" choice.
    But it isn't working. All time it don't detect this key, present or not present, I have all time my error message.
    Thank you for your help.
    Best regards,

    Hi foudesoft,
    Thank you for posting in MSDN forum.
    Since this forum is to discuss: Visual Studio WPF/SL Designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help System, and Visual Studio Editor.
    As you said the Installshield LE, I did some research about it and found it is a third-party tool. So I would recommend you consider posting this issue at the following forum to get supports.
    http://community.flexerasoftware.com/forumdisplay.php?133-InstallShield
    Thanks for your understanding.
    Best Regards,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How to create materialized  view with parameter and index ?

    Hi all,
    i am using oracle 11g.
    i want to create  parameter materialized view  with two parameter (STORED_VALUE, LOV_NAME) with  an index .
    i have below view
    CREATE OR REPLACE FORCE VIEW SR_MY_TEST(DISPLAYED_VALUE, STORED_VALUE, LOV_NAME) AS
      SELECT  DISPLAYED_VALUE , LOVVALUE.STORED_VALUE , lovname.lov_name
               FROM (SELECT T.LOV_VALUE_ID,
          T.LOV_ID,
          T.ORG_ENTITY_ID,
          T.STORED_VALUE,
          T.DISPLAYED_VALUE,
          T.ENTERPRISE_ID
         FROM MS_QS_LIST_OF_VALUES_T T) lovvalue, ms_qs_lov_names lovname
              WHERE lovvalue.lov_id = lovname.lov_id
                AND lovvalue.org_entity_id = 1
                and LOVVALUE.ENTERPRISE_ID = 100000
                AND LOVNAME.ENTERPRISE_ID = 100000;
    i want to create index on   STORED_VALUE, LOV_NAME
    Thanks
    Damby

    No.AFAIK, there's nothing called as "parameterized MV".
    Materialized View store data like tables (and not like Views). So, does it make sense when you say - "table with parameters" ?
    Could you please explain your business requirement?
    What is the purpose behind those 2 parameters?

  • How I create a label with drag and drop?

    I have the next...
    I want to be able to move to a label (drag and drop) of swing in my panel contained in jframe.
    I already identify the position of the mouse with the method mouseMoved
    With the method ---jButton1ActionPerformed--- that I assign to each button I identify the selected component
    With the property setBounds of the button I assign the new hubicaci�n of the button.
    My questions:
    This good which I am doing?
    Like sending in value X and the value to him and of the position of the mouse to the button?
    Help me, please
    NOTE: in the example comence using JButton, but must be labels.
    import java.awt.dnd.DropTarget;
    import java.awt.event.MouseEvent;
    import java.awt.event.MouseMotionListener;
    import javax.swing.JButton;
    * @author Administrador
    public class MYCLass extends javax.swing.JFrame implements MouseMotionListener {
    private int coorX, coorY;
    private JButton general = null;
    /** Creates a new instance of MYCLass */
    public MYCLass() {
    System.out.println("Layout " + this.getContentPane().getLayout());
    this.getContentPane().setLayout(null);
    addMouseMotionListener(this);
    JButton jb = new JButton("1.- El botonsito");
    JButton jb2 = new JButton("2.- El botonsito");
    jb.setBounds(16,100,100,25);
    jb2.setBounds(16,280,100,25);
    jb.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    jButton1ActionPerformed(evt);
    jb2.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    jButton1ActionPerformed(evt);
    this.getContentPane().add(jb);
    this.getContentPane().add(jb2);
    this.pack();
    this.setSize(300, 600);
    private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {
    if (this.isFocusable()) {
    System.out.println("POSICION X " + coorX);
    System.out.println("POSICION y " + coorY);
    // general = (JButton) ((javax.swing.JPanel) this.getContentPane().getC).getComponentAt(coorX,coorY);
    System.out.println(" boton genral tiene valor: " + general );
    // this.setBounds(coorX,coorY,100,25);
    System.out.println("Obtuvo el foco.... " + evt.getActionCommand());
    // this.getComponentAt();
    // System.out.println("Obtuvo el nombre... " + this.getName());
    public void mouseDragged(MouseEvent e) {
    repaint( );
    public void mouseMoved(MouseEvent e) {
    if(e.getClickCount() == 2) {
    System.out.println("Se presiono 2 veces el MOUSE");
    coorX = e.getX();
    coorY = e.getY();
    System.out.println("POSICION X " + coorX);
    System.out.println("POSICION y " + coorY);
    * @param args the command line arguments
    public static void main(String args[]) {
    java.awt.EventQueue.invokeLater(new Runnable() {
    public void run() {
    new MYCLass().setVisible(true);
    }

    Hello!!!!
    I have the next......
    It modifies it and I am of the following form
    Give its opinion me, thanks!!!!
    import java.awt.dnd.DropTarget;
    import java.awt.event.MouseAdapter;
    import java.awt.event.MouseEvent;
    import java.awt.event.MouseMotionListener;
    import javax.swing.JButton;
    import javax.swing.JLabel;
    * @author Administrador
    public class MYCLass extends javax.swing.JFrame implements MouseMotionListener {
    private int coorX, coorY;
    private JLabel labelPrincipal = null;
    /** Creates a new instance of MYCLass */
    public MYCLass() {
    System.out.println("Layout " + this.getContentPane().getLayout());
    this.getContentPane().setLayout(null);
    addMouseMotionListener(this);
    JLabel jl1 = new JLabel("1.- Etiqueta... ");
    JLabel jl2 = new JLabel("2.- Etiqueta... ");
    jl1.setBounds(16,100,100,25);
    jl2.setBounds(16,280,100,25);
    jl1.addMouseListener(new MouseAdapter() {
    public void mouseClicked(MouseEvent e) {
    System.out.println("Click");
    System.out.println("Source... " + e.getSource());
    labelPrincipal = (JLabel) e.getSource();
    labelPrincipal.setText("Texto especial .....");
    jl2.addMouseListener(new MouseAdapter() {
    public void mouseClicked(MouseEvent e) {
    System.out.println("Click");
    System.out.println("Source... " + e.getSource());
    labelPrincipal = (JLabel) e.getSource();
    labelPrincipal.setText("Cambia tu texto.....");
    this.addMouseListener(new java.awt.event.MouseAdapter() {
    public void mouseClicked(java.awt.event.MouseEvent evt) {
    formMouseClicked(evt);
    this.getContentPane().add(jl1);
    this.getContentPane().add(jl2);
    this.pack();
    this.setSize(300, 600);
    private void formMouseClicked(java.awt.event.MouseEvent evt) {
    if (evt.getClickCount() == 2) {
    // labelPrincipal.setBounds(coorX,coorY,120,25);
    System.out.println( "PRESIONO EL MOUSE.. " + evt.getClickCount());
    labelPrincipal = null;
    public void mouseDragged(MouseEvent e) {
    public void mouseMoved(MouseEvent e) {
    if (labelPrincipal != null) {
    coorX = e.getX();
    coorY = e.getY();
    System.out.println("POSICION X " + coorX);
    System.out.println("POSICION y " + coorY);
    labelPrincipal.setBounds(coorX-1,coorY-35,120,25);
    * @param args the command line arguments
    public static void main(String args[]) {
    java.awt.EventQueue.invokeLater(new Runnable() {
    public void run() {
    new MYCLass().setVisible(true);
    }

  • How to create a page with LOV and a Go Button that calls a sproc

    I'm new to Apex but not Oracle. I've done some VB, C and other programming.
    I have read the 2 Day + and worked through most of the advanced tutorials as well as the Apex 3.0 ermployee task OBE. I'm looks for an OBE or assistance in doing the following:
    I need to create a page that has a dynamic LOV that pulls CUSTOMER NAME as d, and ID as r (this I can do).
    I need a button on the page "Go". Here's the use case.
    User selects a customer from the LOV
    User presses Go
    Go invokes myschema.go_sproc and passes in LOV selected Cust ID
    myschema.go_sproc does some work and passes back a Status
    Status is displayed to the user
    Any pointers are appreciated.

    Great.
    Two last questions:
    #1 Is there a Apex Reference, like the SQL Reference, that lists all the various settings and options and their meanings, for instance on the create region page there are many different region types. Is this information centralized in one place? I don't see (or I am missing it) in the list of Apex 3.2 books.
    #2 For my use case would you use a HTML region or some other type of region?
    Thanks again.
    George

  • How to create search engine (with UIX and BC4J) across nested VOs?

    Suppose I have N:N relationship beetween the DB tables so the intermediary table is created (PK is Primary Key, FK is foreign key):
    table1 (PK_ID1, ATTR11, ATTR12...)
    table2 (FK_ID1, FK_ID3) //where both FKs are Primary Key this is intermediary table
    table3 (PK_ID3, ATTR31, ATTR32...)
    The goal is to create a data model (ie EOs, VOs and AM) so that I can create a search page in UIX that would have search fields from tables 1 and 3 ! However, the search result display should return only table 1.
    for example:
    table1=INDIVIDUALS (IID, FIRST_NAME, LAST_NAME...)
    table2=EMP_PHO(IID, PID)
    table3=PHONES(PID, PHONE)
    so an individual may have more than one phone and one phone may belong to more then one individual (ie family home phone)
    and say, I want to search by phone number (PHONE) and to return individuals in a table?
    Please help

    Hai Nikhil,
    Please find below sample code for your report logic.
    REPORT  ZJAK1.
    tables:makt.
    select * from makt where maktx like 'test%'.
    write:/10 makt-maktx.
    endselect.
    output of this program
    tested
    test
    test forcast
    if useful please provide points.
    Jaheer

Maybe you are looking for