Will You Help me with my Day Old Mac Mini?

As I was setting up mac mini and connecting to trackpad, I turned the mac mini off so i could set it up later because i had companny coming.  Then when I turned it on, all the personal and acoount, user information was skipped so when I went to settings to enter that it said I needed a password which I never set up.  Now I cannot use my newly bought mac mini i bought earlier today.
Please Help Me, I do not know what to do.  I am thinking about taking it back to apple.
ALso another Question
CAn you return a mac mini that has been pirchased within a few days to get a new fresh one to start over on?

I'm sure Apple will help you on this, but try booting it up holding CMD + r keys to get the Rstore options.

Similar Messages

  • Will you help me with troubleshooting why my applications are not loading and why I'm getting so many fork failures?

    I have an iMac, 2.5Ghz i5, 12GB RAM, OSX 10.8.4. Things were working fine, but recently I had to install Java (I had to avert my eyes) because it was needed to use a certain web site. This seemed to be the beginning of my problems, but they were easily fixed by repairing permissions. I typically leave my iMac running until recently I noticed applications weren't loading, but by repairing permissions everything seemed to return to normal.
    Then I had to use tech support from another company for a diffferent issue. The techy used GoToAssist Customer so he could access my desktop remotely. The problems began to show up more often. Lots of fork failures and spinning beach balls, and applications weren't launching. Consequently, I logged into a guest account to see if the problems existed in that account - and they didn't, everything worked fine, like a new machine. I have repaired permissions until I'm blue in the face - I even resorted to using Onyx, but that didn't help.
    I have since removed Java (I wonder if I should remove GoToAssist), but the problems seem to be getting worse (not better). Before I resort to performing a clean re-install of Mountail Lion (and the headaches that it causes) I thought I would reach out to the community to see if anyone has any suggestions. I have got to do something fairly quickly, I need my machine working tomorrow. I wil be so grateful if you can help me. Luckily, I have ML on a thumb drive so a clean install won't take so long, but I also use Windows 7 with Parallels, which makes it a pretty major hassle. Does anyone have any suggestions?

    You can try these steps in case of issues with web pages:
    Reload web page(s) and bypass the cache to refresh possibly outdated or corrupted files.
    *Hold down the Shift key and left-click the Reload button
    *Press "Ctrl + F5" or press "Ctrl + Shift + R" (Windows,Linux)
    *Press "Command + Shift + R" (Mac)
    Clear the cache and cookies only from websites that cause problems.
    "Clear the Cache":
    *Firefox/Tools > Options > Advanced > Network > Cached Web Content: "Clear Now"
    "Remove Cookies" from sites causing problems:
    *Firefox/Tools > Options > Privacy > Cookies: "Show Cookies"
    Start Firefox in <u>[[Safe Mode|Safe Mode]]</u> to check if one of the extensions (Firefox/Firefox/Tools > Add-ons > Extensions) or if hardware acceleration is causing the problem (switch to the DEFAULT theme: Firefox/Firefox/Tools > Add-ons > Appearance).
    *Do NOT click the Reset button on the Safe Mode start window.
    *https://support.mozilla.org/kb/Safe+Mode
    *https://support.mozilla.org/kb/Troubleshooting+extensions+and+themes

  • Do you have experience with FCE on a mac mini?

    Just looking for any comments on experience using a mini for FCE and importing AVCHD files.
    I've got a Mini that I maxed out the ram and dropped in a 7200 rpm drive. I also have an external drive (usb) for my movie files - will go with a firewire drive soon. My camera is a Canon HG10. I'm only doing small videos so budget is my biggest concern.
    I've been using the old iMovie HD (the quality of import/conversion when I tried iMovie08 is really bad - and don't like using it anyways.) I found that 4Media Video Converter has done the best conversions so far (Voltiac dies if the file is too big). But would like better quality - would FCE handle that on this system?
    Thanks in advance,
    Neil

    Hello, I think you're out of luck with the toolbar, but not on 10.9 to check right now, you can change the minimum font size used in Safari Prefereces for web pages.
    Perhaps Zoom will work for you...
    http://support.apple.com/kb/PH14358

  • What will i do..there is a message show, "your device in not more eligible to create a free i cloud acount"..and when i try a new one it ask an account number, but i dont have...can you help me with this issue..

    What will i do..there is a message show, "your device in not more eligible to create a free i cloud acount"..and when i try a new one it ask an account number, but i dont have...can you help me with this issue..?
    I try also my old icloud user but its not recognizing the accoun...

    What will i do..there is a message show, "your device in not more eligible to create a free i cloud acount"..and when i try a new one it ask an account number, but i dont have...can you help me with this issue..?
    I try also my old icloud user but its not recognizing the accoun...

  • Hi i have i phone 4s and ios 7.0.2 is updated and problem is wifi and last 3 days i have  problem anbout wifi and im connected  and its automatic turn off and then on ...... will you help me

    hi i have i phone 4s and ios 7.0.2 is updated and problem is wifi and last 3 days i have  problem about wifi and im connected wifi and its automatic turn off and then on ...... will you help me

    Apple guys are deleting posts. I have found my posts have been deleted. Apple should MUST let us downgrade at least to previous release from current which was working fine.

  • Just bought a new Canon Vixia HF R300.  It looks like I have basically two recording modes--either AVCHD or MP4.  I have a year old Mac Mini on Lion with increased ram.  I edit on iMovie and upload to You Tube.  Which recording mode would be best?

    Hi...
    I just bought a Canon Vixia HF R300 camcorder.  It looks like it gives me a choice of two recording modes AVCHD or MP4.  I will be uploading onto a year old Mac Mini with the Lion Operating system and increased ram.   I will be editing in iMovie '11 then uploading to You Tube.  Which recording mode should I use?  Obviously I'd like to get the best quality but I also want it to show well on You Tube.   What do you think?  Thanks for the help.  Bill

    Hi
    What program can you use to convert AVCHD to a DVD format?
    Share to File (in iMovie) - AND AS 480p - NOT Higher as DownScaling will be done badly.
    Use this file in iDVD or Roxio Toast™ or what DVD Authoring program You've got.
    To make a VIDEO-DVD You must use a DVD Authoring program - to get the right compression format AND Structure - It is a MUST.
    There are free alternatives - but resulting DVD hasve been far from what quality iDVD (and Toast™) will deliver.
    To get best possibly DVD - also this counts.
    - DVD brand used - I only Verbatim
    - DVD type used - I only DVD-R Single layer (4.7Gb)
    (DVD+R works for many and DVD-R/W usually don't work OK and Double Layer also are a problem to it self)
    - BURN SPEED - I set this as low possibly (usually x2)
    - Free Space on Start-Up Hard Disk - MATTERS - I never go less than 25Gb
    Good Luck
    Yours Bengt W

  • Hello, we have both Creative Cloud and Creative Cloud for teams. Can you help me with the difference and if i need to have both?

    Hello, we have both Creative Cloud membership and Creative Cloud for team. Can you help me with the difference and if i need to have both? We have 9 employees that are using it. Just not sure if i'm paying for something i don't need.
    Thank you

    Please refer to Creative Cloud Help | Creative Cloud / Common Questions
    CC is for retail use with 20 GB of storage space, CCT is where number of seats are purchased & assigned by one program admin where each seat gets 100GB of storage space.
    You can not have both the CC & team in one account as it will only provide you added storage space of 120 GB but you can activate the CC any of them or either of them twice as CC is based on Adobe ID.
    Regards
    Rajshree

  • Will Apple help us with ATT rate hikes? Who do I contact?

    Just a few months ago - and at the time I entered into my 2 year contract - unlimited textings was avaialble for less that 5 dollars more. But that is now gone and what has taken its place is just Dick Channey crazy!
    Wasnt the whole point of APPLE insisting that phone plans all come with unlimited internet so that this would encourage the owners to fully integrate the iphone in to their daily lives? Does having huge rate increases in texting help that cause ?
    MY QUESTION TO APPLE and its user forums - WHO do I contact at apple or at ATT for help on this issue??
    Thats what I want in a nutshell. If you want, I can tell ya more.
    Harry
    iphone, ipod and shuffle owner
    MORE is this...........................
    I do understand the nature of big business and partnerships etc.
    I do understand that Apple would like to not be involved in disputes between ATT and its customers.
    I GET THAT. But can Apple help me anyway just for the reason that I WANT TO KEEP MY IPHONE?!?!?
    ATT has implemented monsterous rate hikes and LIMITATIONS on package combinations so that iphone users will pay as much or more for Texting than they do for unlimited internet.
    We had to live with unlimited internet not including unlimited texting. OK fine, thats how it was when we signed up and you have to take it or leave it. But now with the new changes in rates - here is what the iphone user has as their options.
    200 included texts for free
    or
    $5 - get 200 more - 400 texts total
    or
    THE NEXT OPTION - $20 MORE, for not unlimited but 1500 texts.
    Does having to keep an eye on your text totals or paying at least $85 / month sound like the vision that apple wanted for the iphone users?
    if it doesnt, WILL YOU HELP US?

    I didnt forget that - its I dont know that statement to be true.
    I have been with ATT since Cingular and I've had internet,text and MMS combo packages for some time now; that Includes shopping around for the right phone and plans combo. And I know for a fact that there were MANY combos of unlimited and they were FAR from 50 bucks.
    There certainly might be a webpage or two with some ancient pricing plans offered. And I am sure that any one of those would be superceeded by another new price offer on the same plan.
    so I didnt forget that; I knew it to be not on point.

  • Will Apple help me with this issue?

    Dear Sir or Madam,
    I am a student in China, I really need your help, my iphone now problems bothers me! HELP ME PLEASE!!!
    As I bought my iPhone 4s(16GB,White) in the USA from Sprint, full price with tax,  unlocked ,it was excepted to be a global phone. But now I come across with some problems in China  using local carrier.Now I am in China, not the normal use of the phone, I rely on odd jobs to earn, very not easy, English is not my mother tongue, maybe there are many grammatical mistakes, I hope you'll forgive me! Mobile phone can not be used normally I am very sad, I can not contact the parents and friends, can not let them worry about me, I've tried all means, including the upgrade to 6.1, but still can not solve the problem, I think maybe I am in China, so can not be used normally, at this moment I am very anxious, because of the time difference, it is later I can send mail, you can see it, please help me, a Chinese student's request!
    I tried all the possible solutions from the Internet, and the Official solution offered by Apple (http://support.apple.com/kb/TS4459), but it doesn't seem to work.
    Will Apple help me with this issue? Please do.THANK YOU VERY MUCH!!!

    We are not Apple, and Apple does not unlock phones. Sprint will unlock phones, but you have to qualify. One of the qualifications is to have been a customer in good standing for a period of time. You can check their website for what that is. After that, they can unlock the GSM side of the phone for International use, that is it. If you are on a CDMA carrier, then it cannot be unlocked. Are you trying to use a local SIM card in China?
    Your only option is to contact Sprint to see if you qualify for an unlock. Only they can unlock it. Sprint is one of the poorest choices to take to another country.

  • HT2801 I understand there is a way to use my Super Drive with my PC.  However, it requires a System OS Disk.  Which I never received.  Can you help me with this?

    I understand there is a way to use my Super Drive with my PC.  However, it requires a System OS Disk.  Which I never received.  Can you help me with this?

    Rick6812 wrote:
      I'm using Windows 8.1. 
    I do not know what you mean by a Windows 8.1.  Please clarify.
    The Apple superdrive is designed to be used with the following Macs.
    It will not work with any other Mac unless you perform this modification;
    http://www.tuaw.com/2012/04/02/use-the-macbook-air-superdrive-with-any-almost-ma c/
    Are you trying to get it to work with a PC? 
    Ciao.

  • HT5787 can you help me with change the security question

    can you help me with change the security question

    If you have a rescue email address (which is not the same thing as an alternate email address) set up on your account then the steps half-way down this page give you a reset link on your account : http://support.apple.com/kb/HT5312
    If you don't have a rescue email address (you won't be able to add one until you can answer your questions) then you will need to contact iTunes Support / Apple in your country to get the questions reset.
    Contacting Apple about account security : http://support.apple.com/kb/HT5699
    When they've been reset (and if you don't already have a rescue email address) you can then use the steps half-way down the HT5312 link above to add a rescue email address for potential future use

  • HT201356 hi , i forget my question and answer for my apple id , and i try to restore it but i cannot , can you help me with that thanks

    hi , i forget my question and answer for my apple id , and i try to restore it but i cannot , can you help me with that thanks

    You will have to try to recover the password or contact Apple for help.
    https://iforgot.apple.com/
    IF you still cannot recover it, contact Apple according to the instructions here.
    Apple ID: Contacting Apple for help with Apple ID account security - Apple Support

  • Will you help me activate my new phone?

    Will you help me activate my new phone under my correct phone number?

    Michelle you are not understanding.
    1) What phone do you have?
    2) What phone does your daughter have?
    3) Are they basic phones?
    4) Are they Androids?
    5) Are they Apple phones?
    Just what devices do you both have? Make and Model numbers, Names of the devices? I am not telling you to call anyone right now!
    I said go into a Verizon Wireless Corporate Store. Since you stated you cannot make phone calls.
    Borrow a phone and call if necessary. Use a pay phone if there is one available, use a friends or neighbors phone.
    We have used these types of communications devices long before cell phones came into use.
    If the phones are 4G LTE and both have sim cards in the devices you can swap them out and each phone should work.
    I cannot do it for you over the internet with the little to no information you are giving.

  • Can you help me with mouse pressed method please?

    hi
    can you help me with my problem please, player label doesn't show up in the applet and the draw string method it doesn't draw any strings like X or O for the game I don't know what is the problem maybe it is with MousePressed method which is in Board class. I tried to write the code of the location many times I'm not sure if the problem comes from there.
    there is no error in my code, but it doesn't work.
    this is class Board which has the mouseListener
    class Board extends JPanel  implements MouseListener, MouseMotionListener
        private JLabel playerlabel; 
         private boolean play;
         private boolean start;
        private int turn; 
        private Square squares[][];
      private Player myplayer[][];
         public Board()
              setBackground( Color.WHITE );
              playerlabel = new JLabel( "X player first" );
              //playerlabel.setLayout(null);
         //     playerlabel.setLocation(500,500);
              add( playerlabel );
              play = true;
              turn = 1;
             squares = new Square[3][3];
             myplayer = new Player[3][3];
             int x = 40;
              int y = 40;
              for (int i=0; i<3; i++){
                   x = 40;
                   for (int j=0; j<3; j++){
                        Square s = new Square( x,y );
                        squares[i][j] = s;
                        x +=50;
                   y +=50;
                this.addMouseListener(this);
            this.addMouseMotionListener(this);
          public void mouseClicked( MouseEvent event ){}
          public void mouseMoved( MouseEvent event ){}
          public void mouseEntered( MouseEvent event ){}
          public void mouseExited( MouseEvent event ){}
          public void mousePressed( MouseEvent event )
          {int xPos = event.getX();
                  int yPos = event.getY();
                    if(play && turn ==1){
                    for (int i=0; i<3; i++){
                        for (int j=0; j<3; j++){
                             int x = squares[i][j].getX();
                             int y = squares[i][j].getY();
                             if(xPos> x && xPos<x+40&& yPos> y && yPos<y+40){
                                  if( squares[i][j].getOccupied() ==0 ){
                                       String ptext;
                                       ptext = "X";
                                       Player p = new Player(x, y,ptext);
                                       myplayer[i][j] = p;
                                       squares[i][j].setOccupied(1);
                                       playerlabel.setText( "O Player Turn" );
                                       turn = 2;
                                       repaint();
                                       Win();
                                  else{
                                       turn = 2;
                                       playerlabel.setText( "O Player Turn" );
                                       repaint();
              if ( play && turn ==2 )
    for (int i=0; i<3; i++){
                        for (int j=0; j<3; j++){
                             int x = squares[i][j].getX();
                             int y = squares[i][j].getY();
                             if(xPos> x && xPos<x+40&& yPos> y && yPos<y+40){
                                  if( squares[i][j].getOccupied() ==0 ){
                                       String ptext;
                                       ptext = "O";
                                       Player p = new Player(x, y,ptext);
                                       myplayer[i][j] = p;
                                       squares[i][j].setOccupied(2);
                                       playerlabel.setText( "X Player Turn" );
                                       turn = 1;
                                       repaint();
                                       Win();
                                  else{
                                       turn = 1;
                                       playerlabel.setText( "X Player Turn" );
                                       repaint();
          public void mouseReleased( MouseEvent event )
          public void mouseDragged( MouseEvent event )
         public void Win(){
              if(squares[0][0].getOccupied() == squares[0][1].getOccupied() &&squares[0][1].getOccupied()==squares[0][2].getOccupied() &&squares[0][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else if (squares[1][0].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[1][2].getOccupied() &&squares[1][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else      if(squares[2][0].getOccupied() == squares[2][1].getOccupied() &&squares[2][1].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
                   if(squares[0][0].getOccupied() == squares[0][1].getOccupied() &&squares[0][1].getOccupied()==squares[0][2].getOccupied() &&squares[0][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else if (squares[1][0].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[1][2].getOccupied() &&squares[1][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else      if(squares[2][0].getOccupied() == squares[2][1].getOccupied() &&squares[2][1].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              //Vertically win
               if (squares[0][0].getOccupied() == squares[1][0].getOccupied() &&squares[1][0].getOccupied()==squares[2][0].getOccupied() &&squares[2][0].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else if (squares[0][1].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][1].getOccupied() &&squares[2][1].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else      if(squares[0][2].getOccupied() == squares[1][2].getOccupied() &&squares[1][2].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
               if (squares[0][0].getOccupied() == squares[1][0].getOccupied() &&squares[1][0].getOccupied()==squares[2][0].getOccupied() &&squares[2][0].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else if (squares[0][1].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][1].getOccupied() &&squares[2][1].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else      if(squares[0][2].getOccupied() == squares[1][2].getOccupied() &&squares[1][2].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              //Diagonal win
                    if (squares[0][0].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else if (squares[0][2].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][0].getOccupied() &&squares[2][0].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
               if (squares[0][0].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else if (squares[0][2].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][0].getOccupied() &&squares[2][0].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
         }//end win
    public void setTurn(int t)
              turn = t;
              playerlabel.setText( "X Player Plays First" );
         public void paintComponent( Graphics g )
               super.paintComponent( g );
               this.setBackground( Color.WHITE );
              for (int i=0; i<3; i++){
                   for (int j=0; j<3; j++){
                        g.setColor( Color.BLACK );
                         g.drawRect( squares[i][j].getX(), squares[i][j].getY(), 50, 50 );     
               for (int i=0; i<3; i++){
                   for (int j=0; j<3; j++){
                         myplayer[i][j].draw(g);     
            //End of paintComponent   
    }and this is the whole code of my program.
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import java.util.*;
    class Player{
         private int xCoordinate;
         private int yCoordinate;
        private String playerText;
      public   Player(int x, int y, String t)
            playerText = t;
            xCoordinate = x;
            yCoordinate = y;
        public void draw(Graphics g)
               g.drawString(playerText,  xCoordinate, yCoordinate);
         public void SetText(String t)
         { playerText = t;
    }//end player
    class Square
         private int x;
         private int y;
         private int occupied;
         public Square(int x1, int y1)
              x = x1;
              y= y1;
              occupied = 0;
         public void setX(int x1)
              x = x1;
         public int getX()
              return x;
         public void setY(int y1)
              y = y1;
         public int getY()
              return y;
         public void setOccupied(int o)
              occupied = o;
         public int getOccupied()
              return occupied;
    public class TicTac extends JApplet implements ActionListener
    { private JPanel panel;
         private JButton newgame;
         private Board B;
         public void init()
              B = new Board();
              add( B, BorderLayout.CENTER );
              panel = new JPanel();
               newgame = new JButton( "New Game" );
               panel.add( newgame);
               add( panel, BorderLayout.SOUTH );
               newgame.addActionListener(this);
              public void actionPerformed( ActionEvent ev)
               {     Object source = ev.getSource();
         if (source == newgame)
                    {remove(B);
                   repaint();
              B = new Board();
                   add( B, BorderLayout.CENTER );
         B.setTurn(1);
                   repaint();
                   validate();
            }//end class TicTac
    class Board extends JPanel  implements MouseListener, MouseMotionListener
        private JLabel playerlabel; 
         private boolean play;
         private boolean start;
        private int turn; 
        private Square squares[][];
      private Player myplayer[][];
         public Board()
              setBackground( Color.WHITE );
              playerlabel = new JLabel( "X player first" );
              //playerlabel.setLayout(null);
         //     playerlabel.setLocation(500,500);
              add( playerlabel );
              play = true;
              turn = 1;
             squares = new Square[3][3];
             myplayer = new Player[3][3];
             int x = 40;
              int y = 40;
              for (int i=0; i<3; i++){
                   x = 40;
                   for (int j=0; j<3; j++){
                        Square s = new Square( x,y );
                        squares[i][j] = s;
                        x +=50;
                   y +=50;
                this.addMouseListener(this);
            this.addMouseMotionListener(this);
          public void mouseClicked( MouseEvent event ){}
          public void mouseMoved( MouseEvent event ){}
          public void mouseEntered( MouseEvent event ){}
          public void mouseExited( MouseEvent event ){}
          public void mousePressed( MouseEvent event )
          {int xPos = event.getX();
                  int yPos = event.getY();
                    if(play && turn ==1){
                    for (int i=0; i<3; i++){
                        for (int j=0; j<3; j++){
                             int x = squares[i][j].getX();
                             int y = squares[i][j].getY();
                             if(xPos> x && xPos<x+40&& yPos> y && yPos<y+40){
                                  if( squares[i][j].getOccupied() ==0 ){
                                       String ptext;
                                       ptext = "X";
                                       Player p = new Player(x, y,ptext);
                                       myplayer[i][j] = p;
                                       squares[i][j].setOccupied(1);
                                       playerlabel.setText( "O Player Turn" );
                                       turn = 2;
                                       repaint();
                                       Win();
                                  else{
                                       turn = 2;
                                       playerlabel.setText( "O Player Turn" );
                                       repaint();
              if ( play && turn ==2 )
    for (int i=0; i<3; i++){
                        for (int j=0; j<3; j++){
                             int x = squares[i][j].getX();
                             int y = squares[i][j].getY();
                             if(xPos> x && xPos<x+40&& yPos> y && yPos<y+40){
                                  if( squares[i][j].getOccupied() ==0 ){
                                       String ptext;
                                       ptext = "O";
                                       Player p = new Player(x, y,ptext);
                                       myplayer[i][j] = p;
                                       squares[i][j].setOccupied(2);
                                       playerlabel.setText( "X Player Turn" );
                                       turn = 1;
                                       repaint();
                                       Win();
                                  else{
                                       turn = 1;
                                       playerlabel.setText( "X Player Turn" );
                                       repaint();
          public void mouseReleased( MouseEvent event )
          public void mouseDragged( MouseEvent event )
         public void Win(){
              if(squares[0][0].getOccupied() == squares[0][1].getOccupied() &&squares[0][1].getOccupied()==squares[0][2].getOccupied() &&squares[0][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else if (squares[1][0].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[1][2].getOccupied() &&squares[1][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else      if(squares[2][0].getOccupied() == squares[2][1].getOccupied() &&squares[2][1].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
                   if(squares[0][0].getOccupied() == squares[0][1].getOccupied() &&squares[0][1].getOccupied()==squares[0][2].getOccupied() &&squares[0][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else if (squares[1][0].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[1][2].getOccupied() &&squares[1][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else      if(squares[2][0].getOccupied() == squares[2][1].getOccupied() &&squares[2][1].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              //Vertically win
               if (squares[0][0].getOccupied() == squares[1][0].getOccupied() &&squares[1][0].getOccupied()==squares[2][0].getOccupied() &&squares[2][0].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else if (squares[0][1].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][1].getOccupied() &&squares[2][1].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else      if(squares[0][2].getOccupied() == squares[1][2].getOccupied() &&squares[1][2].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
               if (squares[0][0].getOccupied() == squares[1][0].getOccupied() &&squares[1][0].getOccupied()==squares[2][0].getOccupied() &&squares[2][0].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else if (squares[0][1].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][1].getOccupied() &&squares[2][1].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else      if(squares[0][2].getOccupied() == squares[1][2].getOccupied() &&squares[1][2].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              //Diagonal win
                    if (squares[0][0].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
              else if (squares[0][2].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][0].getOccupied() &&squares[2][0].getOccupied() == 1)
              {playerlabel.setText("Player 1 X WON THE GAME!");
              play =false;          }
               if (squares[0][0].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][2].getOccupied() &&squares[2][2].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
              else if (squares[0][2].getOccupied() == squares[1][1].getOccupied() &&squares[1][1].getOccupied()==squares[2][0].getOccupied() &&squares[2][0].getOccupied() == 2)
              {playerlabel.setText("Player 2 O WON THE GAME!");
              play =false;          }
         }//end win
    public void setTurn(int t)
              turn = t;
              playerlabel.setText( "X Player Plays First" );
         public void paintComponent( Graphics g )
               super.paintComponent( g );
               this.setBackground( Color.WHITE );
              for (int i=0; i<3; i++){
                   for (int j=0; j<3; j++){
                        g.setColor( Color.BLACK );
                         g.drawRect( squares[i][j].getX(), squares[i][j].getY(), 50, 50 );     
               for (int i=0; i<3; i++){
                   for (int j=0; j<3; j++){
                         myplayer[i][j].draw(g);     
            //End of paintComponent   
            Edited by: mshadows on May 18, 2008 7:53 AM

    I was playing with this a little bit and came up with this game model, something that I'm sure can be improved upon greatly:
    TttXO.java
    an enum to encapsulate X vs O. I could use a boolean here since it has 2 states, but this seems more intuitive to me
    package dy08.m05.ttt;
    * tic tac toe encapsulation of X vs O
    * @author Pete
    public enum TttXO
        X, O
    }TttCell.java
    encapsulates an individual cell in the tictactoe grid.
    package dy08.m05.ttt;
    * Tic Tac Toe Game cell
    * can be occupied or not
    * can hold TttXO X or O or null 
    * @author Pete
    public class TttCell
        private boolean occupied = false;
        private TttXO xo = null;
        public TttCell()
         * sets a Square for either x or o
         * @param TttXO
         * @return true if successful, false if already occupied
        public boolean setXO(TttXO xo)
            if (occupied)
                return false;
            else
                occupied = true;
                this.xo = xo;
                return true;
        public void reset()
            occupied = false;
            xo = null;
        public boolean isOccupied()
            return occupied;
        public TttXO getXO()
            return xo;
        // used to test and debug the class
        public String toString()
            if (occupied)
                return xo.toString();
            else
                return "-";
    package dy08.m05.ttt;
    * Tic Tac Toe game model
    * @author Pete
    public class TttGameModel
        private TttCell[][] cellGrid = new TttCell[3][3];
        private boolean xTurn = true;
        private boolean win = false;
        public TttGameModel()
            for (int i = 0; i < cellGrid.length; i++)
                for (int j = 0; j < cellGrid.length; j++)
    cellGrid[i][j] = new TttCell();
    public void reset()
    xTurn = true;
    win = false;
    for (int i = 0; i < cellGrid.length; i++)
    for (int j = 0; j < cellGrid[i].length; j++)
    cellGrid[i][j].reset();
    public boolean isXTurn()
    return xTurn;
    public boolean isWin()
    return win;
    * @param row
    * @param col
    * @return true if valid move, false if game already over or cell occupied
    public boolean takeTurn(int col, int row)
    TttXO currentXO = TttXO.O;
    TttCell cell = cellGrid[row][col];
    if (win)
    return false;
    if (cell.isOccupied())
    return false;
    if (xTurn)
    currentXO = TttXO.X;
    cell.setXO(currentXO);
    win = checkWin(col, row, currentXO);
    xTurn = !xTurn; // toggle xturn
    return true;
    public boolean checkWin(int col, int row, TttXO xo)
    boolean win = false;
    // first rows and columns
    boolean temp = true;
    for (int i = 0; i < 3; i++)
    temp &= cellGrid[row][i].getXO() == xo;
    win |= temp;
    temp = true;
    for (int i = 0; i < 3; i++)
    temp &= cellGrid[i][col].getXO() == xo;
    win |= temp;
    if (row == col) // if slash diagonal
    temp = true;
    for (int i = 0; i < 3; i++)
    temp &= cellGrid[i][i].getXO() == xo;
    win |= temp;
    if (row + col == 2) // if backslash diagonal
    temp = true;
    for (int i = 0; i < 3; i++)
    temp &= cellGrid[i][2 - i].getXO() == xo;
    win |= temp;
    return win;
    // used to test and debug the class
    public String toString()
    StringBuilder sb = new StringBuilder();
    for (int i = 0; i < cellGrid.length; i++)
    for (int j = 0; j < cellGrid[i].length; j++)
    sb.append(cellGrid[i][j] + " ");
    sb.append("\n");
    if (win)
    sb.append("win! Game over");
    else
    sb.append("No winner yet");
    return sb.toString();
    // test the class
    public static void main(String[] args)
    TttGameModel model = new TttGameModel();
    checkMove(model, 0, 0);
    checkMove(model, 1, 0);
    checkMove(model, 1, 1);
    checkMove(model, 2, 0);
    checkMove(model, 1, 0); // bad move
    checkMove(model, 2, 2);
    // to test the class
    private static void checkMove(TttGameModel model, int i, int j)
    System.out.println("OK move: " + model.takeTurn(i, j));
    System.out.println(model + "\n");

  • HT204146 Good morning.  I just purchased Imatch but cannot download my music from an iphone 5 to IMatch in Icloud.  Can you help me with this?

    Good morning.  I just purchased Imatch but cannot download my music from an iphone 5 to IMatch in Icloud.  Can you help me with this?

    Hi
    Has iTunes completed its scan of your iTunes library on your computer Subscribing to iTunes from an iOS device.
    Jim

Maybe you are looking for