[JS CS3] Trouble with changeGrep() array

This is strange, or else I'm totally missing something simple:
My script does a GREP search for a text string in a table, and assigns a paragraph style to the string. Next, for each string that was found, I want to merge the cell that contains the string with the two cells directly to the right of the cell. The line
var myFound = mySelection.changeGrep();
does the changing of the text string.
I understand that changeGrep() returns an array, in this case, of insertion points. When I run the script on a table that contains 5 instances of the string that the Grep search is looking for, myFound returns an array of 5 insertion points like I'd expect. Except that if I pause the script and examine the contents of the array, this is what I get:
myFound[0].parent.contents displays the correct (first) text string that was changed
myFound[1].parent.contents isn't correct. It displays the contents of the cell directly to the left of he text string that was changed.
myFound[2] through myFound[4] are also incorrect.
Again, this is examining the array before I do anything to the table such as merging cells, etc.
So, why doesn't the array return the correct insertion points?
Here is the full script function:
function myProcessTable(mySelection) {
// Specify the column width
mySelection.columns.item(0).width = 68;
mySelection.columns.item(1).width = 103.5;
mySelection.columns.item(2).width = 24;
mySelection.columns.item(3).width = 16;
mySelection.columns.item(4).width = 16;
mySelection.columns.item(5).width = 16;
// Find every occurance of ddd.dd/d in the current table, and apply the Table body, cond, center paragraph style,
app.findGrepPreferences = NothingEnum.nothing;
app.changeGrepPreferences = NothingEnum.nothing;
app.findGrepPreferences.findWhat = "\\d.\\d\\d/\\d";
app.changeGrepPreferences.appliedParagraphStyle = app.activeDocument.paragraphStyles.itemByID(locateParagraphStyle("Table body, cond, center"));
var myFound = mySelection.changeGrep();
alert ("Search is completed. " + myFound.length + " replacement(s) made.")
// merge the cell with the two cells to the right
for (i=myFound.length-1; i>=0; i--) { // iterate through each found occurance
var myCell = myFound[i].parent;
var myTable = myCell.parent;
var myRow = myCell.parentRow.index;
var myColumn = myCell.parentColumn.index;
myCell.merge(myTable.rows[myRow].cells[myColumn+2]);

Keith,
changeGrep()'s arrays can't be used for anything, so that's where your script runs into trouble -- it's nothing to do with tables. To work around that, use findGrep()'s array.Immediately before this line:
for (i=myFound.length-1; i>=0; i--) { // iterate through each found occurance
add this one:
var myFound = mySelection.findGrep();
Peter

Similar Messages

  • Trouble with primitive arrays and casting, lesson 521

    hi everyone!
    there is a problem i discovered right now - after years with java where was no necessity to do this.....
    and i'm shure this must have been the topic already, but i couldn't find any helpful resource :-/
    right here we go:
    1. an array is a (special) kind of object.
    2. there are "primitive" arrays and such containing references to objects. of course - and i imagine why - they are treated differently by the VM.
    3. then both are - somehow - subclasses of Object. whereas primitive types are not really, primitive-arrays are. this is hidden to the programmer....
    4. any array can be "pointed" at via local Object variable, like this:
    Object xyz = new int[6];
    5. arrays of Objects (with different dimensions) can be casted, like this:
      Object pointer = null;
      Object[]   o  = new SomeClass[42] ;
      Object[][] oo = new OtherClass[23] [2] ;
      Object[][][] ooo = new OtherClass[23] [2] [9] ;
      o = oo = ooo;     // this is save to do,
                                   //because "n-dimensional" object-arrays
                                  // are just arrays of  other arrays, down to simple array
    pointer = o;         // ok, we are referencing o via Object "pointer"6. but, you cannot do this with primitive types:
      int[]  i1 = new int [99] ;
      int[][] i2 = new int [1] [3] ;
      i1 = i2                  // terror: impossible. this is awful, if you ask me.
                                   // ok, one could talk about "special cases" and
                                   // "the way the VM works", but this is not of interest to me as
                                   // a programmer. i'm not happy with that array-mess!
      pointer = i2;       // now this is completely legal. i2, i1 etc is an object!7. after the preparation, let's get into my main trouble (you have the answer, i know!) :
    suppose i have a class, with methods that should process ANY kind of object given. and - i don't know which. i only get it at runtime from an unknown source.
    let's say: public void BlackBox( Object x );
    inside, i know that there might be regular objects or arrays, and for this case i have some special hidden method, just for arrays... now try to find it out:
    public void BlackBox( Object x )
      if ( x == null)
           return;
       Class c = x.getClass();
       if ( c.isArray() )
              // call the array method if it's an array.........
              BlackBoxes(     (Object [] )  x );         // wait: this is a cast! and it WILL throw an exception, eventually!
              return;
       else
               DoSpecialStuffWith( x );
    }ok ? now, to process any kind of array, the special method you cannot reach from outside:
    private void BlackBoxes( Object[] xs )
       if ( xs != null )
            for ( Object x : xs )
                 BlackBox( x );
    // this will end up in some kind of recursion with more than one array-dimension, or when an Object[] has any other array as element!this approach is perfectly save when processing any (real) Object, array or "multi-dimensional" arrays of Objects.
    but, you cannot use this with primitive type arrays.
    using generics wouldn't help, because internally it is all downcasted to Object.
    BlackBox( new Integer(3) ) ---- does work, using a wrapper class
    BlackBox( new Integer[3] ) ----- yep!
    BlackBox( 3 ) ---- even this!
    BlackBox( new int[42] ) ---- bang! ClassCastException, Object[] != int[]
    i'm stuck. i see no way to do this smoothly. i could write thousands of methods for each primitive array - BlackBox( int[] is ) etc. - but this wouldn't help. because i can't cast an int[][] to int[], i would also have to write countless methods for each dimension. and guess, how much there are?
    suppose, i ultimately wrote thousands of possible primitive-type methods. it would be easy to undergo any of it, writing this:
    BlackBox( (Object) new int[9] [9] );
    the method-signature would again only fit to my first method, so the whole work is useless. i CAN cast an int[] to Object, but there seems no convenient way to get the real array out of Object - in a generic way.
    i wonder, how do you write a serialisation-engine? and NO, i can't rely on "right usage" of my classes, i must assume the worst case...
    any help appreciated!

    thanks, brigand!
    your code looks weird to me g and i think there's at least one false assumption: .length of a multidimensional array returns only the number of "top-level" subarrays. that means, every length of every subarray may vary. ;)
    well i guess i figured it out, in some way:
    an int is no Object;
    int[ ] is an Object
    the ComponentType of int [ ] is int
    so, the ComponentType of an Object int[ ] is no Object, thus it cannot be casted to Object.
    but the ComponentType of int [ ] [ ] IS Object, because it is int [ ] !
    so every method which expects Object[], will work fine with int[ ] [ ] !!
    now, you only need special treatment for 1-dimensional primitive arrays:
    i wrote some code, which prints me everything of everything:
        //this method generates tabs for indentation
        static String Pre( int depth)
             StringBuilder pre = new StringBuilder();
             for ( int i = 0; i < depth; i++)
                  pre.append( "\t" );
             return pre.toString();
        //top-level acces for any Object
        static void Print( Object t)
             Print ( t, 0);
        //the same, but with indentation depth
        static void Print( Object t, int depth)
            if ( t != null )
                 //be shure it is treated exactly as the class it represents, not any downcast
                 t = t.getClass().cast( t );
                if ( t.getClass().isArray() )
                     //special treatment for int[]
                     if ( t instanceof int[])
                          Print( (int[]) t, depth);
                     // everything else can be Object[] !
                     else
                          Print( (Object[]) t, depth );
                     return;
                else
                    System.out.println( Pre(depth) + " [ single object:] " + t.toString() );
            else
                System.out.println( Pre(depth) + "[null!]");
        // now top-level print for any array of Objects
        static void Print( Object [] o)
             Print( o, 0 );
        // the same with indentation
        static void Print( Object [] o, int depth)
            System.out.println( Pre(depth) + "array object " + o.toString() );
            for ( Object so : o )
                    Print( so, depth + 1 );
        //the last 2 methods are only for int[] !
        static void Print( int[] is)
             Print( is, 0 );
        static void Print( int[] is, int depth)
            System.out.println( Pre(depth) + "primitive array object " + is.toString() );
            // use the same one-Object method as every other Object!
            for ( int i : is)
                 Print ( i, depth + 1 );
            System.out.println( "-----------------------------" );
        }now, calling it with
    Print ( (int) 4 );
    Print ( new int[] {1,2,3} );
    Print( new int[][] {{1,2,3}, {4,5,6}} );
    Print( new int[][][] {{{1,2,3}, {4,5,6}} , {{7,8,9}, {10,11,12}}, {{13,14,15}, {16,17,18}} } );
    Print( (Object) (new int[][][][] {{{{99}}}} ) );
    produces this fine array-tree:
    [ single object:] 4
    primitive array object [I@9cab16
          [ single object:] 1
          [ single object:] 2
          [ single object:] 3
    array object [[I@1a46e30
         primitive array object [I@3e25a5
               [ single object:] 1
               [ single object:] 2
               [ single object:] 3
         primitive array object [I@19821f
               [ single object:] 4
               [ single object:] 5
               [ single object:] 6
    array object [[[I@addbf1
         array object [[I@42e816
              primitive array object [I@9304b1
                    [ single object:] 1
                    [ single object:] 2
                    [ single object:] 3
              primitive array object [I@190d11
                    [ single object:] 4
                    [ single object:] 5
                    [ single object:] 6
         array object [[I@a90653
              primitive array object [I@de6ced
                    [ single object:] 7
                    [ single object:] 8
                    [ single object:] 9
              primitive array object [I@c17164
                    [ single object:] 10
                    [ single object:] 11
                    [ single object:] 12
         array object [[I@1fb8ee3
              primitive array object [I@61de33
                    [ single object:] 13
                    [ single object:] 14
                    [ single object:] 15
              primitive array object [I@14318bb
                    [ single object:] 16
                    [ single object:] 17
                    [ single object:] 18
    array object [[[[I@ca0b6
         array object [[[I@10b30a7
              array object [[I@1a758cb
                   primitive array object [I@1b67f74
                         [ single object:] 99
    -----------------------------and i'll have to write 8 methods or so for every primitive[ ] type !
    sounds like a manageable effort... ;-)

  • Having trouble with my array...

    Hi everyone
    Im having trouble completing this code... what i want is for every loop through the method the gallows[][] should go down to the next one. You will see what i mean if you read the comments below. Also why does this code give me an error of "unclosed Character Literals". Its got something to do with the '/' and '\' in the array.
    Thanx heaps for your help guys
    import java.io.*;
    import java.util.*;
    public class Gallows
       public static void main(String[] args)
          char bodyPart;
          char[][] gallows = new char[6][7];
          gallows[0][0] = '-';
          gallows[1][0] = '|';
          gallows[2][0] = '|';
          gallows[3][0] = '|';
          gallows[4][0] = '|';
          gallows[5][0] = '|';
          gallows[0][1] = '-';
          gallows[0][2] = '-';
          gallows[0][3] = '-';
          gallows[0][4] = '-';
          gallows[0][5] = '-';
          gallows[1][5] = '|';
          gallows[2][5] = '0';
          gallows[2][4] = '\';
          gallows[2][6] = '/';
          gallows[3][5] = '|';
          gallows[4][4] = '/';
          gallows[4][6] = '\';
          Display gallows[0][0] to [0][5] so that something like this is displayed:
          |
          |
          |
          |
          |
          if guess does not equal a letter in the word
               print out the next part of the array.
               eg. the first wrong guess will get the gallows[1][5].
               It will then repeat and the next wrong guess will be [2][5]
               etc etc
    }

    Here's an equally funny way to do this:public class Foo
        public static void main(String[] args) {
            Gallows g = new Gallows();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows();
    class Gallows
        private final char[] gallows = new char[]
                {'-', '-', '-', '-', '-', '-', '\n',
                 '|', ' ', ' ', ' ', ' ', '|', '\n',
                 '|', ' ', ' ', ' ', ' ', 'O', '\n',
                 '|', ' ', ' ', ' ', '/', '|', '\\', '\n',
                 '|', ' ', ' ', ' ', '/', ' ', '\\', '\n',
                 '|'};
        private boolean[] display = new boolean[]
                {true, true, true, true, true, true, true,
                 true, true, true, true, true, false, true,
                 true, true, true, true, true, false, true,
                 true, true, true, true, false, false, false, true,
                 true, true, true, true, false, true, false, true,
                 true};
        private final int[] bodyParts = new int[] {12, 19, 25, 26, 27, 33, 35};
        private int wrongGuesses = 0;
        public void displayGallows() {
            for (int i = 0; i < gallows.length; i++) {
                if (display)
    System.out.print(gallows[i]);
    System.out.println();
    public void wrongGuess() {
    if (gameOver()) return;
    display[bodyParts[wrongGuesses]] = true;
    wrongGuesses++;
    public boolean gameOver() {
    return wrongGuesses == bodyParts.length;

  • [JS CS3] Trouble with getElements().length

    The "ScriptLabel.jsx" tutorial script has this code fragment:
    var myPageItems = myPage.pageItems.item("myScriptLabel");
    if(myPageItems.getElements().length != 0){
    alert("Found " + myPageItems.getElements().length + " page items with the label.");
    The script works fine as long as the page contains at least one pageItem with the label "myScriptLabel". However, if there are no labeled pageItems, the script fails because myPageItems.getElements().length is invalid.
    I can't figure out how to test for the condition of no pageItems having the label "myScriptLabel" to avoid this error. What am I missing?
    Thanks to anyone who can enlighten me!

    Wow! It's a long time since I've looked at this, but it appears that you have to do something like this:
    myPage = app.documents[0].pages[0];
    myPIs = myPage.pageItems.item("myScriptLabel")
    if (myPIs != null) {
      myPIs = myPIs.getElements();
    } else {
      alert("Tough luck, there aren't any");
    If there are no such items on the page you get null rather than an empty array. If there is just one this still works, but notice I had to use getElements() to get the separate items into an array.
    You can use the .item(Name) construction to directly work on all the objects that match, such as:
    myPage.textFrames.item("HitMe").contents = "Consider yourself hit.";
    Dave

  • CS3-Trouble with Transferred Trimmed Project

    Hello...
    New problem; have not been able to find answer.
    I need to cut a 20 minute SD video down to 10 minutes to share at a retreat for documentary filmmakers. The last interation of the video was on my editor's machine. Saved a trimmed project without previews to an external drive and then transferred the project to my computer.
    The problem is that when I do changes, the renders are glacial. I timed one...2.5 minutes for 50 frames...and there was nothing fancy going on. When I save the project and reopen it, it shows rendering is needed again...some areas required rendering which were not changed.
    Premiere seems to handle other projects ok. Crazy making...there is obviously something I do not understand about working with trimmed projects. My editor has a much newer and more powerful computer, but is running CS3 as well. (Running Win7.)
    The computer is long in the tooth...but has always been fine in the past...and is fine with other projects. What's up? I know I need a new computer but this one should be able to handle this.
    Thanks in advance!

    Thank you for that info. Sounds like things should work just fine.
    The "lost Renders" often happens when one is using an external HDD to edit to/from, or a networked drive, but this does not seem to be your issue.
    When I archive a Project (usually TO and external HDD), I will test that Project, prior to moving on. I have yet to encounter any issues, so long as my Assets are in the Project's folder hierarchy. I have run into issues, with Assets not being gathered, when the Assets are spread about. I encountered this with some SmartSound files, that were in a separate folder, since they were being used in about 22 separate Projects for that client. I learned to Copy those into the Project's folder structure, into Music sub-folders, even if that meant having 22 Copies on my system. That has been the ONLY issue, that I have had with archived Projects, using Project Manager, but do have to admit that other than my initial test, I have not revisited many over the years. Do not have any idea why the Render files are causing an issue, and also why the Projects are slowing down, as they are.
    Hope that others will see what I am missing, and will have tips for you.
    Good luck,
    Hunt

  • Trouble With my array

    Hi everyone
    Im having trouble completing this code... what i want is for every loop through the method the gallows[][] should go down to the next one. You will see what i mean if you read the comments below.
    Thanx heaps for your help guys
    import java.io.*;
    import java.util.*;
    public class Gallows
       public static void main(String[] args)
          char bodyPart;
          char[][] gallows = new char[6][7];
          gallows[0][0] = '-';
          gallows[1][0] = '|';
          gallows[2][0] = '|';
          gallows[3][0] = '|';
          gallows[4][0] = '|';
          gallows[5][0] = '|';
          gallows[0][1] = '-';
          gallows[0][2] = '-';
          gallows[0][3] = '-';
          gallows[0][4] = '-';
          gallows[0][5] = '-';
          gallows[1][5] = '|';
          gallows[2][5] = '0';
          gallows[2][4] = '\';
          gallows[2][6] = '/';
          gallows[3][5] = '|';
          gallows[4][4] = '/';
          gallows[4][6] = '\';
          Display gallows[0][0] to [0][5] so that something like this is displayed:
          |
          |
          |
          |
          |
          if guess does not equal a letter in the word
               print out the next part of the array.
               eg. the first wrong guess will get the gallows[1][5].
               It will then repeat and the next wrong guess will be [2][5]
               etc etc
    }

    disregard that last post..
    The last thing i need to do is make it so that when every part of the array is display (7 wrong guesses) it is to stop the program and display "Bad luck".
    I just dont know where to put this code ... Here are both classes...
    import java.io.*;
    import java.util.*;
    public class Hangman
        static Scanner console = new Scanner(System.in);
        public void play()
            String player;
            System.out.println(" ******WELCOME TO HANGMAN******");
            System.out.println(" ------------------------------");
            System.out.println("       What is your name?       ");
            player = console.nextLine();
            System.out.println("   **Welcome " + player + " & good luck!!**");
            System.out.println("");
            processLetter();
        public void processLetter()
            String input;
            String word;
            int num;
            boolean wordflag;
            Gallows gallows = new Gallows(); // <- added this
            gallows.displayGallows(); // <- and this
            String[] words = new String[10];
            words[0] = "MELBOURNE";
            words[1] = "BEER";
            words[2] = "BRICKLAYER";
            words[3] = "RAINFALL";
            words[4] = "PRISON";
            words[5] = "COLLINGWOOD";
            words[6] = "BOTTLE";
            words[7] = "PUPPY";
            words[8] = "LANGUAGE";
            words[9] = "FISHTANK";
            num = (int)Math.round(Math.random()*9);
            word = words[num];
            StringBuffer wb = new StringBuffer(word);
            for (int i = 0; i < word.length(); i++) wb.setCharAt(i, '-');
            System.out.println("           " + wb);
            System.out.println("Enter a letter or an entire word ");
            boolean letters[] = new boolean['Z' - 'A' + 1];
            for (char i = 'A'; i < 'Z'; ++i)
                letters[i - 'A'] = false;
            input = console.nextLine();
            wordflag = true;
            while (wordflag)
                String newInput = input.toUpperCase();
                if (newInput.equals(word))
                    System.out.println("Congratulations. You have guessed correctly!!!");
                    break;
                char guess = input.charAt(0);
                guess = Character.toUpperCase(guess);
                letters[guess - 'A'] = true;
                for (int i = 0; i < word.length(); i++)
                    int k = word.indexOf(guess, i);
                    if (k >= 0) wb.setCharAt(k, guess);
                if (word.indexOf(guess) == -1) gallows.wrongGuess(); // <- added this line
                gallows.displayGallows(); // <- and this line
                System.out.println("");
                System.out.println("           " + wb);
                System.out.println("");
                System.out.print("Letters Tried: ");
                for (char i = 'A'; i <= 'Z'; ++i)
                    if (letters[i - 'A']) System.out.print(i);
                if (wb.toString().equals(word))
                    System.out.println("");
                    System.out.println("Congratulations, You have guessed the correct word!!!");
                    wordflag = false;
                } else
                    System.out.println("");
                    System.out.println("----------------------------------");
                    System.out.println("Enter a letter or the entire word ");
                    input = console.nextLine();
    }and
    public class HangmanGallows
        public static void main(String[] args)
            Gallows g = new Gallows();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows(); g.wrongGuess();
            g.displayGallows();
    class Gallows
        private final char[] gallows = new char[]
                {'-', '-', '-', '-', '-', '-', '\n',
                 '|', ' ', ' ', ' ', ' ', '|', '\n',
                 '|', ' ', ' ', ' ', ' ', 'O', '\n',
                 '|', ' ', ' ', ' ', '/', '|', '\\', '\n',
                 '|', ' ', ' ', ' ', '/', ' ', '\\', '\n',
                 '|'};
        private boolean[] display = new boolean[]
                {true, true, true, true, true, true, true,
                 true, true, true, true, true, false, true,
                 true, true, true, true, true, false, true,
                 true, true, true, true, false, false, false, true,
                 true, true, true, true, false, true, false, true,
                 true};
        private final int[] bodyParts = new int[] {12, 19, 25, 26, 27, 33, 35};
        private int wrongGuesses = 0;
        public void displayGallows()
            for (int i = 0; i < gallows.length; i++)
                if (display)
    System.out.print(gallows[i]);
    System.out.println();
    public void wrongGuess()
    if (gameOver()) return;
    display[bodyParts[wrongGuesses]] = true;
    wrongGuesses++;
    public boolean gameOver()
    return wrongGuesses == bodyParts.length;
    thanx heaps for your help guys....

  • Trouble with an Array of ArrayList

    Hi I've created an array of ArrayLists as follows:
    public static ArrayList<BasicSimulationApp>[] clientHashTable = (ArrayList <BasicSimulationApp>[]) new ArrayList<?>[numBins];
    Unfortunately, I keep getting a warning:
    Type safety: The cast from ArrayList<?>[] to ArrayList<BasicSimulationApp>[] is actually checking against the erased type ArrayList<E>[]     
    I've tried a number of different solutions including trying to make clientHashTable of type clientHashTable<?>[] but then I get warnings when I try to use this array. If I try to initialize clientHashTable as new ArrayList<BasicSimulationApp>[numBins] I get an error saying that cannot create a generic array of type <BasicSimulationApp>.
    Can anyone suggest what I can do to get rid of the warning? Apart from turning the warning off of course ;)

    When you are using Generics with arrays you'll always end up with warnings.
    One thing you can try out is to use the latest addition of @SuppressWarnings Annotation Tag.

  • Trouble with array to spreadsheet string

    I am having trouble with the array to spreadsheet string.
    I have a 1-d array of string, the output spreadsheet string never puts a space on the first row, but all others.
    example:
    05:59:29.170    00000101     8        00 00 07 00 0B 0E 0D 0C
     05:59:29.198    00000100     8        00 00 3A 3A 39 39 39 39
     05:59:29.220    00000101     8        00 00 07 00 0B 0E 0D 0C
     05:59:29.248    00000100     8        00 00 39 39 39 39 39 39
    format string is %s and default tab is delimiter.
    this is screwing up my program because of the "scan for string" function can't be used correctly if the spreadsheet string isnt consistent.
    Any suggestions?
    Thanks

    You don't need to use "array to spreadheet string": You could use plain formatting for full control over the output.
    Still, your observation is a bit odd. Could you attach a simple VI that shows the behavior? (Put your input array into a diagram constant).
    LabVIEW Champion . Do more with less code and in less time .

  • HELP. 3 years ago I purchased cs3. I had troubles with registering the serial number and used my university's suite instead, and (stupidly) did not sort it out. I am now wanting to subscribe to the online creative cloud with my cs3 discount. Is there any

    HELP. 3 years ago I purchased cs3. I had troubles with registering the serial number and used my university's suite instead, and (stupidly) did not sort it out. I am now wanting to subscribe to the online creative cloud with my cs3 discount. Is there any way to find / prove that I had purchased cs3 and locate a serial number? On my Adobe account it does not show my purchase of cs3 (I am guessing because of the trouble with registering my serial number). I have moved house 3 times since the purchase and am unable to locate the packaging or disk. Is there any way to prove my purchase without any serial number or showing under my Adobe account? Please help! Thanks

    The CS3 discount offer is only for retail online product, it does not include education or volume license purchases. Refer to Terms and Conditions | Adobe
    To check whether you had retail CS3 purchase, we need proof of purchase as well as serial number, without which the issue can not be resolved.
    Regards
    Rajshree

  • Trouble with sending huge arrays via DataSocket​s.

    Hi,
    I am having trouble sending huge arrays via Data Sockets from my main vi on the server PC to the vi on the client PC.
    To further elaborate, in my main vi program I have created 3 arrays called Array1, Array2 and Array3 on my front Panel. By right clicking the mouse on each set of array and from the pop-up menu I selected Data Operations-> DataSocket Connection and I entered dstp://localhost/Array1 and clicked on Publish to broadcast the data from Array1. Similarly, I did the same for Array2 and Array3.
    Now, in my client vi program I have created three arrays on my front Panel to read (Subscribe) the data from the three arrays broadcasted via DataSockets from the server’s main vi program. To subsc
    ribe the data I did the similar process above and clicked on Subscribe to read the data (of course the IP address of the client PC will be different then the server PC so enter the hosts IP address). Once the data is received in the client arrays, I am using LV2 globals so that I can use these arrays on other sub-vi’s locally (instead of having each sub-vi get data from the server directly).
    I succeeded in doing this with two arrays, however when I added the third array the DataSockets would not work consistently. For example the refresh rate would get slower at times and sometimes 2 out of the 3 arrays would update. I don’t know if I have exceeded the limit on how much data DataSockets can broadcast, but I need to have some mechanism to broadcast 6 arrays (approx. 10000 elements for each array) of double digits precision.
    Has anyone come across this issue? Is there another way of broadcasting data more efficiently then DataSockets?
    I would appreciate any
    help that I can get.
    I have attached the files for this program in the zip file.
    First run the Server main program, testServeMainVI.vi, and then the client program, testClientMainVI.vi.
    Thanks
    Nish
    Attachments:
    beta2.zip ‏70 KB

    DataSocket can be a lossy communication. I like the advice to flatten the data to a string, but another option would be to buffer the communcation. The problem might be that the data is being overwritten on the server faster than it is being read. There is an example of buffered datasocket on NI web page: http://venus.ni.com/stage/we/niepd_web_display.DIS​PLAY_EPD4?p_guid=BA3F9DFED17F62C3E034080020E74861&​p_node=DZ52000_US&p_submitted=N&p_rank=&p_answer=&​p_source=Internal
    Also, I have played with the new built in buffered datasocket in LabVIEW 7.0. It is pretty slick. If buffers the data both on the server and the client side.

  • Trouble with "body" images lining up at the top

    Hi, I am having troubles with the #body style in my web page. I have inserted a table into the #body area and the the body editable region will not line up on the top with the sideBar editable region when I add text and apply my css to it. Can you look at the code and let me know what I am doing wrong? Thanks!
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <!-- TemplateBeginEditable name="doctitle" -->
    <title>Ram Restaurant &amp; Brewery</title>
    <!-- TemplateEndEditable -->
    <meta name="keywords" content="Ram Restaurant, The Ram restaurant, Ram Restaurant and brewpub, Ram Restaurant Group, Ram International" />
    <meta name="description" content="Welcome to The Ram!  Your stomach wants food.  Your tastebuds want beer.  Satisfy them both at the Ram Restaurant & Brewery." />
    <style type="text/css">
    <!--
    body {
    background-color: #333;
    margin: 0 auto;
    padding: 0px;
    margin-left: 0px;
    margin-right: 0px;
    .navbar_center {
    text-align: center;
    -->
    </style>
    <link href="/RamWebsite_NEW/cssstyles.css" rel="stylesheet" type="text/css" />
    <style type="text/css">
    <!--
    body,td,th {
    font-family: Arial, Helvetica, sans-serif;
    color: #F00;
    margin: 0px;
    padding: 0px;
    a:link {
    color: #666;
    text-decoration: none;
    h1 {
    font-size: 36px;
    color: #000;
    h2 {
    font-size: 24px;
    color: #000;
    h3 {
    font-size: 18px;
    color: #000;
    h4 {
    font-size: 12px;
    color: #000;
    a:visited {
    text-decoration: none;
    color: #000;
    a:hover {
    text-decoration: underline;
    a:active {
    text-decoration: none;
    -->
    </style>
    <!--[if lte IE 8]>
    <style type="text/css">
    ul.MenuBarHorizontalul  li ul li ul li.MenuBarHorizontal, ul.MenuBarHorizontal li ul li.MenuBarHorizontal {
    width:100px;
    height:23px;
    </style>
    <![endif]-->
    <script src="/RamWebsite_NEW/SpryAssets/SpryMenuBar.js" type="text/javascript"></script>
    <script type="text/javascript">
    <!--
    function MM_preloadImages() { //v3.0
      var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
        var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
        if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
    function MM_swapImgRestore() { //v3.0
      var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
    function MM_findObj(n, d) { //v4.01
      var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
        d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
      if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
      for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
      if(!x && d.getElementById) x=d.getElementById(n); return x;
    function MM_swapImage() { //v3.0
      var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
       if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
    //-->
    </script>
    <link href="/RamWebsite_NEW/SpryAssets/SpryMenuBarHorizontal.css" rel="stylesheet" type="text/css" />
    <!-- TemplateBeginEditable name="head" -->
    <!-- TemplateEndEditable -->
    </head>
    <body link="#000000" topmargin="0" onload="MM_preloadImages('/RamWebsite_NEW/images/Menu_rollover.jpg','/RamWebsite_NEW/imag es/EventsLink2_rollover.jpg','/RamWebsite_NEW/images/GiftCards_rollover.jpg','/RamWebsite_ NEW/images/BeerLink2_rollover.jpg')">
    <div id="wrapper">
    <div id="header">
        <table width="900" border="0" cellpadding="0" cellspacing="0">
          <tr>
            <th width="200" height="36" rowspan="2" align="center" valign="middle" scope="col"><a href="http://www.theram.com"><img src="/RamWebsite_NEW/images/Ram-Logo-red.gif" alt="Ram Restaurant &amp; Brewery Logo" width="175" height="69" border="0" /></a></th>
            <th width="350" height="50" align="center" valign="middle" scope="col"> </th>
            <th width="200" align="center" valign="middle" scope="col"> </th>
            <th width="150" align="right" valign="middle" scope="col"><a href="http://www.facebook.com/home.php?#!/theramrestaurant?ref=ts"><img src="/RamWebsite_NEW/images/FacebookBox.gif" alt="Becoma a Facebook Fan!" width="40" height="40" border="0" /></a><a href="http://www.twitter.com/theram"><img src="/RamWebsite_NEW/images/TwitterBox.gif" alt="Follow Us on Twitter" width="40" height="40" hspace="30" border="0" /></a></th>
          </tr>
          <tr>
            <th colspan="3" align="right" scope="col"><ul id="MenuBar1" class="MenuBarHorizontal">
              <li><a class="MenuBarItemSubmenu" href="#">MENU</a>
                <ul>
                  <li><a href="#" class="MenuBarItemSubmenu">Idaho</a>
                    <ul>
                      <li><a href="/menus/idaho/boise.shtml">Boise</a></li>
                      <li><a href="/menus/idaho/meridian.shtml">Meridian</a></li>
                    </ul>
                  </li>
                  <li><a href="#" class="MenuBarItemSubmenu">Illinois</a>
                    <ul>
                      <li><a href="/menus/illinois/rosemont.shtml">Rosemont</a></li>
                      <li><a href="/menus/illinois/schaumburg.shtml">Schaumburg</a></li>
                      <li><a href="/menus/illinois/wheeling.shtml">Wheeling</a></li>
                    </ul>
                  </li>
                  <li><a href="#" class="MenuBarItemSubmenu">Indiana</a>
                    <ul>
                      <li><a href="/menus/indiana/fishers.shtml">Fishers</a></li>
                      <li><a href="/menus/indiana/indianapolis.shtml">Indianapolis</a></li>
    </ul>
                  </li>
                  <li><a href="#" class="MenuBarItemSubmenu">Oregon</a>
                    <ul>
                      <li><a href="/menus/oregon/clackamas.shtml">Clackamas</a></li>
                      <li><a href="/menus/oregon/salem.shtml">Salem</a></li>
                    </ul>
                  </li>
                  <li><a href="#" class="MenuBarItemSubmenu">Washington</a>
                    <ul>
                      <li><a href="/menus/washington/kent.shtml">Kent</a></li>
                      <li><a href="/menus/washington/lacey.shtml">Lacey</a></li>
                      <li><a href="/menus/washington/lakewood.shtml">Lakewood</a></li>
                      <li><a href="/menus/washington/puyallup.shtml">Puyallup South Hill Mall</a></li>
                      <li><a href="/menus/washington/puyallup2.shtml">Puyallup Sunrise Village</a></li>
                      <li><a href="/menus/washington/northgate.shtml">Seattle Northgate</a></li>
                      <li><a href="/menus/washington/seattle.shtml">Seattle University Village</a></li>
                      <li><a href="/menus/washington/tacoma.shtml">Tacoma</a></li>
                    </ul>
                  </li>
                </ul>
              </li>
              <li><a href="#" class="MenuBarItemSubmenu">LOCATIONS</a>
                <ul>
                  <li><a href="#" class="MenuBarItemSubmenu">Idaho</a>
                    <ul>
                      <li><a href="/idaho/boiseNew.html">Boise</a></li>
                      <li><a href="/idaho/meridianNew.html">Meridian</a></li>
                    </ul>
                  </li>
                  <li><a href="#" class="MenuBarItemSubmenu">Illinois</a>
                    <ul>
                      <li><a href="/illinois/rosemontNew.html">Rosemont</a></li>
                      <li><a href="/illinois/schaumburgNew.html">Schaumburg</a></li>
                      <li><a href="/illinois/wheelingNew.html">Wheeling</a></li>
                    </ul>
                  </li>
                  <li><a href="#" class="MenuBarItemSubmenu">Indiana</a>
                    <ul>
                      <li><a href="/indiana/fishersNew.html">Fishers</a></li>
                      <li><a href="/indiana/indianapolisNew.html">Indianapolis</a></li>
                    </ul>
                  </li>
                  <li><a href="#" class="MenuBarItemSubmenu">Oregon</a>
                    <ul>
                      <li><a href="/oregon/clackamasNew.html">Clackamas</a></li>
                      <li><a href="/oregon/salemNew.html">Salem</a></li>
                    </ul>
                  </li>
                  <li><a href="#" class="MenuBarItemSubmenu">Washington</a>
                    <ul>
                      <li><a href="/washington/kentNew.html">Kent</a></li>
                      <li><a href="/washington/laceyNew.html">Lacey</a></li>
                      <li><a href="/washington/lakewoodNew.html">Lakewood</a></li>
                      <li><a href="/washington/puyallup-southHill-NEW.html">Puyallup South Hill Mall</a></li>
                      <li><a href="/washington/puyallup-Sunrise-New.html">Puyallup Sunrise Village</a></li>
                      <li><a href="/washington/northgateNew.html">Seattle Northgate</a></li>
                      <li><a href="/washington/seattleNew.html">Seattle University Village</a></li>
                      <li><a href="/washington/tacomaNew.html">Tacoma</a></li>
                    </ul>
                  </li>
                </ul>
              </li>
              <li><a class="MenuBarItemSubmenu" href="#">PROMOS</a>
                <ul>
                  <li><a href="/drink_specials.shtml">Drink Promos</a>              </li>
                  <li><a href="/food_specials.shtml">Food Promos</a></li>
    </ul>
              </li>
              <li><a href="/news.shtml">RAM NEWS</a></li>
              <li><a href="/about.shtml">ABOUT US</a></li>
              <li><a href="#" class="MenuBarItemSubmenu">CONTACT US</a>
                <ul>
                  <li><a href="/contact.shtml">General Info</a></li>
                  <li><a href="/employment.shtml">Careers</a></li>
                  <li><a href="/comments.shtml">Comments</a></li>
                </ul>
              </li>
              <li><a href="/banquets.shtml" class="MenuBarItemSubmenu">BANQUETS</a>
                <ul>
                  <li><a href="/banquets.shtml">Banquets</a></li>
                  <li><a href="/banquets-catering.shtml">Off-Site Catering</a></li>
                </ul>
              </li>
            </ul></th>
          </tr>
          <tr>
            <th colspan="4" align="center" valign="middle" scope="col"><img src="/RamWebsite_NEW/images/redbar.gif" width="900" height="11" /></th>
          </tr>
        </table>
    </div>
    <div id="body">
      <table width="900" border="0" cellpadding="0" cellspacing="0">
        <tr>
          <th height="300" valign="top" scope="col"><table width="900" border="0" cellspacing="0" cellpadding="0">
            <tr>
              <th width="225" align="center" valign="top" bgcolor="#000000" scope="col"><!-- TemplateBeginEditable name="sideBar" -->adfadsfds<!-- TemplateEndEditable --></th>
              <th width="675" align="left" valign="top" bgcolor="#FFFFFF" scope="col"><!-- TemplateBeginEditable name="body" -->
                <p><img src="/images/aboutus2.jpg" width="675" height="300" /></p>
                <p class="foodNameDesc">adfadslkj</p>
              <!-- TemplateEndEditable --></th>
            </tr>
          </table></th>
        </tr>
      </table>
    </div>
    <div id="bottomMenuSubPg">
      <table width="900" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <th width="200" align="center" scope="col"><a href="#" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Menu','','/RamWebsite_NEW/images/Menu_rollover.jpg',1)"><img src="/RamWebsite_NEW/images/Menu.jpg" alt="Menu" name="Menu" width="212" height="125" hspace="6" border="0" id="Menu" /></a></th>
          <th width="200" align="center" scope="col"><a href="#" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Big Horn Beer','','/RamWebsite_NEW/images/BeerLink2_rollover.jpg',1)"><img src="/RamWebsite_NEW/images/BeerLink2.jpg" alt="Big Horn Beer" name="Big Horn Beer" width="212" height="125" hspace="6" border="0" id="Big Horn Beer" /></a></th>
          <th width="200" align="center" scope="col"><a href="#" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Events','','/RamWebsite_NEW/images/EventsLink2_rollover.jpg',1 )"><img src="/RamWebsite_NEW/images/EventsLink2.jpg" alt="Events at the Ram" name="Events" width="212" height="125" hspace="6" border="0" id="Events" /></a></th>
          <th width="200" align="center" scope="col"><a href="#" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Gift Cards','','/RamWebsite_NEW/images/GiftCards_rollover.jpg',1)"><img src="/RamWebsite_NEW/images/GiftCards.jpg" alt="Gift Cards" name="Gift Cards" width="212" height="125" hspace="6" border="0" id="Gift Cards" /></a></th>
        </tr>
      </table>
    </div>
    <div id="bottommenu2"></div>
    <map name="Map" id="Map">
      <area shape="poly" coords="16,103" href="#" />
      <area shape="poly" coords="49,71,102,58,158,73,191,113,180,141,151,161,109,169,65,162,31,141,18,112" href="http://theram.fbmta.com/members/UpdateProfile.aspx?Action=Subscribe&amp;InputSource=W" target="_blank" />
    </map>
    <script type="text/javascript">
    <!--
    var MenuBar1 = new Spry.Widget.MenuBar("MenuBar1", {imgDown:"/RamWebsite_NEW/SpryAssets/SpryMenuBarDownHover.gif", imgRight:"/RamWebsite_NEW/SpryAssets/SpryMenuBarRightHover.gif"});
    //-->
    </script>
    </div>
    </body>
    </html>

    You have your image in the 'body editable region' wrapped in <p></p> tags (paragraph tags). <p> tags have padding and margin set on them by default.
    <p><img src="/images/aboutus2.jpg" width="675" height="300" /></p>
    You can either just remove the <p></p> tags or you can zero out the padding and margin:
    p {
    padding: 0;
    margin: 0;
    Unfortuanately the above will target every paragraph on your page which might not be desirable so I would just remove the <p> tags as it is not necessary to wrap an image in them.
    If you do want to keep the <p> tags then use some inline css to specifically remove the padding and margin on that particular one:
    <p style="padding: 0; margin: 0;"><img src="/images/aboutus2.jpg" width="675" height="300" /></p>

  • Having trouble printing an array of prime numbers that has been resized

    HI, im having trouble with my printPrimeNumbers() method printing the current state of an array, I can only get it to print the original state it was in. The array is inside of a primeNumbers object. I used checkAndResize to resize that array. my printPrimeNumbers method must be void without a parameter. How could i get my PrintPrimeNumbers method to print out a resized array without modifying the parameter? Any ideas.
    Here is my PrimeNumbers class:
    * Created by IntelliJ IDEA.
    * User: Kevin
    * Date: Mar 4, 2007
    * Time: 1:53:56 AM
    * To change this template use File | Settings | File Templates.
    package primes;
    public class PrimeNumbers {
        private boolean [] sieve;
        public PrimeNumbers(int  upper) {
            initializeSieve(upper);
        public int getNthPrime (int n){
        int prime = 0;
        double num;
        if (n >= sieve.length)
            checkAndResize(n + 1);
        for (int i = 0; i < sieve.length; i++){
            if(sieve)
    prime++;
    if (prime == n)
    return i;
    if (prime < n && i == sieve.length -1)
    checkAndResize(2*sieve.length);
    return -1;
    public int getNumberPrimeNumbers(int n){
    int primes = 0;
    for (int i =0 ; i < sieve.length ; i ++){
    if (n > sieve.length){
    checkAndResize(n);
    if(sieve[i])
    primes++;
    else if (sieve[i])
    primes++;
    return primes;
    public int getSieveSize ()
    return sieve.length;
    public boolean isPrime (int n) {
    if (n > sieve.length){
    checkAndResize(n);
    //initializeSieve(n);
    return sieve[n];
    // prints out the prime numbers inside sieve
    public void printPrimeNumbers() {
    int n = 0;
    boolean first = true;
    System.out.print("[");
    for(int i = 0; i < sieve.length - 1; i++){
    n++;
    if(sieve[i] == true && n != sieve.length - 1) {
    if(first) first = false;
    else System.out.print(" ");
    System.out.print(i);
    System.out.println("]");
    // checks length of sieve with N and then resizes sieve if nessecary.
    private void checkAndResize (int n){
    if ((n + 1) >= sieve.length){
    initializeSieve(2*n);
    private void setMultiples (int k) {
    for (int i = 2*k; i < sieve.length; i += k)
    sieve [i] = false;
    private void initializeSieve (int upper){
    if ( upper < 2)
    sieve = new boolean [2];
    else
    sieve = new boolean [upper + 1];
    sieve[0] = false;
    sieve[1] = false;
    for (int i =2 ; i< sieve.length; i ++ )
    sieve[i] = true;
    int bound = (int) Math.ceil(Math.sqrt(sieve.length));
    for (int i = 2 ; i < bound ; i ++)
    if (sieve[i])
    setMultiples (i);
    private String booleanToString (boolean value)
    if (value)
    return "T";
    else
    return "F";
    public String toString (){
    StringBuffer buf = new StringBuffer("[");
    for (int i = 0; i < sieve.length -1 ; i ++)
    buf.append(booleanToString (sieve[i]) + " " );
    buf.append(booleanToString (sieve[sieve.length -1]) + "]");
    return buf.toString();
    here is the client code
            PrimeNumbers test = new PrimeNumbers(16);
            System.out.println(test);
            System.out.println("There are " + test.getNumberPrimeNumbers(16) +
                    " prime nummbers in the sieve from 1 to 15. \n");
            System.out.println("There are " + test.getNumberPrimeNumbers(26) +
                    "  prime numbers in the resized sieve from 1 to 25.");
            System.out.println("\nThe first 25 prime numbers are:");// makes sense why it doesnt work
            test.printPrimeNumbers();
            System.out.println("\nThe 13th prime number is: " + test.getNthPrime(13));
            System.out.println();
            System.out.println("The number 3001 is prime:  " + test.isPrime(3001));do you see how my methods resized it?
    here is the output:
    [F F T T F T F T F F F T F T F F F]
    There are 6 prime nummbers in the sieve from 1 to 15.
    There are 15 prime numbers in the resized sieve from 1 to 25.
    The first 25 prime numbers are:
    [2 3 5 7 11 13 17 19 23 29 31 37 41 43 47]// this is only the first 15 elements
    The 13th prime number is: 41
    The number 3001 is prime: true
    thanks for taking your time to look at this

    What's the problem?
    You say that there are 15 prime numbers in the range 1-25. Your method printPrimeNumbers() prints the last calculated primes, and that is 15. So the program works.

  • I am really in trouble with AP Div-How do I fix it on the web?

    Hi,
    I am really in trouble with my website. I have added some pictures and text on top of Fireworks Image and have published it on the website.
    But the concern is, when I zoom in & zoom out, I can see the previous text on the screen and also the picture and texts I have added using Ap Div  tag are scattered moving all to the left when I zoom out. Can someone help me how to fix this in one particular place so that it doesn't move when I zoom in or zoom out!!! I am using Adobe Dreamweaver CS3, if this will help.
    Appreciate your sincere help on this.
    Thanks in advance.

    Frankly, there's a lot that is wrong with that page:
    1. Most of your content is in the images - this means that you will get very poor search engine ranking
    2. Your extensive use of absolute positioning for layout - this means that when you enlarge the text size in the browser, you will have overflow problems on the page (for example, the terrible problems at the bottom of the page)
    3. You have used tables for layout - this is because of your use of Fireworks to create the HTML
    Each of these problems is solvable but none of them are solvable easily without a redesign of the page. A web page should be built from the top down, stacking content containers (i.e., <div>, <section>, <article>, <aside>, etc.) vertically or floating them horizontally or both. These containers would be loaded with the text content of the page, and images would be used only for cosmetic appearance. Using CSS to style/locate the content will allow you to completely move away from tables for layout. Most typical pages can be created without the use of absolute positioning which should be used only for special purposes, not for layout of the page elements.

  • Having trouble with image processor...help please!

    HI there...First off I just bought a new iMac and haven't a clue what I'm doing so my problem could be related to that.  While I'm waiting for Adobe to transfer over my platform I downloaded the trial of CS5 Extended to get me started.  I'm having trouble with the image processor...I choose file/scripts/image processor...the dialog box comes up and I choose use open files and then try and choose the folder I want to save them in.  I choose my folder and hit run and it keeps telling me specify folder destination.  I can't for the life of me figure this out...what am I doing wrong?  It always worked fine for me on my PC and CS3.  I can't handle saving each image individually in the new folder...
    Thanks!!

    I haven't renamed anything as far as I know.  I made a new folder when I hit Folder option and it's highlighted as well as the path shows up in the processor box.  Just when I choose run it tells me to specify a folder.  The only thing I can think of is that maybe something messed up b/c I'm copied the files and folders over from my PC but it let me save as on the mac.  Also the folder I'm choosing to put them in is on the Mac harddrive.  IDK...

  • I am postin a message but no one seems to answer it . Plse I am having trouble with adobe 5 and I wr

    I am hjaving trouble with adobe 5 not compatable with my computer so how do I get rid of it and up grade  to a newer verson, hopfully a free one

    There is no application named Adobe 5, so you might have to provide the correct name for the application.  If it happens to be Creative Suite 5 (CS5) there is a good chance it is compatible with your computer but you might have to install it in a compatibility mode.  If you want to remove it you should first deactivate it. YOu might also do well to use the Creative Suite Cleaner Tool...
    Adobe Creative Suite Cleaner Tool
    helps resolve installation problems for CS3 thru CS6 and for Creative Cloud
    http://www.adobe.com/support/contact/cscleanertool.html
    As far as I know there are no free upgrades, especially if the reason would be lack of compatibility.  It might be true if you were to have purchased one version when the next version was just about to be released, but CS5 is well beyond being considered for that.  Software is not freely upgraded to match newer machines - that's part of life.
    Just in case... if the lack of compatibility is due to your machine not meeting the tech specs of CS5, then it will most likely be true that your machine does not meet the tech specs of anything newer than that.

Maybe you are looking for

  • "SSO" for non-sap web application using SAPGUI to browse?

    I have a web application (non SAP) and the user base are also SAP users in an ABAP system. To strengthen the authentication in the web app, I wanted to implement SSO  authentication as we pity the users for having to remember so many strong pw's and

  • How do I clear the "save as" dropdown menu settings?

    When saving a file which I am downloading, I get a set of locations in the drop down menu after instantiating the save as prompt. I want to clear that information for several reasons, not the least of which is that many of the locations listed are no

  • Email Billing document as PDF Attachment while saving from VF01/02

    Hi, Can anybody suggest if there is any BADI/User Exit/Configuration exists in order to email Billing document as a PDF attachment while saving from VF01 or VF02? We need to trigger this while saving the Output type say, VF02 GOTO -> HEADER -> OUTPUT

  • Resolution of n8

    i purchased nokia n8 one month back, im new to nokia. this is my first nokia phone. from the date of purchase im getting a doubt about resolution of n8. it is 360x640, is it sufficient for a 3.5" screen. i previously used samsung jet. it has 480x800

  • Drag and drop operation resulted in files gone missing

    I would really appreciate some help as I have lost about 80 files. Here's what happened: I had a big folder of several hundred files and I was moving those files– photographs – into subfolders.I selected the photo in bridge and then used a drag and d