Don't understand computer authorization
I bought toy story and then burned a copy for my mac, so i could sync it with my iphone for the kids. i also put it on my home computer to sync with my wife's iphone. but i'm getting a message that i have to authorize the computer to play it. why? i didn't buy it from itunes. can someone explain to me why this is happening? I don't understand how authorizations work.
I have this same problem. When I sync my ipod I get the message that my purchased songs etc. will not be synced because this computer is not authorized. So I authorized the computer and it tells me the computer is already authorized. So what to do?
I just downloaded 10.x because apparently the 8.x had problems that I just figured was related to the installation have not used my pod for almost a year. Everything else is fine just not getting these songs.
We need help.
Similar Messages
-
I don't understand computer language please help.
I don't understand computer language to figure out why I am having trouble playing pogo games.
<sub>edit: removed personal information for your protection. please note that we cannot offer support via telephone, so please continue in the forum. thanks for your understanding! (philipp)</sub>It would be helpful if you could reply with the specific wording of the error message you are getting. If it's too difficult to type out, you could try to capture a screen shot of it. This article has tips on doing that: [[How do I create a screenshot of my problem?]]
Also, I found this test page on Pogo's site where they tell you whether your browser meets their requirements. Could you view this page and see whether you get green checkmarks for all the items? If not, we might be able to help you get what you need for full compatibility:
http://www.pogo.com/system-info -
When i attempt to sync my iphone it continues to say this computer is no longer authorized for apps and they will be deleted?? I don't understand?? I put my password and authorize but same message comes up. What to do??
I found the solution in another post. By deleting all my apps, I was able to sync the phone. I hope I don't have to delete all my apps every time I want to sync my phone, but at least now I am able to sync my phone.
-
I just downloaded Adobe Acrobat XI Pro, I am in the install process now and I am getting an Error message, Error 1303, stating I need to log on as an administrator ... this is my computer so I don't understand the issue??
Hi MAX22,
Even though it's your computer but your user account might not have sufficient privileges to install the software.
Please try the following :
> Enable the hidden Admin Account on Windows 7 ( Ref : http://www.howtogeek.com/howto/windows-vista/enable-the-hidden-administrator-account-on-wi ndows-vista/ )
Reboot and try installing in the new enabled Admin user account and check.
Regards,
Rave -
The itunes software repeats its request for computer authorization despite trying the steps mentioned in the
help article: authorizing from admin account, checking for updates, deleting sc folder, what else can be done?Doublechecking. In the course of your troubleshooting to date, have you also worked through the instructions from the following document?
iTunes: Missing folder or incorrect permissions may prevent authorization -
I am computer challenged so I don't understand this. When I try to download Mozilla Firefox on my laptop it tells me that firefox uses a proxy server and won't complete the download. I don't like IE, and do like Mozilla Firefox and have used it for a long time on my desk top. If someone could tell me what to do to make it work I really would appreciate this.
This is on a laptop, not this computerAre you trying to do this while on a corporate wifi or over home wifi/cellular?
-
HT1420 I don't have the 'Authorize this computer' button.....
So, I am trying to Authorize my new computer on itunes and I don't have the Authorize this Computer button. I have iTunes version 10.6. Can someone please help me out here?
It should be on the Store drop-wodn menu at the top of iTunes e.g.
-
I just don't understand how to delete photos from my Iphone placed there by Syc.
Well, if they were synced fomr a computer then the iPhone says the computer "owns" them for instructional purposes. You have two options.
1) Plug your iPhone up to any computer with iTunes. You can get itunes at www.itunes.com Then tell it to sync photos, but then select no photos or an empty folder. This will override what the previous computer put on your iPhone.
2) Go to Settings > General > Reset > Erase All Content & Settings and say goodbye to everything including those synced photos. If you make a quick backup first in iCloud (be sure it finishes) then you can restore form your iCloud backup via Wifi and those synced photos wont be there. How to backup: http://support.apple.com/kb/ht1766 -
I tried to log inn to itunes store on my computer, but is say that it is somthing wrong with the internett conaction .. help ? The internett is god so i don't understand ..
Hi trine96,
Welcome to the Support Communities!
The article below will walk you through the troubleshooting steps for connectivity issues with iTunes:
Can't connect to the iTunes Store
http://support.apple.com/kb/TS1368
iTunes: Advanced iTunes Store troubleshooting
http://support.apple.com/kb/TS3297
I hope this information helps ....
Have a great day!
- Judy -
I don't understand why recently with the new "pages" my computer stops responding. When I go to fix some grammar all of a sudden the little colored circle begins to appear and won't go away I restart my computer.
If you have more than one user account, these instructions must be carried out as an administrator.
Launch the Console application in any of the following ways:
☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
☞ Open LaunchPad. Click Utilities, then Console in the icon grid.
Step 1
Make sure the title of the Console window is All Messages. If it isn't, select All Messages from the SYSTEM LOG QUERIES menu on the left. If you don't see that menu, select
View ▹ Show Log List
from the menu bar.
Enter "BOOT_TIME" (without the quotes) in the search box. Note the timestamps of those log messages, which refer to the times when the system was booted. Now clear the search box and scroll back in the log to the last boot time after you had the problem. Select the messages logged before the boot, while the system was unresponsive or was failing to shut down. Copy them to the Clipboard by pressing the key combination command-C. Paste into a reply to this message (command-V). Please include the BOOT_TIME message at the end of the log extract.
If there are runs of repeated messages, post only one example of each. Don’t post many repetitions of the same message.
When posting a log extract, be selective. In most cases, a few dozen lines are more than enough.
Please do not indiscriminately dump thousands of lines from the log into this discussion.
Important: Some private information, such as your name, may appear in the log. Anonymize before posting.
Step 2
Still in Console, look under System Diagnostic Reports for crash or panic logs, and post the entire contents of the most recent one, if any. In the interest of privacy, I suggest you edit out the “Anonymous UUID,” a long string of letters, numbers, and dashes in the header of the report, if present (it may not be.) Please don’t post any other kind of report — it will be very long and not helpful. -
try and open a web pg. that friend sent me it keeps coming up on screen in box says, The Proxy server refusing connections Firefox is configured to use a proxy server that is refusing connections , Check t proxy settings to make sure that , they are correct,Check network to see if proxy server is working
okay so how do I fix this cause really don't understand what this means , Help! to fix as I am missing a lot of information I would like to read .KMHYou can find the connection settings in Tools > Options > Advanced : Network : Connection
If you do not need to use a proxy to connect to internet then select "No Proxy" if the default "Use the system proxy settings" setting doesn't work.
See "Firefox connection settings":
* https://support.mozilla.com/kb/Firefox+cannot+load+websites+but+other+programs+can -
Which Mac Pro? More cores=slower speeds? And most of us know the speed matters or FPU for music and I don't understand the faster is for the least amount of procs. And while I get the whole rendering thing and why it makes sense.
The above is what the bar says. It's been a while and wondered, maybe Apple changed the format for forums. Then got this nice big blank canvas to air my concerns. Went to school for Computer Science, BSEE, even worked at Analog Devices in Newton Massachusetts, where they make something for apple.
The bottom line is fast CPU = more FPU = more headroom and still can't figure out why the more cores= the slower it gets unless it's to get us in to a 6 core then come out with faster cores down the road or a newer Mac that uses the GPU. Also. Few. I'm the guy who said a few years ago Mac has an FCP that looks like iMovie on Steroids. Having said that I called the campus one day to ask them something and while I used to work for Apple, I think she thought I still did as she asked me, "HOW ARE THE 32 CORES/1DYE COMING ALONG? Not wanting to embarrass her I said fine, fine and then hung up. Makes the most sense as I never quite got the 2,6,12 cores when for years everything from memory to CPU's have been, in sets of 2 to the 2nd power. 2,4,8,16,32,64,120,256,512, 1024, 2048,4196,8192, 72,768. Wow. W-O-W and will be using whatever I get with Apollo Quad.
Peace to all and hope someone can point us in THE RIGHT DIRECTION. THANK YOUThanks for your reply via email/msg. He wrote:
If you are interested in the actual design data for the Xeon processor, go to the Intel site and the actual CPU part numbers are:
Xeon 4 core - E5.1620v2
Xeon 6 core - E5.1650v2
Xeon 8 core - E5.1680v2
Xeon 12 core - E5.2697v2
I read that the CPU is easy to swap out but am sure something goes wrong at a certain point - even if solderedon they make material to absorb the solder, making your work area VERY clean.
My Question now is this, get an 8 core, then replace with 2 3.7 QUAD CHIPS, what would happen?
I also noticed that the 8 core Mac Pro is 3.0 when in fact they do have a 3.4 8 core chip, so 2 =16? Or if correct, wouldn't you be able to replace a QUAD CHIP WITH THAT? I;M SURE THEY ARE UO TO SOMETHING AS 1) WE HAVE SEEN NO AUDIO FPU OR PERHAPS I SHOULD CHECK OUT PC MAKERS WINDOWS machines for Sisoft Sandra "B-E-N-C-H-M-A-R-K-S" -
SOMETHINGS UP AND AM SURE WE'LL ALL BE PLEASED, AS the mac pro was announced Last year, barely made the December mark, then pushed to January, then February and now April.
Would rather wait and have it done correct than released to early only to have it benchmarked in audio and found to be slower in a few areas- - - the logical part of my brain is wondering what else I would have to swap out as I am sure it would run, and fine for a while, then, poof....
PEACE===AM SURE APPLE WILL BLOW US AWAY - they have to figure out how to increase the power for 150 watts or make the GPU work which in regard to FPU, I thought was NVIDIA? -
I just updated my Macbook (2010) to Yosemite, and it's become very slow. After searching through this community, I downloaded and run EtreCheck, but don't understand what the report means. Please could you help me with what I should do to improve my computer's speed, aside from upgrading my RAM? Thank you so much.
The report:
Problem description:
my macbook is running very slowly after upgrading to yosemite.
EtreCheck version: 2.0.11 (98)
Report generated 12 November 2014 1:44:14 pm SGT
Hardware Information: ℹ️
MacBook (13-inch, Mid 2010) (Verified)
MacBook - model: MacBook7,1
1 2.4 GHz Intel Core 2 Duo CPU: 2-core
2 GB RAM Upgradeable
BANK 0/DIMM0
1 GB DDR3 1067 MHz ok
BANK 1/DIMM0
1 GB DDR3 1067 MHz ok
Bluetooth: Old - Handoff/Airdrop2 not supported
Wireless: en1: 802.11 a/b/g/n
Video Information: ℹ️
NVIDIA GeForce 320M - VRAM: 256 MB
Color LCD 1280 x 800
System Software: ℹ️
OS X 10.10 (14A389) - Uptime: 3:23:3
Disk Information: ℹ️
TOSHIBA MK2555GSXF disk0 : (250.06 GB)
S.M.A.R.T. Status: Verified
EFI (disk0s1) <not mounted> : 210 MB
Macintosh HD (disk0s2) / [Startup]: 249.20 GB (25.42 GB free)
Recovery HD (disk0s3) <not mounted> [Recovery]: 650 MB
HL-DT-ST DVDRW GS23N
USB Information: ℹ️
Western Digital My Passport 0748 1 TB
S.M.A.R.T. Status: Verified
EFI (disk1s1) <not mounted> : 210 MB
tansey (disk1s2) /Volumes/tansey : 999.83 GB (951.98 GB free)
Apple Inc. Built-in iSight
Apple Inc. BRCM2070 Hub
Apple Inc. Bluetooth USB Host Controller
Apple Inc. Apple Internal Keyboard / Trackpad
Configuration files: ℹ️
/etc/hosts - Count: 15
Gatekeeper: ℹ️
Mac App Store and identified developers
Kernel Extensions: ℹ️
/System/Library/Extensions
[not loaded] com.NovatelWireless.driver.NovatelWirelessUSBCDCECMControl (3.0.13) Support
[not loaded] com.NovatelWireless.driver.NovatelWirelessUSBCDCECMData (3.0.13) Support
[not loaded] com.ZTE.driver.ZTEUSBCDCACMData (1.3.8) Support
[not loaded] com.ZTE.driver.ZTEUSBMassStorageFilter (1.3.8) Support
[not loaded] com.novamedia.driver.IceraUSB_MSD_Bypass (1.3.0) Support
[not loaded] com.novatelwireless.driver.3G (3.0.13) Support
[not loaded] com.novatelwireless.driver.DisableAutoInstall (3.0.13) Support
[not loaded] com.option.driver.Option72 (2.15.0) Support
[not loaded] com.option.driver.OptionHS (3.26.0) Support
[not loaded] com.option.driver.OptionMSD (1.21.0) Support
[not loaded] com.option.driver.OptionQC (1.11.0) Support
[not loaded] com.rim.driver.BlackBerryUSBDriverInt (0.0.39) Support
[not loaded] com.rim.driver.BlackBerryUSBDriverVSP (0.0.45) Support
[not loaded] com.vodafone.driver (3.0.9) Support
[not loaded] com.zte.driver.cdc_ecm_qmi (1.0.1) Support
[not loaded] com.zte.driver.cdc_usb_bus (1.0.1) Support
[not loaded] de.novamedia.driver.NMSamsung (0.0.2) Support
[not loaded] de.novamedia.driver.NMSmartplugSCSIDevice (1.0.1) Support
[not loaded] de.novamedia.oem.vodafone.vtp.huawei.cdc (0.0.2) Support
/System/Library/Extensions/NMHuaweiPhonesVTPCDC_106.kext/Contents/PlugIns
[not loaded] de.novamedia.driver.NMUSBCDCACMControl (3.2.12) Support
/System/Library/Extensions/NMSamsungDriver_106.kext/Contents/PlugIns
[not loaded] de.novamedia.driver.NMUSBCDCACMData (3.2.12) Support
/System/Library/Extensions/NovatelWireless3G.kext/Contents/PlugIns
[not loaded] com.novatelwireless.driver.3GData (3.0.13) Support
/System/Library/Extensions/Vodafone.kext/Contents/PlugIns
[not loaded] com.vodafone.driver.Data (3.0.9) Support
Startup Items: ℹ️
HP IO: Path: /Library/StartupItems/HP IO
HWNetMgr: Path: /Library/StartupItems/HWNetMgr
HWPortDetect: Path: /Library/StartupItems/HWPortDetect
Startup items are obsolete and will not work in future versions of OS X
Problem System Launch Agents: ℹ️
[failed] com.apple.accountsd.plist
[failed] com.apple.AirPlayUIAgent.plist
[failed] com.apple.bird.plist
[failed] com.apple.CallHistoryPluginHelper.plist
[failed] com.apple.CallHistorySyncHelper.plist
[failed] com.apple.cloudd.plist
[failed] com.apple.coreservices.appleid.authentication.plist
[failed] com.apple.coreservices.uiagent.plist
[failed] com.apple.EscrowSecurityAlert.plist
[failed] com.apple.icloud.fmfd.plist
[failed] com.apple.iconservices.iconservicesagent.plist
[failed] com.apple.nsurlsessiond.plist
[failed] com.apple.pluginkit.pkd.plist
[failed] com.apple.recentsd.plist
[failed] com.apple.security.cloudkeychainproxy.plist
[failed] com.apple.spindump_agent.plist
[failed] com.apple.telephonyutilities.callservicesd.plist
Problem System Launch Daemons: ℹ️
[failed] com.apple.awdd.plist
[failed] com.apple.cache_delete.plist
[failed] com.apple.coresymbolicationd.plist
[failed] com.apple.ctkd.plist
[failed] com.apple.diagnosticd.plist
[failed] com.apple.iconservices.iconservicesagent.plist
[failed] com.apple.iconservices.iconservicesd.plist
[failed] com.apple.ifdreader.plist
[failed] com.apple.installd.plist
[failed] com.apple.MobileFileIntegrity.plist
[failed] com.apple.nehelper.plist
[failed] com.apple.nsurlsessiond.plist
[failed] com.apple.sandboxd.plist
[failed] com.apple.softwareupdated.plist
[failed] com.apple.spindump.plist
[failed] com.apple.sysmond.plist
[failed] com.apple.tccd.system.plist
[failed] com.apple.wdhelper.plist
[failed] com.apple.xpc.smd.plist
[running] de.novamedia.nmnetmgrd.plist Support
Launch Agents: ℹ️
[not loaded] com.adobe.AAM.Updater-1.0.plist Support
[failed] com.adobe.CS5ServiceManager.plist Support
[loaded] com.google.keystone.agent.plist Support
[running] de.novamedia.VodafoneDeviceObserver.plist Support
[invalid?] SwapperUFi.plist Support
Launch Daemons: ℹ️
[loaded] com.adobe.fpsaud.plist Support
[invalid?] com.adobe.SwitchBoard.plist Support
[loaded] com.cloudpath.maccmd.plist Support
[loaded] com.google.keystone.daemon.plist Support
[loaded] com.microsoft.office.licensing.helper.plist Support
[invalid?] PPPMonitord.plist Support
User Launch Agents: ℹ️
[loaded] com.adobe.ARM.[...].plist Support
[invalid?] com.akamai.client.plist Support
[invalid?] com.divx.agent.postinstall.plist Support
[failed] com.facebook.videochat.[redacted].plist Support
User Login Items: ℹ️
Dropbox Application (/Applications/Dropbox.app)
SurplusMeterAgent UNKNOWN (missing value)
Google Chrome ApplicationHidden (/Applications/Google Chrome.app)
HP Scheduler Application (/Library/Application Support/Hewlett-Packard/Software Update/HP Scheduler.app)
Internet Plug-ins: ℹ️
o1dbrowserplugin: Version: 5.38.6.0 - SDK 10.8 Support
Google Earth Web Plug-in: Version: 7.1 Support
Default Browser: Version: 600 - SDK 10.10
OfficeLiveBrowserPlugin: Version: 12.2.6 Support
OVSHelper: Version: 1.1 Support
AdobePDFViewerNPAPI: Version: 10.1.12 Support
FlashPlayer-10.6: Version: 15.0.0.152 - SDK 10.6 Support
Silverlight: Version: 5.1.10411.0 - SDK 10.6 Support
Flash Player: Version: 15.0.0.152 - SDK 10.6 Mismatch! Adobe recommends 15.0.0.223
iPhotoPhotocast: Version: 7.0
googletalkbrowserplugin: Version: 5.38.6.0 - SDK 10.8 Support
QuickTime Plugin: Version: 7.7.3
AdobePDFViewer: Version: 10.1.12 Support
SharePointBrowserPlugin: Version: 14.0.0 Support
JavaAppletPlugin: Version: 15.0.0 - SDK 10.10 Check version
User Internet Plug-ins: ℹ️
OctoshapeWeb: Version: 1.0 Support
Safari Extensions: ℹ️
DivX Plus Web Player HTML5 <video>
3rd Party Preference Panes: ℹ️
DivX Support
Flash Player Support
Time Machine: ℹ️
Skip System Files: NO
Auto backup: NO - Auto backup turned off
Volumes being backed up:
Macintosh HD: Disk size: 249.20 GB Disk used: 223.78 GB
Destinations:
Time Machine Backups [Local]
Total size: 0 B
Total number of backups: 0
Oldest backup: -
Last backup: -
Size of backup disk: Too small
Backup size 0 B < (Disk used 223.78 GB X 3)
Top Processes by CPU: ℹ️
15% WindowServer
1% Dropbox
0% AppleSpell
0% Skype
0% imagent
Top Processes by Memory: ℹ️
60 MB Google Chrome
56 MB JavaApplicationStub
47 MB Skype
45 MB Finder
45 MB WindowServer
Virtual Memory Information: ℹ️
60 MB Free RAM
443 MB Active RAM
398 MB Inactive RAM
349 MB Wired RAM
16.91 GB Page-ins
633 MB Page-outsI advise to reply to the one you want to reply to.
You have had good information here. I will not repeat that here.
I would like to add:
you have incompatible software: start in SafeMode, read Woodmeister and see if it is free of issues.
Akamai is crap software needed or not, Huawei the same.
It is very possible that the keygenerator you used for generating a key for some softwares has infected your mac.
The non-regular software with the false key(s) are not compatible probably or generate malware. Luckily you can not update them automatically because the keygenerator blocked the software for contacting the developer... I propose to consider getting rid of those softwares by really good uninstalling.
You have a beautiful mac, don't degenerate it with crapped software. There are alternatives for expensive software, for example Adobe Photoshop has a free alternative (with a less beautiful interface) in GIMP. And so on.
Lex -
Hi,
Ok, I'll preface this by saying there's a lotta code pasted in here but it really quite an easy question, I just need to post all the code so you understand where what came from.
Now.............the question I'm trying to do is to create an applet that has 2 buttons -- each button when clicked opens an application (one is a simple calculator, the other a Mortgage calculation app). When you click one of the buttons (calc or mortgage), that app opens infront of the 2 button menu so its in "focus". The button on the 2 button menu then switches to a "hide app X" button (ie: "Mortgage", changes to "Hide Mortgage"). Thus if you click the hide button, the app that was opened is hidden, and then that "hide" button switches back to the original "app X" button. Pretty simple.
Now, I have from my text book an example that does exactly this, with the simple calculator already in it, and with another app (a traffic light thing) where the Mortgage should be in my final product. I also already have the Mortgage applet I need to insert from another book example in place of that Traffic Light portion.
Now, common sense would dictate that I should be able to just copy my code for the Mortgage applet into the example that has the 2 button menu structure, and overwrite the code I want to get rid of (the traffic light) with the mortgage code & rename the menu buttons. Right?? A simple switch of one thing for another... but therein lies my problem.
I copied all the Mortgage code in correctly over the traffic lights, switched the button names, tried to compile it but I get one error....
Exercise12_17.java:52: cannot resolve symbol
symbol : method pack ()
location: class MortgageApplet
mortgageAppletFrame.pack();I don't understand why..... mortgageAppletFrame.pack(); was a simple rewrite from lightsFrame.pack(); like every other line...... it should work. I've gone over it for 2 days......... Anyone know why it comes up as an error???
Below, in order going down is (1)my code with the 1 error I can't solve, (2)the original menu example I tried to edit, and (3)the Mortgage app code...........
Does anyone know what my error is?? Help or a hint would be greatly appreciated........ Thanks.
My erroring app.......
// Exercise12_17.java: Create multiple windows
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import javax.swing.border.TitledBorder;
public class Exercise12_17 extends JFrame implements ActionListener {
// Declare and create a frame: an instance of MenuDemo
MenuDemo calcFrame = new MenuDemo();
// Declare and create a frame: an instance of RadioButtonDemo
MortgageApplet mortgageAppletFrame = new MortgageApplet();
// Declare two buttons for displaying frames
private JButton jbtCalc;
private JButton jbtMortgage;
public static void main(String[] args) {
Exercise12_17 frame = new Exercise12_17();
frame.setSize( 400, 70 );
frame.setTitle("Exercise 11.8: Multiple Windows Demo");
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setVisible(true);
public Exercise12_17() {
// Add buttons to the main frame
getContentPane().setLayout(new FlowLayout());
getContentPane().add(jbtCalc = new JButton("Simple Calculator"));
getContentPane().add(jbtMortgage = new JButton("Mortgage"));
// Register the main frame as listener for the buttons
jbtCalc.addActionListener(this);
jbtMortgage.addActionListener(this);
public void actionPerformed(ActionEvent e) {
String arg = e.getActionCommand();
if (e.getSource() instanceof JButton)
if ("Simple Calculator".equals(arg)) {
//show the MenuDemo frame
jbtCalc.setText("Hide Simple Calculator");
calcFrame.pack();
calcFrame.setVisible(true);
else if ("Hide Simple Calculator".equals(arg)) {
calcFrame.setVisible(false);
jbtCalc.setText("Simple Calculator");
else if ("Mortgage".equals(arg)) {
//show the CheckboxGroup frame
mortgageAppletFrame.pack();
jbtMortgage.setText("Hide Mortgage");
mortgageAppletFrame.setVisible(true);
else if ("Hide Mortgage".equals(arg)) {
mortgageAppletFrame.setVisible(false);
jbtMortgage.setText("Mortgage");
class MortgageApplet extends JApplet
implements ActionListener {
// Declare and create text fields for interest rate
// year, loan amount, monthly payment, and total payment
private JTextField jtfAnnualInterestRate = new JTextField();
private JTextField jtfNumOfYears = new JTextField();
private JTextField jtfLoanAmount = new JTextField();
private JTextField jtfMonthlyPayment = new JTextField();
private JTextField jtfTotalPayment = new JTextField();
// Declare and create a Compute Mortgage button
private JButton jbtComputeMortgage = new JButton("Compute Mortgage");
/** Initialize user interface */
public void init() {
// Set properties on the text fields
jtfMonthlyPayment.setEditable(false);
jtfTotalPayment.setEditable(false);
// Right align text fields
jtfAnnualInterestRate.setHorizontalAlignment(JTextField.RIGHT);
jtfNumOfYears.setHorizontalAlignment(JTextField.RIGHT);
jtfLoanAmount.setHorizontalAlignment(JTextField.RIGHT);
jtfMonthlyPayment.setHorizontalAlignment(JTextField.RIGHT);
jtfTotalPayment.setHorizontalAlignment(JTextField.RIGHT);
// Panel p1 to hold labels and text fields
JPanel p1 = new JPanel();
p1.setLayout(new GridLayout(5, 2));
p1.add(new Label("Annual Interest Rate"));
p1.add(jtfAnnualInterestRate);
p1.add(new Label("Number of Years"));
p1.add(jtfNumOfYears);
p1.add(new Label("Loan Amount"));
p1.add(jtfLoanAmount);
p1.add(new Label("Monthly Payment"));
p1.add(jtfMonthlyPayment);
p1.add(new Label("Total Payment"));
p1.add(jtfTotalPayment);
p1.setBorder(new
TitledBorder("Enter interest rate, year and loan amount"));
// Panel p2 to hold the button
JPanel p2 = new JPanel();
p2.setLayout(new FlowLayout(FlowLayout.RIGHT));
p2.add(jbtComputeMortgage);
// Add the components to the applet
getContentPane().add(p1, BorderLayout.CENTER);
getContentPane().add(p2, BorderLayout.SOUTH);
// Register listener
jbtComputeMortgage.addActionListener(this);
/** Handle the "Compute Mortgage" button */
public void actionPerformed(ActionEvent e) {
if (e.getSource() == jbtComputeMortgage) {
// Get values from text fields
double interest = (Double.valueOf(
jtfAnnualInterestRate.getText())).doubleValue();
int year =
(Integer.valueOf(jtfNumOfYears.getText())).intValue();
double loan =
(Double.valueOf(jtfLoanAmount.getText())).doubleValue();
// Create a mortgage object
Mortgage m = new Mortgage(interest, year, loan);
// Display monthly payment and total payment
jtfMonthlyPayment.setText(String.valueOf(m.monthlyPayment()));
jtfTotalPayment.setText(String.valueOf(m.totalPayment()));
class MenuDemo extends JFrame implements ActionListener {
// Text fields for Number 1, Number 2, and Result
private JTextField jtfNum1, jtfNum2, jtfResult;
// Buttons "Add", "Subtract", "Multiply" and "Divide"
private JButton jbtAdd, jbtSub, jbtMul, jbtDiv;
// Menu items "Add", "Subtract", "Multiply","Divide" and "Close"
private JMenuItem jmiAdd, jmiSub, jmiMul, jmiDiv, jmiClose;
/** Main method */
public static void main(String[] args) {
MenuDemo frame = new MenuDemo();
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.pack();
frame.setVisible(true);
/** Default constructor */
public MenuDemo() {
setTitle("Menu Demo");
// Create menu bar
JMenuBar jmb = new JMenuBar();
// Set menu bar to the frame
setJMenuBar(jmb);
// Add menu "Operation" to menu bar
JMenu operationMenu = new JMenu("Operation");
operationMenu.setMnemonic('O');
jmb.add(operationMenu);
// Add menu "Exit" in menu bar
JMenu exitMenu = new JMenu("Exit");
exitMenu.setMnemonic('E');
jmb.add(exitMenu);
// Add menu items with mnemonics to menu "Operation"
operationMenu.add(jmiAdd= new JMenuItem("Add", 'A'));
operationMenu.add(jmiSub = new JMenuItem("Subtract", 'S'));
operationMenu.add(jmiMul = new JMenuItem("Multiply", 'M'));
operationMenu.add(jmiDiv = new JMenuItem("Divide", 'D'));
exitMenu.add(jmiClose = new JMenuItem("Close", 'C'));
// Set keyboard accelerators
jmiAdd.setAccelerator(
KeyStroke.getKeyStroke(KeyEvent.VK_A, ActionEvent.CTRL_MASK));
jmiSub.setAccelerator(
KeyStroke.getKeyStroke(KeyEvent.VK_S, ActionEvent.CTRL_MASK));
jmiMul.setAccelerator(
KeyStroke.getKeyStroke(KeyEvent.VK_M, ActionEvent.CTRL_MASK));
jmiDiv.setAccelerator(
KeyStroke.getKeyStroke(KeyEvent.VK_D, ActionEvent.CTRL_MASK));
// Panel p1 to hold text fields and labels
JPanel p1 = new JPanel();
p1.setLayout(new FlowLayout());
p1.add(new JLabel("Number 1"));
p1.add(jtfNum1 = new JTextField(3));
p1.add(new JLabel("Number 2"));
p1.add(jtfNum2 = new JTextField(3));
p1.add(new JLabel("Result"));
p1.add(jtfResult = new JTextField(4));
jtfResult.setEditable(false);
// Panel p2 to hold buttons
JPanel p2 = new JPanel();
p2.setLayout(new FlowLayout());
p2.add(jbtAdd = new JButton("Add"));
p2.add(jbtSub = new JButton("Subtract"));
p2.add(jbtMul = new JButton("Multiply"));
p2.add(jbtDiv = new JButton("Divide"));
// Add panels to the frame
getContentPane().setLayout(new BorderLayout());
getContentPane().add(p1, BorderLayout.CENTER);
getContentPane().add(p2, BorderLayout.SOUTH);
// Register listeners
jbtAdd.addActionListener(this);
jbtSub.addActionListener(this);
jbtMul.addActionListener(this);
jbtDiv.addActionListener(this);
jmiAdd.addActionListener(this);
jmiSub.addActionListener(this);
jmiMul.addActionListener(this);
jmiDiv.addActionListener(this);
jmiClose.addActionListener(this);
/** Handle ActionEvent from buttons and menu items */
public void actionPerformed(ActionEvent e) {
String actionCommand = e.getActionCommand();
// Handle button events
if (e.getSource() instanceof JButton) {
if ("Add".equals(actionCommand))
calculate('+');
else if ("Subtract".equals(actionCommand))
calculate('-');
else if ("Multiply".equals(actionCommand))
calculate('*');
else if ("Divide".equals(actionCommand))
calculate('/');
else if (e.getSource() instanceof JMenuItem) {
// Handle menu item events
if ("Add".equals(actionCommand))
calculate('+');
else if ("Subtract".equals(actionCommand))
calculate('-');
else if ("Multiply".equals(actionCommand))
calculate('*');
else if ("Divide".equals(actionCommand))
calculate('/');
else if ("Close".equals(actionCommand))
System.exit(0);
/** Calculate and show the result in jtfResult */
private void calculate(char operator) {
// Obtain Number 1 and Number 2
int num1 = (Integer.parseInt(jtfNum1.getText().trim()));
int num2 = (Integer.parseInt(jtfNum2.getText().trim()));
int result = 0;
// Perform selected operation
switch (operator) {
case '+': result = num1 + num2;
break;
case '-': result = num1 - num2;
break;
case '*': result = num1 * num2;
break;
case '/': result = num1 / num2;
// Set result in jtfResult
jtfResult.setText(String.valueOf(result));
Original 2 button menu example....
// Exercise11_8.java: Create multiple windows
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class Exercise11_8 extends JFrame implements ActionListener {
// Declare and create a frame: an instance of MenuDemo
MenuDemo calcFrame = new MenuDemo();
// Declare and create a frame: an instance of RadioButtonDemo
RadioButtonDemo lightsFrame = new RadioButtonDemo();
// Declare two buttons for displaying frames
private JButton jbtCalc;
private JButton jbtLights;
public static void main(String[] args) {
Exercise11_8 frame = new Exercise11_8();
frame.setSize( 400, 70 );
frame.setTitle("Exercise 11.8: Multiple Windows Demo");
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setVisible(true);
public Exercise11_8() {
// Add buttons to the main frame
getContentPane().setLayout(new FlowLayout());
getContentPane().add(jbtCalc = new JButton("Simple Calculator"));
getContentPane().add(jbtLights = new JButton("Traffic Lights"));
// Register the main frame as listener for the buttons
jbtCalc.addActionListener(this);
jbtLights.addActionListener(this);
public void actionPerformed(ActionEvent e) {
String arg = e.getActionCommand();
if (e.getSource() instanceof JButton)
if ("Simple Calculator".equals(arg)) {
//show the MenuDemo frame
jbtCalc.setText("Hide Simple Calculator");
calcFrame.pack();
calcFrame.setVisible(true);
else if ("Hide Simple Calculator".equals(arg)) {
calcFrame.setVisible(false);
jbtCalc.setText("Simple Calculator");
else if ("Traffic Lights".equals(arg)) {
//show the CheckboxGroup frame
lightsFrame.pack();
jbtLights.setText("Hide Traffic Lights");
lightsFrame.setVisible(true);
else if ("Hide Traffic Lights".equals(arg)) {
lightsFrame.setVisible(false);
jbtLights.setText("Traffic Lights");
class RadioButtonDemo extends JFrame
implements ItemListener {
// Declare radio buttons
private JRadioButton jrbRed, jrbYellow, jrbGreen;
// Declare a radio button group
private ButtonGroup btg = new ButtonGroup();
// Declare a traffic light display panel
private Light light;
/** Main method */
public static void main(String[] args) {
RadioButtonDemo frame = new RadioButtonDemo();
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setSize(250, 170);
frame.setVisible(true);
/** Default constructor */
public RadioButtonDemo() {
setTitle("RadioButton Demo");
// Add traffic light panel to panel p1
JPanel p1 = new JPanel();
p1.setSize(200, 200);
p1.setLayout(new FlowLayout(FlowLayout.CENTER));
light = new Light();
light.setSize(40, 90);
p1.add(light);
// Put the radio button in Panel p2
JPanel p2 = new JPanel();
p2.setLayout(new FlowLayout());
p2.add(jrbRed = new JRadioButton("Red", true));
p2.add(jrbYellow = new JRadioButton("Yellow", false));
p2.add(jrbGreen = new JRadioButton("Green", false));
// Set keyboard mnemonics
jrbRed.setMnemonic('R');
jrbYellow.setMnemonic('Y');
jrbGreen.setMnemonic('G');
// Group radio buttons
btg.add(jrbRed);
btg.add(jrbYellow);
btg.add(jrbGreen);
// Place p1 and p2 in the frame
getContentPane().setLayout(new BorderLayout());
getContentPane().add(p1, BorderLayout.CENTER);
getContentPane().add(p2, BorderLayout.SOUTH);
// Register listeners for check boxes
jrbRed.addItemListener(this);
jrbYellow.addItemListener(this);
jrbGreen.addItemListener(this);
/** Handle checkbox events */
public void itemStateChanged(ItemEvent e) {
if (jrbRed.isSelected())
light.turnOnRed(); // Set red light
if (jrbYellow.isSelected())
light.turnOnYellow(); // Set yellow light
if (jrbGreen.isSelected())
light.turnOnGreen(); // Set green light
// Three traffic lights shown in a panel
class Light extends JPanel {
private boolean red;
private boolean yellow;
private boolean green;
/** Default constructor */
public Light() {
turnOnGreen();
/** Set red light on */
public void turnOnRed() {
red = true;
yellow = false;
green = false;
repaint();
/** Set yellow light on */
public void turnOnYellow() {
red = false;
yellow = true;
green = false;
repaint();
/** Set green light on */
public void turnOnGreen() {
red = false;
yellow = false;
green = true;
repaint();
/** Display lights */
public void paintComponent(Graphics g) {
super.paintComponent(g);
if (red) {
g.setColor(Color.red);
g.fillOval(10, 10, 20, 20);
g.setColor(Color.black);
g.drawOval(10, 35, 20, 20);
g.drawOval(10, 60, 20, 20);
g.drawRect(5, 5, 30, 80);
else if (yellow) {
g.setColor(Color.yellow);
g.fillOval(10, 35, 20, 20);
g.setColor(Color.black);
g.drawRect(5, 5, 30, 80);
g.drawOval(10, 10, 20, 20);
g.drawOval(10, 60, 20, 20);
else if (green) {
g.setColor(Color.green);
g.fillOval(10, 60, 20, 20);
g.setColor(Color.black);
g.drawRect(5, 5, 30, 80);
g.drawOval(10, 10, 20, 20);
g.drawOval(10, 35, 20, 20);
else {
g.setColor(Color.black);
g.drawRect(5, 5, 30, 80);
g.drawOval(10, 10, 20, 20);
g.drawOval(10, 35, 20, 20);
g.drawOval(10, 60, 20, 20);
/** Set preferred size */
public Dimension getPreferredSize() {
return new Dimension(40, 90);
class MenuDemo extends JFrame implements ActionListener {
// Text fields for Number 1, Number 2, and Result
private JTextField jtfNum1, jtfNum2, jtfResult;
// Buttons "Add", "Subtract", "Multiply" and "Divide"
private JButton jbtAdd, jbtSub, jbtMul, jbtDiv;
// Menu items "Add", "Subtract", "Multiply","Divide" and "Close"
private JMenuItem jmiAdd, jmiSub, jmiMul, jmiDiv, jmiClose;
/** Main method */
public static void main(String[] args) {
MenuDemo frame = new MenuDemo();
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.pack();
frame.setVisible(true);
/** Default constructor */
public MenuDemo() {
setTitle("Menu Demo");
// Create menu bar
JMenuBar jmb = new JMenuBar();
// Set menu bar to the frame
setJMenuBar(jmb);
// Add menu "Operation" to menu bar
JMenu operationMenu = new JMenu("Operation");
operationMenu.setMnemonic('O');
jmb.add(operationMenu);
// Add menu "Exit" in menu bar
JMenu exitMenu = new JMenu("Exit");
exitMenu.setMnemonic('E');
jmb.add(exitMenu);
// Add menu items with mnemonics to menu "Operation"
operationMenu.add(jmiAdd= new JMenuItem("Add", 'A'));
operationMenu.add(jmiSub = new JMenuItem("Subtract", 'S'));
operationMenu.add(jmiMul = new JMenuItem("Multiply", 'M'));
operationMenu.add(jmiDiv = new JMenuItem("Divide", 'D'));
exitMenu.add(jmiClose = new JMenuItem("Close", 'C'));
// Set keyboard accelerators
jmiAdd.setAccelerator(
KeyStroke.getKeyStroke(KeyEvent.VK_A, ActionEvent.CTRL_MASK));
jmiSub.setAccelerator(
KeyStroke.getKeyStroke(KeyEvent.VK_S, ActionEvent.CTRL_MASK));
jmiMul.setAccelerator(
KeyStroke.getKeyStroke(KeyEvent.VK_M, ActionEvent.CTRL_MASK));
jmiDiv.setAccelerator(
KeyStroke.getKeyStroke(KeyEvent.VK_D, ActionEvent.CTRL_MASK));
// Panel p1 to hold text fields and labels
JPanel p1 = new JPanel();
p1.setLayout(new FlowLayout());
p1.add(new JLabel("Number 1"));
p1.add(jtfNum1 = new JTextField(3));
p1.add(new JLabel("Number 2"));
p1.add(jtfNum2 = new JTextField(3));
p1.add(new JLabel("Result"));
p1.add(jtfResult = new JTextField(4));
jtfResult.setEditable(false);
// Panel p2 to hold buttons
JPanel p2 = new JPanel();
p2.setLayout(new FlowLayout());
p2.add(jbtAdd = new JButton("Add"));
p2.add(jbtSub = new JButton("Subtract"));
p2.add(jbtMul = new JButton("Multiply"));
p2.add(jbtDiv = new JButton("Divide"));
// Add panels to the frame
getContentPane().setLayout(new BorderLayout());
getContentPane().add(p1, BorderLayout.CENTER);
getContentPane().add(p2, BorderLayout.SOUTH);
// Register listeners
jbtAdd.addActionListener(this);
jbtSub.addActionListener(this);
jbtMul.addActionListener(this);
jbtDiv.addActionListener(this);
jmiAdd.addActionListener(this);
jmiSub.addActionListener(this);
jmiMul.addActionListener(this);
jmiDiv.addActionListener(this);
jmiClose.addActionListener(this);
/** Handle ActionEvent from buttons and menu items */
public void actionPerformed(ActionEvent e) {
String actionCommand = e.getActionCommand();
// Handle button events
if (e.getSource() instanceof JButton) {
if ("Add".equals(actionCommand))
calculate('+');
else if ("Subtract".equals(actionCommand))
calculate('-');
else if ("Multiply".equals(actionCommand))
calculate('*');
else if ("Divide".equals(actionCommand))
calculate('/');
else if (e.getSource() instanceof JMenuItem) {
// Handle menu item events
if ("Add".equals(actionCommand))
calculate('+');
else if ("Subtract".equals(actionCommand))
calculate('-');
else if ("Multiply".equals(actionCommand))
calculate('*');
else if ("Divide".equals(actionCommand))
calculate('/');
else if ("Close".equals(actionCommand))
System.exit(0);
/** Calculate and show the result in jtfResult */
private void calculate(char operator) {
// Obtain Number 1 and Number 2
int num1 = (Integer.parseInt(jtfNum1.getText().trim()));
int num2 = (Integer.parseInt(jtfNum2.getText().trim()));
int result = 0;
// Perform selected operation
switch (operator) {
case '+': result = num1 + num2;
break;
case '-': result = num1 - num2;
break;
case '*': result = num1 * num2;
break;
case '/': result = num1 / num2;
// Set result in jtfResult
jtfResult.setText(String.valueOf(result));
Mortgage applet code....
// MortgageApplet.java: Applet for computing mortgage payments
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import javax.swing.border.TitledBorder;
public class MortgageApplet extends JApplet
implements ActionListener {
// Declare and create text fields for interest rate
// year, loan amount, monthly payment, and total payment
private JTextField jtfAnnualInterestRate = new JTextField();
private JTextField jtfNumOfYears = new JTextField();
private JTextField jtfLoanAmount = new JTextField();
private JTextField jtfMonthlyPayment = new JTextField();
private JTextField jtfTotalPayment = new JTextField();
// Declare and create a Compute Mortgage button
private JButton jbtComputeMortgage = new JButton("Compute Mortgage");
/** Initialize user interface */
public void init() {
// Set properties on the text fields
jtfMonthlyPayment.setEditable(false);
jtfTotalPayment.setEditable(false);
// Right align text fields
jtfAnnualInterestRate.setHorizontalAlignment(JTextField.RIGHT);
jtfNumOfYears.setHorizontalAlignment(JTextField.RIGHT);
jtfLoanAmount.setHorizontalAlignment(JTextField.RIGHT);
jtfMonthlyPayment.setHorizontalAlignment(JTextField.RIGHT);
jtfTotalPayment.setHorizontalAlignment(JTextField.RIGHT);
// Panel p1 to hold labels and text fields
JPanel p1 = new JPanel();
p1.setLayout(new GridLayout(5, 2));
p1.add(new Label("Annual Interest Rate"));
p1.add(jtfAnnualInterestRate);
p1.add(new Label("Number of Years"));
p1.add(jtfNumOfYears);
p1.add(new Label("Loan Amount"));
p1.add(jtfLoanAmount);
p1.add(new Label("Monthly Payment"));
p1.add(jtfMonthlyPayment);
p1.add(new Label("Total Payment"));
p1.add(jtfTotalPayment);
p1.setBorder(new
TitledBorder("Enter interest rate, year and loan amount"));
// Panel p2 to hold the button
JPanel p2 = new JPanel();
p2.setLayout(new FlowLayout(FlowLayout.RIGHT));
p2.add(jbtComputeMortgage);
// Add the components to the applet
getContentPane().add(p1, BorderLayout.CENTER);
getContentPane().add(p2, BorderLayout.SOUTH);
// Register listener
jbtComputeMortgage.addActionListener(this);
/** Handle the "Compute Mortgage" button */
public void actionPerformed(ActionEvent e) {
if (e.getSource() == jbtComputeMortgage) {
// Get values from text fields
double interest = (Double.valueOf(
jtfAnnualInterestRate.getText())).doubleValue();
int year =
(Integer.valueOf(jtfNumOfYears.getText())).intValue();
double loan =
(Double.valueOf(jtfLoanAmount.getText())).doubleValue();
// Create a mortgage object
Mortgage m = new Mortgage(interest, year, loan);
// Display monthly payment and total payment
jtfMonthlyPayment.setText(String.valueOf(m.monthlyPayment()));
jtfTotalPayment.setText(String.valueOf(m.totalPayment()));
}Does it have to be an applet?
If you want the same behaviour as in the code with traffic lights, change
class MortgageApplet extends JApplet implements ActionListener {
to
class MortgageApplet extends JFrame implements ActionListener {
and change
public void init() {
to
public MortgageApplet() { -
I don't understand why iPhoto recognize the pictrures in the videocamera and iMovie doesn't recognize the videos and the videocamera.
I see all the pictures taken in iPhoto but I can't see any video in iMovie because I don't see the videocamera in iMovie.
I did the same operation several times in the past and always worked it out, with USB connection, I've tryed to restart the computer, to turn on and off the camera, to change cable, to change MAC: always the same problem!
Please is anybody so kind to help me ? Thank you!hi dlpmaster!
So, when it updates the program is working but then it sort of freezes. Then unfreezes and then again..
hmmm. what antivirus applications are you using?
as an experiment, does the freezing behavior still occur if you disable the antivirus prior to plugging your ipod in?
love, b
Maybe you are looking for
-
Sync address book with google and storm
I got a storm and have been having issues trying to get items to sync since pocketmac doesn't seem to work with the storm. Found a forum on crackberrry that tells you how to sync the calendar and address bock between the 3. I was able to get the cale
-
How do I turn off percent symbol in JFormattedTextField
I am using a custom JFormattedTextField field, that has methods to add masks which apply formatting and add suffix and prefixes. It allows the user to see the data in display mode (formatted) or raw (unedited mode) Just found a problem though with ou
-
I have been using iWeb to create and maintain fairly simple web sites. One of them is http://www.getalifesports.com and up until recently everything has been working fine. Recently I noticed that if I type the website name into the Safari address b
-
Picking up wrong segment value during FICA document Posting
Hi, When we are posting any FICA-document manually(FPE1) the segment is getting drived corrcectly for the line items, but issue is happening when the document is getting posted during Invoicing. Everytime it fetchs a default value for segment irrespe
-
Windows Will Not Stay Selected
Menu bar app windows, as well as other windows will not stay selected. To type on some of these windows, I have to click on the window after every letter or else it will become unselected.