I could use some hlep with a simple script to add a contact to a group

Aloha,
I am using Apple's Mail. I have a special email address set up (add-hiker@...) to add someone to my group of hiking friends in my address book. I would like to automate the process. Can someone please give me some guidance? I am a strong programmer, well, I was years ago, but I don't have much experience with Applescript. I'd also like to write a similar rule to remove a contact from the hiking group when they send an email to remove-hiker@...
TIA,
Thad

Save the source code below; and via 'Mail's 'Preferences' 'Rule' setting - locate the resultant save file as the AppleScript script to call when an e-Mail message is received by 'add-hiker@...'.
-- Code starts here.
property hikingGroup : "Hiking Group" -- Assumed name of 'Company'.
using terms from application "Mail" -- Focus on 'Mail' commands.
on perform mail action with messages tMessages -- Execute on a 'Rule' activation.
-- Obtain 'hikingGroup' account list. The list should contain only one entry.
tell application "Address Book" to set tPersons to (every person whose name is hikingGroup)
repeat with i in tMessages -- Cycle through received e-Mail messages.
set tSender to (sender of i) -- Obtain 'Sender's e-Mail address.
tell application "Address Book" -- Focus on 'Address Book' commands.
repeat with j in tPersons -- Cycle through every 'hikingGroup' account.
-- Add a new e-Mail message with a 'Work' label, and e-Mail address of 'Sender'.
make new email at end of emails of j with properties {label:"Work", value:tSender}
end repeat
quit -- Quit 'Address Book'.
end tell
end repeat
end perform mail action with messages
end using terms from
-- Code ends here.
Edit the code according to your particular needs.

Similar Messages

  • Powerpoint presentation I have stored in icloud until recently were syncing to Keynote on my iPad with no problem.  Now when I open Keynote on my iPad there is nothing.  I could use some help with this problem.

    powerpoint presentation I have stored in icloud until recently were syncing to Keynote on my iPad with no problem.  Now when I open Keynote on my iPad there is nothing.  I could use some help with this problem.

    Morning AndreD86,
    Thanks for using Apple Support Communities.
    These articles explain exactly what is backed up by using their method.
    iTunes: About iOS backups
    http://support.apple.com/kb/ht4946
    and
    iCloud: Backup and restore overview
    http://support.apple.com/kb/ht4859
    Also we want to double-click the Home button and swipe the Task Bar to the right.
    Then make sure the button on the far left of Task Bar is not muted.
    Best of luck,
    Mario

  • I could use some help with my html5 and my video

    Hello all.
    I've been reading up and working on my video issue for days.  I feel like I'm very close.  ANY help would be huge.
    I've got two websites.  Both of which have videos which my clients wants to be about to see on his mac, his PC and his iPhone and iPad.  He's a multi-platform guy living in a multi-platform world.
    The first website, has two videos on it.
    http://www.ftworthfoundation.com/index2.html
    It is very close to working... I can view all videos locally on safari and firefox.
    However remotely I cannot see any videos with firefox.
    Remotely- I can see all videos with Safari and IE and 1 video on the homepage with my iPhone.  My first thought on this was that the video which wouldn't play was too large.  I read somewhere that the iPHone will not load anything over 20MB... the .m4v was 33MB so I cut it down to about a 3rd of the size and re uploaded it (at 6.6MB) but it will still not play on my iPhone
    here is my code for the videos.  The video is formatted in .ogg, .mp4, .m4v and .flv... all videos are uploaded to the root directory.
    <div id=Video1>
         <video controls width=448>
            <source src="excel_Construction_Commercial.ogg" type="video/ogg" />
            <source src="excel_Construction_Commercial2.mp4" type="video/mp4" /> 
                <source src="excel_Construction_Commercial.m4v" type="video/m4v" />
            <embed src="excel_construction_commercial.flv" type="application/x-shockwave-flash" width="448" height="249" allowscriptaccess="always" allowfullscreeen="true"></embed>
        </video>
        </div>
          <div id="VideoPlayer">
            <video controls width="448"> 
                <source src="Foundation_Repair.ogg" type="video/ogg" />
    <source src="Foundation_Repair.mp4" type="video/mp4" /> 
                <source src="Foundation_Repair.m4v" type="video/m4v" />
              <embed src="Foundation_Repair.flv" type="application/x-shockwave-flash" width=448 height="249" allowscriptaccess="always" allowfullscreeen="true"></embed>
            </video>
            </div>
    If anyone can help me on this I can probably tackle the 2nd website solo.
    Thanks guys.
    -D

    Hi David.
    Thanks for the reply.  I am definitely moving the right direction.
    I have changed my extensions but the video will still not play remotely.  It does play locally.
    Here is my new code
      <video controls width="448">
                <source src="Remodeling.mp4" type="video/mp4">
                <source src="Remodeling.ogv" width="448" height="298" type='video/ogg; codecs="theora, vorbis"'>
                <source src="Remodeling.m4v" type="video/m4v">
                <embed src="Remodeling.flv" type=application/x-shockwave-flash wIDth="448" HeIGHT=249 alloWScRIPTACCESs="always" aLLOwfUllSCREeN=true></EmbEd>
                </div>
    I'm thinking I have a MIME type issue as I read this article online.
    Here is a link
    http://diveintohtml5.org/video.html
    It's a great website for anyone looking to understand how to create and export video to html5.
    Anyway here is the section of article I'm interested in.
    What’s the proper MIME type? You’ve already seen it; it’s part of the value of the type attribute on a <source> element. But setting thetype attribute in your HTML markup is not sufficient. You also need to ensure that your web server includes the proper MIME type in the Content-Type HTTP header.
    If you’re using the Apache web server or some derivative of Apache, you can use an AddType directive in your site-wide httpd.confor in an .htaccess file in the directory where you store your video files. (If you use some other web server, consult your server’s documentation on how to set the Content-Type HTTP header for specific file types.)
    Can anyone tell me how to change my MIME type? I can see my .htaccess.html file and I tried adding in
    AddType video/ogg .ogv
    AddType video/mp4 .mp4
    AddType video/webm .webm
    But the server will not let me upload the new .htaccess file.  So I cannot change it.
    I'm using GoDaddy and have complete admin rights rights as far as I can tell.
    Again.  Any help is greatly appreciated.

  • Serious Ethernet problems I could use some help with please.

    Good day.
    After about two weeks of trouble shooting I replaced the AP card in my MacPro.
    No good, still not seeing networks.
    I tried as a troubleshoot, plugging in a AP Express via Enet into my MacPro, it was seeing the Enet port for a while but now shows, via the Network prefs, that nothing is plugged into either Enet 1 or 2 ports. I've tried both.
    I've done the usual, trashed the plist files, reset the PMU button/ctr-cmd-P-R etc., all with no avail.
    Coupled with the orig problem of the MacPro and AP card setting an "Internet IP" number I'm thinking I have some type of ethernet "board" problem.
    Can any give any suggestions short of bringing this beast in please?
    Thank you much.
    Tom

    i haven't had ethernet on my pro since last year. I've tried over 25 configurations and tests and still, the leopard system im using has broken ethernet.
    from this, this is what im going to ask/suggest.
    1) reinstall another copy of leopard (retail) on another hard drive. No migration assistant. I did this and i had ethernet again. But a virgin system and litterally days to reinstall everything. (which i didn't do). But the test worked.
    2) or if you have a working version of tiger, try it to test (you don't mention which macpro you have. some had tiger)
    3) have you tried networking with ethernet cables, just to see if that works? Not the AP, but directly to a router or another mac.
    4) if you have access to a dock/enclosure and another mac, try booting that other mac with your hard drive. If you have access, then its not the system, but the ethernet hardware in your pro.

  • Could use some help with my ipod

    Well my sister got a video ipod so she didn't want her ipod so i figure hey what the heck give me it .Anyway i got this charger but no way to use it how do i charge my ipod
    http://i12.ebayimg.com/05/i/06/65/01/38_1.JPG
    What plug goes into that or can i charge my ipod with the same plug used for transfering songs or no.

    Try this:
    http://store.apple.com/1-800-MY-APPLE/WebObjects/AppleStore.woa/wo/StoreReentry. wo?productLearnMore=M9837LL%2FA
    it should work better then a firewire cable or try this:
    http://www.radioshack.com/product/index.jsp?productId=2191864&cp=&kw=ipod+alarm& parentPage=search
    It is awesome it charges your ipod, plays your music, and has an alarm clock in it that can play to your music and it has a fm/am radio in it. Buy it it is worth the $money$
    David

  • Could use some help on positioning images

    With help here, I'm making my way through ID novice to ID "dangerous". I sorta get layout and sorta get styling and now could use some help with sizing and positioning images.
    The test is a 3-column newspaper that I let ID size when the document was created. All the text frames are linked. I now want to put some images on the pages and have the text wrap. I sorta understand wrapping and anchoring, the question is sizing.
    Am I on the right path to start thinking that images often need to be sized to a column width or two (plus gutter)? If so, do I size images based on the frame size? For example, the columns show as 3.2222in and the gutter as .1667. Does that mean I want to set the image width to 3.2887 or are things just not that accurate? What are the best practices?
    One related question on wrapping: it seems like anchoring the image allows wrapping around only one frame of text but not the other if the image spans two text columns. How do you place and image so that it wraps text in more than one column?
    Also, do people make the image smaller than the frame to put a border in when wrapping text?
    Thanks
    Tom

    Are you asking about image size as it is saved, or as placed on the page?
    With older RIPS it was common to want to save images at the correct dimensions so when placed at 100% they would have the correct resolution. This was to reduce processing time. Today that is less of an issue and it is not at all unusual to scale images in the InDesign layout. (I'm talking raster here -- vector objects can be scaled almost infinitely.)
    So, what is the correct size? There are a number of rules of thumb, but the basic one is that images should be placed so that the resolution, at the size they will be printed, is twice the value of the linescreen being used. Anything in the range of 1.5 to 2.5 is probably acceptable, and I know people who routinely send images at 1.4 times the linescreen.
    For coated papers and reasonably good reproduction, 150 lpi is not unusual, with 200 lpi for fine art books, so you get the common suggestion that images should be 300 ppi. Newspaper printing is usually accomplished on fairly porous stock at much lower screen frequencies -- 80 to 100 lpi -- so you need considerably less image resolution.
    How do you know what the resolution is at the size you've place the image? Look at the info panel with an image selected. You'll see too numbers, an "actual" ppi and an "effective" ppi. The actual number is simply the resolution recorded with the image at its dimensions when it was saved (and digital cameras often save images 20 inches or so wide at 72 ppi) and is basically irrelevant. The effective ppi is the one that matters. If it's too small, either reduce the size of the image on the page, or be prepared to live with less than stellar reproduction. If it's grossly over the requirement it usually won't hurt except for some increased processing time, but the extra image data won't improve things as it gets discarded by the RIP.
    It's usually OK to downsample an image in Photoshop, though you will sometimes lose fine detail or subtlety in shading, but you'd probably lose the same things through scaling in ID. Upsampling never helps.
    I presume you know that you can place graphical objects in several ways, either into an existing frame, at full size (whatever that happens to be and at the "actual" resolution) by clicking the loaded cursor on an empty spot on the page, or you can click and drag a new frame the size you want. When an image is first placed it will always be "actual size" unless some scaling factor has been applied to the frame in advance, so you may not see the entire image. You then have several fitting options available to either make the frame fit the image or the image fit the frame (and in newspaper work you pretty much only want to fit to or fill the frame proportionally).
    I personally like keeping the images snapped to the column grid, but it's by no means an iron-clad rule. You want to avoid situations, though, where an image impinges on a column to the point that the remaining text is unworkably narrow.
    I don't know why you are using anchored frames for your images (text wrap only affects text in the frame after the anchor point). It's not likely in a newspaper that you would want the pictures to move on the page if you edit the text. You can group the image, caption and story, if you like, so that they all stay together if you need to re-arrange the page or move them to a new location.
    I don't know if I answered your question. Feel free to come back for clarification.
    Peter

  • I have two macs, i was able to install mavericks on my 17", i can't do it with my 13" MacAir, I get a drop down box after i login, I could use some help. George

    I have two macs, i was able to install mavericks on my 17", i can't do it with my 13" MacAir, I get a drop down box after i login, I could use some help. The drop down box says, unknown error, George

    Welcome to the Apple Support Communities
    Pages for the iPad and Pages for a Mac are completely different, so you have to purchase them twice, one for the iPad and another one for the Mac. The only advantage is that, if you buy another iPhone, iPod touch or iPad, you will be able to install Pages for free on all of them.
    As you are running Mac OS X 10.6.8 on the MacBook, you can't purchase Pages from the App Store, so you have to buy iWork '09 on a DVD on Amazon or eBay in order to install it

  • Multi-camera shoot.. having import issues, could use some work flow advice

    Okay, so I am doing some multi camera shoots. I have 2 Canon HV20's and 1 Canon HG10. The HV20's are being captured at HDV 1080i setting (1440x1080), and the HG10 is being logged and transferred coming in at it's different setting, (can't remember off hand what it is)
    I am syncing these 3 with "in points", however becasue the HG10 is a different format I can not use it to do a Multiclip with, I have been using QT to convert it to HDV 1080i, but a 60 minute record seesion is taking 7 hours for the convert.
    is there an easier way to get the AVCHD data from the HG10 to match the captured info from the HV20 tapes, or os there a setting to tell FCP that the multiclip doesn't need to use the same settings?
    Or does someone have a better workflow I could use...?? I understand that just buying anothe HV20 would solve the problem, but I can't afford that right now, so I'm etiehr stuck only shooting with 2 cameras or wasting the time of converting to use the 3rd different format camera..
    I could use some help or advice, thanks
    also, I haven't been able to set my capture in's and out's and do a batch capture with the HV20's... I keep having to "capture now" to get the footage, I always get an error as soon as I tell the batch capture to start
    Message was edited by: Chris Fritsche

    understand that just buying anothe HV20 would solve the problem, but I can't afford that right now,
    so I'm etiehr stuck only shooting with 2 cameras or wasting the time of converting to use the 3rd
    different format camera..< </div>
    The simple most direct route is to dub (or convert) your odd camera to the base camera's format (or convert everything to a single format). It's not a waste of time at all; simple and immediate and solves everything.
    bogiesan

  • I could use some advice and perhaps some help

    i recently brought iphone 4 apparently you need snow leopard for your mac to work so i went to best buy brought snow leopard i tryed installing it my mac saids i need to upgrade my ram so for me to have my iphone 4 i need to do these things my question is if i make an appointment in the apple store genus bar how quickly do you guy think they can resolve this issue meaning a few min to a few hours or days please could use some advice also if you happen to know a work around that would be appreciated
    i am also have trouble sycing any type of video podcast or movies from my library to my iphone 3g i am using macbook g4 i think

    SuperMarioNES wrote:
    i recently brought iphone 4 apparently you need snow leopard for your mac to work so i went to best buy brought snow leopard i tryed installing it my mac saids i need to upgrade my ram so for me to have my iphone 4 i need to do these things my question is if i make an appointment in the apple store genus bar how quickly do you guy think they can resolve this issue meaning a few min to a few hours or days please could use some advice also if you happen to know a work around that would be appreciated
    i am also have trouble sycing any type of video podcast or movies from my library to my iphone 3g i am using macbook g4 i think
    You can not run snow leopard on non intel macs. You have a g4. Ip4 requires leopard 10.5 not snow leopard so return it. You should not need more RAM how much does your machine have?

  • Could someone please sketch out this simple script for me?

    Could someone please sketch out a simple java script for me. I will have a document with one background
    layer and a layer set (group) called "Analyze" that consists of 63 adjustment layers. The layer names in that "Analyze" group(folder) will be
    "01" ...through "63" with 01 on the bottom and 63 at the top. Initially, all of the adjustment layers will be invisible and  the
    group will be closed (not expanded). I need a simple  script that will check for the first invisible layer in that group
    and make it visible without selecting that layer nor expanding the group. The script has to check
    for the first invisible layer every time it runs because other actions may have turned off a layer in the set.
    The point of this is so I can hotkey flipping on the layers one at a time without expanding the set or
    changing focus off the  background. It seems it should be a simple loop, but I just can't wrap  my head
    around all the objects (e.g. Layer as opposed to Layers  and  Artlayer as opposed to Artlayers)
    and the constants constants.
    for (i = 63; i>0; i--){                 /* I have found layer indexes 0 are the topmost layer */
      if( layerset[i] == INVISIBLE){
               layerset[i] = VISIBLE;
                  break;
    Could someone please write me a simple script that would do this?
    Edit I found this and its very close to what I need:
    var doc = app.activeDocument;
    for(var i = 0 ; i < doc.layers.length;i++){
      doc.layers[i].visible = (i % 2 == 0);
    From here : Function to show/hide layer with Photoshop script (JSX) - Stack Overflow
    In my case I would rewrite it to this
    for(var i = 62; i >=0; i--){
         if(  !doc.layers[i].visible){
              doc.layers[i].visible =TRUE;
              break;
    My problem is I just need  to traverse the layers in my layerset "Analyze"
    How do  I reference just those? Is there a doc.layersets["Analyze"].layers[i].visible = TRUE?
    Message was edited by: Shawn Laughlin To add more information

    Well this works:
    var doc = app.activeDocument;
    var analyze = doc.layerSets.getByName("Analyze").layers
    for(var i = 62 ; i >= 0; i --){
        if (!analyze[i].visible){
            analyze[i].visible =1;
            break;
    Hard to believe TRUE is not a constant in java.

  • Never owned a Mac, thinking of buying a Mac Pro, could use some advice...

    Hey guys,
    I know this was a lot to read, but I sincerely hope someone will take the time to answer my questions:
    As the title of my post implies I've never owned a Mac in my life. I've always built my own desktops and usually gone to HP or Dell for my laptops. I'm approaching that time again where my custom-built desktop is looking outdated and I'm getting the upgrade itch. I'm looking at all the parts I need to order to build a computer and I can't help but think I'm older now with a full-time job and a one year old daughter in the house. Do I really want to go through the hassle of building a desktop from scratch again? Not really. So I started evaluating things a bit. As I get older I’m really just getting sick and tired of Microsoft’s antics (Vista was a huge disappointment for me) so I decided this could be the year for me to take the Mac plunge.
    Now I’m an IT guy, so I have a pretty atypical setup at home. I’m currently running both Windows and Linux on all my computers. Rather than dual boot or use virtualization software I have a pretty intricate system in which I use a product called Acronis Trueimage to experiment with operating systems. What I do is perform a a clean install on an operating system, tweak it as needed for security and to use resources on my LAN than back up the customized OS install to a server a an image file. I have pre-built images for XP, Vista, Ubuntu and OpenSuSE that I can roll out to one of my machines in an average of 15 minutes whenever I get the urge to switch operating systems. I also serve all my data off a NAS box, so since data and OS are kept separate on the network I don’t have to worry about erasing something when I swap between Linux and Windows (as loading an image literally destroys the previous OS install).
    So you can see I’m pretty highly specialized. I even have things down to the point to where I have custom images for specific purposes. For instance I have one XP image customized for development, one XP image customized for gaming, etc. Naturally if I got the Mac Pro I’d like to have the freedom to create a similar set of custom OS deployment images (Windows, Linux and OSX) for it as well. In researching the Mac Pro I have some concerns my current system might not work if I go that route. Am I correct in assuming that in order to run an alternative operating system on a Mac I’ll have to run boot camp or something like it? Or upon unboxing my Mac and tweaking Leopard will I be able to use disk imaging software to make a backup image of my preinstalled Leopard hard drive and then do a clean install of Windows XP or Ubuntu and set it up to function like a PC? I guess I’m asking if it’s possible (now that Macs are Intel-based) to run Windows or Linux exclusively on the Mac hardware?
    Also I have some concerns about the proprietary nature of the Mac platform. From what I can gather in my research it seems the hardware is pretty locked in. One area that has me really concerned is gaming. I pretty much use Ubuntu exclusively at home for productivity and web surfing. However I still like to load that XP image every now and then to play some games on the LAN with my buddies. I’m not a fan of virtualizing for gaming because of the obvious performance hit you take, so I’d have to be able to run Windows XP free and clear. Also I checked Nvidia’s site and I see no OSX drivers listed there for their cards. Under the Windows platform they are always releasing driver updates to squeeze more game performance out of your card. What if I want to upgrade my video card? How do drivers work on OSX? Does Apple just integrate drivers for just a few specific video cards into the OS? Will I be stuck only able to pick from a handful of video cards approved by Apple?
    Thanks in advance to anyone who can offer advice!
    Message was edited by: ZeusABJ

    Hi Zeus
    I may be able to answer some of your questions. And sorry in advance if this sounds like yet another of those "religious conversion" stories
    I'm a software developer/architect, mostly doing Microsoft .NET/C#/Web Services coding. I'd been a loyal Microsoft guy since I started on the original IBM PC back in the 80's. Like a lot of people (or so it seems) I just got fed up with Microsoft's high-handed and self-important ways. More importantly, the company always seemed to be lagging behind technically. Looking at beta versions of Vista did not bode well for the future - it just seemed awful. When Vista came out it it was the last straw - I just could not get enthusiastic about this bloated, slow, mess of an operating system. I really hated it. Still do. Even with a top-spec machine, Vista didn't run in the snappy, responsive way it I thought it should. Nothing seemed well thought out.. yuck!
    Then, by chance, I was staying for a few days with somebody who had a Mac. Now, for years and years I not even considered Macs as remotely serious machines. My only experience of them was in the late 80's when somebody at work had one. He took delight in pushing a floppy disc into the machine so that it would respond "Ah, it's so big!". Great, just a toy. Not for serious programming work. So, encountering Mac OS X Tiger on my friend's iMac was something of a shock. It was so responsive, clean and elegant. When you turned it on it only took about 30 seconds or so for the thing to be ready for use, etc, etc.
    Long story short, I bought an iMac, then a newer, bigger, faster iMac, then a MacBook Pro and now I have a Mac Pro. I still have to work with Windows to do my .NET-related day job. But 95% of the time I work on the Mac using various VMWare virtual machines. I can switch between Windows Server 2008, Windows Server 2003 and Windows XP in a few seconds and still be working in a Mac environment. And the performance of running Windows inside VMWare is even better than on my dedicated top-spec Windows laptop! I have a selection of virtual machines to choose from and, because these virtual machines are just files, I can back them up, revert to saved copies, etc. I've tried Bootcamp but it's much less convenient and performance inside the virtual machines is never an issue (although I don't do any gaming). So, you could keep virtual machines on your NAS box or local Mac hard drive.
    With regard to graphics drives, etc. I've never had any problems whatever in this respect. For example, when I installed Windows XP on VMWare it automatically recognised all my hardware (including some obscure audio interfaces, USB-based MIDI interfaces, etc.) and made it available. I must admit that when I was new to the Mac I expected to have driver issues, but never have had... So, my guess is that you'll be able to run all your Windows and Linux distros on the Mac without too many problems.
    You mention Apple's hardware as being "locked-in". I don't think that's the case. Certainly the consumer Mac models like the iMac can't be upgraded (by you or me) internally, expect for memory. The Mac Pro though is very easy to upgrade - though there may be some limitations with regard graphics cards.
    Re your questions about graphics card drivers. Yes, these come with OS X in just the same as as with Windows. Because I've also used the card that comes "with the box" this has not been an issue for me. However, unless you get a Mac Pro you can't swap-in your existing graphics card. And even then I think you may find restrictions. However, other, more knowledgeable Mac users on this forum may have other thoughts.
    Overall though, the experience of using the Mac in terms of software is very much the reverse of Windows - the OS is very open and well documented. It really is an IT person's dream machine - so much to fiddle around with (particularly if you know anything about Unix!). Unlike Microsoft who charge a FORTUNE for their development tools, Apple give them to you for free. And very good they are too!
    Finally, one bit of advice. If you are considering buying a new Mac, join the Apple Developer Connection scheme as a Select member. It'll cost you around $400 to join but they give you a hardware discount for Apple-store purchased items that will save you a ton of $$$'s - absolutely definitely worth doing.
    Hope this helps (and good luck)!
    Russ

  • I think I've got a memory leak and could use some advice

    We've got ourselves a sick server/application and I'd like to gather a little community advice if I may. I believe the evidence supports a memory leak in my application somewhere and would love to hear a second opinion and/or suggestions.
    The issue has been that used memory (as seen by FusionReactor) will climb up to about 90%+ and then the service will start to queue requests and eventually stop processing them all together. A service restart will bring everything back up again and it could run for 2 days or 2 hours before the issue repeats itself. Due to the inconsistant up time, I can't be sure that it's not some trouble bit of code that runs only occasionally or if it's something that's a core part of the application. My current plan is to review the heap graph on the "sick" server and look for sudden jumps in memory usage then review the IIS logs for requests at those times to try and establish a pattern. If anyone has some better suggestions though, I'm all ears! The following are some facts about this situation that may be usefull.
    The "sick" server:
    - CF 9.0.1.274733 Standard
    - FusionReactor 4.0.9
    - Win2k8 Web R2 (IIS7.5)
    - Dual Xeon 2.8GHz CPUs
    - 4GB RAM
    JVM Config (same on "sick" and "good" servers):
    - Initial and Max heap: 1536
    -server -Xss10m -Dsun.io.useCanonCaches=false -XX:PermSize=192m  -XX:MaxPermSize=256m -XX:+UseParNewGC -Xincgc -Xbatch -Dcoldfusion.rootDir={application.home}/../ -Dcoldfusion.libPath={application.home}/../lib -Dcoldfusion.dotnet.disableautoconversion=true
    What I believe a "healthy" server graph should look like (from "good" server):
    And the "sick" server graph looks like this:

    @AmericanWebDesign, I would concur with BKBK (in his subsequent reply) that a more reasonable explanation for what you’re seeing (in the growth of heap) is something using and holding memory, which is not unusual for the shared variables scopes: session, application, and/or server. And the most common is sessions.
    If that’s enough to get you going, great. But I suspect most people need a little more info. If this matter were easy and straightforward, it could be solved in a tweet, but it’s not, so it can’t.
    Following are some more thoughts, addressing some of your concerns and hopefully pointing you in some new directions to find resolution. (I help people do it all the time, so the good news is that it can be done, and answers are out there for you.)
    Tracking Session Counts
    First, as for the observation we’re making about the potential impact of sessions, you may be inclined to say “but I don’t put that much in the session scope”. The real question to start with, though, is “how many sessions do you have”, especially when memory use is high like that (which may be different than how many you have right now). I’ve helped many people solve such problems when we found they had tens or hundreds of thousands of sessions.  How can you tell?
    a) Well, if you were on CF Enterprise, you could look at the Server Monitor. But since you’re not, you have a couple of choices.
    b) First, any CF shop could use a free tool called ServerStats, from Mark Lynch, which uses the undocumented servicefactory objects in CF to report a count of sessions, overall and per application, within an instance. Get it here: http://www.learnosity.com/techblog/index.cfm/2006/11/9/Hacking-CFMX--pulling-it-all-togeth er-serverStats . You just drop the files (within the zip) into a web-accessible directory and run the one CFM page to get the answer instantly.
    c) Since you mention using FusionReactor 4.0.9, here’s another option: those using FR 4 (or 4.5, a free update for you since you’re on FR 4) can use its available (but separately installed) FusionReactor Extensions for CF, a free plugin (for FR, at http://www.fusion-reactor.com/fr/plugins/frec.cfm). It causes FR to grab that session count (among many other really useful things about CF) to log it every 5 seconds, which can be amazingly helpful. And yes, FREC can grab that info whether one is on CF Standard or Enterprise.
    And let’s say you find you do have tens of thousands of sessions (or more). You may wonder, “how does that happen?“ The most common explanation is spiders and bots hitting your site (from legit or unexpected search engines and others). Some of these visit your site perhaps daily to gather up the content of all the pages of your site, crawling through every page. Each such page hit will create a new session. For more on why and how (and some mitigation), see:
    http://www.carehart.org/blog/client/index.cfm/2006/10/4/bots_and_spiders_and_poor_CF_perfo rmance
    About “high memory”
    All that said, I’d not necessarily conclude so readily that your “bad” memory graph is “bad”. It could just be “different”.
    Indeed, you say you plan to “look for sudden jumps in memory usage“, but if you look at your “bad” graph, it simply builds very slowly. I’d think this supports the notion that BKBK and I are asserting: that this is not some one request that “goes crazy” and uses lots of memory, but instead is the “death by a thousand cuts” as memory use builds slowly.  Even then, I’d not jump at a concern that “memory was high”.
    What really matters, when memory is “high” is whether you (or the JVM) can do a GC (garbage collection) to recover some (or perhaps much) of that “high, used memory”. Because it’s possible that while it “was” in use in the past (as the graph shows), it might no longer be “in use” at the moment . 
    Since you have FR, you can use its “System Metrics page” to do a GC, using the trash can in the top left corner of the top right-most memory graph. (Those with the CFSM can do a GC on its “Memory Usage Summary” page, and SeeFusion users can do it on its front page.)
    If you do a GC, and memory drops q lot, then you had memory that “had been” but no longer ”still was” in use, and so the high memory shown was not a problem. And the JVM can sometimes be lazy (because it’s busy) about getting to doing a GC, so this is not that unusual. (That said, I see you have added the Xincgc arg to your JVM. Do you realize that tells the JVM not to do incremental GCs? Do you really want that? I understand that people trade jvm args like baseball cards, trying to solve problems for each other, but I’d argue that’s not the place to start. In fact, rarely do I find myself that any new JVM args are needed to solve most problems.)
    (Speaking of which, why did you set the – xss value? And do you know if you were raising or lowering it form the default?)
    Are you really getting “outofmemory” errors?
    But certainly, if you do hit a problem where (as you say) you find requests hanging, etc., then you will want to get to the bottom of that. And if indeed you are getting “outofmemory” problems, you need to solve those. To confirm if that’s the case, you’ll really want to look at the CF logs (specifically the console or “out” logs). For more on finding those logs, as well as a general discussion of memory issues  (understanding/resolving them), see:
    http://www.carehart.org/blog/client/index.cfm/2010/11/3/when_memory_problems_arent_what_th ey_seem_part_1
    This is the first of a planned series of blog entries (which I’ve not yet finished) on memory issues which you may find additionally helpful.
    But I’ll note that you could have other explanations for “hanging requests” which may not necessarily be related to memory.
    Are you really getting “queued” requests?
    You also say that “the service will start to queue requests and eventually stop processing them all together”. I’m curious: do you really mean “queuing”, in the sense of watching something in CF that tells you that? You can find a count of queued requests, with tools like CFSTAT, jrun metrics, the CF Server Monitor, or again FREC. Are you seeing one of those? Or do you just mean that you find that requests no longer run?
    I address matters related to requests hanging and some ways to address them in another entries:
    http://www.carehart.org/blog/client/index.cfm/2010/10/15/Lies_damned_lies_and_CF_timeouts
    http://www.carehart.org/blog/client/index.cfm/2009/6/24/easier_thread_dumps
    Other server differences
    You presented us a discussion of two servers, but you’ve left us in the dark on potential differences between them. First, you showed the specs for the “sick” server, but not the “good” one. Should we assume perhaps you mean that they are identical, like you said the JVM.config is?
    Also, is there any difference in the pattern of traffic (and/or the sites themselves) on the two servers? If they differ, then that could be where the explanation lies. Perhaps the sites on one are more inclined to be visited often by search engine spiders and bots (if they sites are more popular or just have become well known to search engines). There are still other potential differences that could explain things, but these are all enough to hopefully get you started.
    I do hope that this is helpful. I know it’s a lot to take in. Again, if it was easier to understand and explain, there wouldn’t be so much confusion. I do realize that many don’t like to read long emails (let alone write them), which only exacerbates the problem. Since all I do each day is help people resolve such problems (as an independent consultant, more at carehart.org/consulting), I like to share this info when I can (and when I have time to elaborate like this), especially when I think it may help someone facing these (very common) challenges.
    Let us know if it helps or raises more questions. :-)
    /charlie

  • Could Use some help...

    Hey everyone, I was wondering if anyone would help me with this strange little problem I'm having.
    I'm 15 and taking a Java class at the local community college, and our current assignment is to make a String class for java. anyway, here is my string class:
    public class myString {
        private final int MAX = 50;
        private char[] mystr = new char[MAX];
        //constructors
        public myString() {
            char[] defstr = {'d', 'e', 'f', 'a', 'u', 'l', 't'};
            mystr = defstr;
        public myString(String str) { setStr(str); }
        public myString(char[] carray) { setStr(carray); }
        public myString(myString anotherStr) {
            mystr = anotherStr.get();
        //setters
        public void setStr(String str) {
            mystr = str.toCharArray();
        public void setStr(char[] carray) {
            mystr = carray;
        //others stuff:
        public char[] get() { return mystr; }
        //the lefts(maybe I did too many O_o):
        public char left(char[] carray) { return carray[0]; }
        public char left() { return mystr[0]; }
        public char[] left(char[] carray, int n) {
            char[] leftstr = new char[MAX];
            System.arraycopy(carray, 0, leftstr, 0, n-1);
            return leftstr;
        public char[] left(int n) {
            char[] leftstr = new char[MAX];
            System.arraycopy(mystr, 0, leftstr, 0, n-1);
            //System.out.println(leftstr);  <- this gave me a good report.
            return leftstr;
        public char left(String str) { return str.toCharArray()[0]; }
        public char[] left(String str, int n) {
            char[] leftstr = new char[MAX];
            str.getChars(0, n, leftstr, 0);
            return leftstr;
    }here is my main:
    import java.io.*;
    public class stringtest {
        public static void main(String[] args) {
            myString hfb = new myString("happy fun ball, still legal in 16 states!");
            char[] d00d = {'d', '0', '0', 'd', '!', '!', '1', '!'};
            char[] whatev = hfb.left(15);
            System.out.println(hfb.get());
            System.out.println(hfb.left("well, lets see this one", 6) +
                "\n" + whatev + "\n" + hfb.left(d00d, 4));
            System.out.println(hfb.lowercase("d00d, PWNED") + "\n" + hfb.uppercase());
    }and here is the report it produces:
    happy fun ball, still legal in 16 states!
    [C@119c082
    [C@1add2dd
    [C@eee36c
    [C@194df86
    [C@defa1a
    so I suppose you can already see my problem here. Now I put a println in myString. it was in the left(int n) function, just before the return statement. It printed "happy fun ball", so it worked. It was a good report.
    when I return it, though, it gives me some hexadecimal number with a crazy symbol in front of it.
    What throws me off more is that my get function works fine, and when I use it it shows a normal report.
    So, yeah. any help is greatly appreciated. This is due tomorrow(hurray for procrastination), so I could use help soon.
    Sorry if I seem to be rambling, its late, and I want to sleep :)

    hmm..
    I tried making one(which unfortunatly resulted in my direct use of the string class, rather than like an extra. I was hoping to avoid it), but it didn't change anything. Now I think I did something wrong, or perhaps I'm calling it wrong.
    will it automatically get used if I do something like System.out.println(myString.left(5));?
    Or do I have to get the left method to return a string?
    and why does get() work correctly?
    This whole thing is confusing me a lot, because it seems so inconsistent. I think its just evry language's deep, personal hatred for me :)
    any further help is also appreciated, and thanks for replying so quickly :)

  • Since I downloaded 4.0, FF has been very slow to respond to pretty much any request. It crashes quite often, and now after uninstalling it, and reloading it, I cannot even get it to start. sure could use some good advice.

    I had been using 3.something without any problems. After I downloaded 4.0 my troubles started. I would be reading the news in Yahoo and would click on the next page or news item and would get the message ' Oops, well this is embarassing'. Or when I would be looking for something, it would just lock up. When it would finally get to where I wanted to be, it was taking longer and longer to respond. Today, I can't even get it to open at all. Nothing else was altered or added or deleted that might affect FF.
    Hope this helps.
    My computer skill is low.

    That is a problem with an AVG extension (Tools > Add-ons > Extensions)
    See:
    * [[Troubleshooting extensions and themes]]

  • HT2509 i could use Burmese font with Zawgyi font in my previous iMac with Lion. Now I have a MacAir with Mountain Lion and i can not properly view Burmese fonts. Font book has 3 types of Burmese (myanmar) related fonts. Please help me to get proper displa

    I could read Burmese font with Zawgyi Font in my previous Mac Book with Lion. I have MacAir Retina display with MountainLion and could not read Burmese fonts. Font books have 3 fonts for Burmese font and all are enable. Please help

    pyoneaye wrote:
    Font books have 3 fonts for Burmese font and all are enable.
    What are the names of those fonts?  Have you downloaded and installed the special Zawgyi font?
    What is it exactly that you cannot read?  Can you provide the url?

Maybe you are looking for