OS X Technologies :: Word Count Not Recognized As Integer Variable?
May 12, 2012
ok, i have this command:  set mywordcount to do shell script "wc -l < MyFile.txt" which gives me the number of words of a given txtwith display alert it reports me number 1 when there is one word, number 4 if there are 4 words, etc... the problem comes when i want to do one action if the file has 1 word, another if it has more than 1...when i write: if mywordcount = 1 thenmyactions hereelseotheractions hereend ifit doesn't do anything at all.
I am currently using automator to make folders named after the large numbers of images. I have everything set up and its working great but I am trying to make it more efficient.Â
I strip the filename to just the first part of the code eg "bmz12345" and make the folder from that.Â
However, In order to do this I have to create a dummy text file or folder somewhere named after the fulle code (bmz12345_black_1) and then strip it down (bmz12345) set a varible of the new filename and then create the folder in the desired location with the right name.Â
After getting the name of a finder item, Is it possible to change the text that is passed to it without creating a file out of it first?
How can one count only visible folders (one level down only) in the Finder?Â
The following script works fine except that it appears to count some invisible folders eg: when the selection is the startup disk the count is 6 although the actual number of visible folders is only 4. tell application "Finder"         set vSelection to selection as alias count every folder of folder vSelectionend tellÂ
I have tried various ideas such as "whose visible is true" but to no avail.Â
Assuming it is possible to perform a successful visible folder count, how could one then move between these visible folders in the Finder prior to performing a command (eg: open)?Â
I got rained on and my macbook got soaked. I dried out my macbook in an airtight container with some special salt for a few days, and luckily got rid of most of the water issues with my monitor. Unfortunately, my battery or logic board seems to have not been so lucky. My macbook is a one and a half year old 13" unibody, and now won't turn/stay powered on unless it's plugged in. For the first 15 minutes I've plugged in the magsafe charger, the battery is recognized. It says it's charging but stays at 0% (I then get the X over the battery icon). The weird thing is that my previously health battery now has a 0 mAh charge capacity and a 0 cycle count. Is there ANY possible solution to this, or has the damage already been done?
Im wondering whether its at all possible to display word count as one of the columns in finder or if there is a program that will let me do this? Basically in compiling a dissertation spread over 40 or so words docs and i need to be able to keep a running tab on word count. Continually putting them all into one big word doc just to grab a total is very time consuming.
I'm trying to help out a co-worker who writes the company newsletter, articles for our base and local newspaper, as well as employee profiles and articles for various projects we produce at my job. This lady comes from a newspaper background and she's looking for a Mac-based program that somehow calculates word count and lets you write for a certain space/word count. Trust me, she's not visually-oriented (or particularly font/layout savvy) in any way, so the easier and more straight-forward something is, the better. I don't know if a program like this exists (and affordable one, at that), but to be honest, she always overwrites and guess who's the guy who has to sit with her and back and forth edit and trial and error stuff?
Also, Mac OS X-native would be very cool, as Sandy is on an iMac and being that she's not stuck waiting on Photoshop and stuff, she's been using OS X for the past month or so and now that our order of Office v.X copies are on the way, she will be one of those lucky people who will probably never have to launch Classic to get her job done: Word and Entourage are the only things she really uses. Anyone know of a program like I've described above? Are any of you from a newspaper/magazine background or environment with some suggestions or advice?
I purchased a new MacBook Pro 17" with OS X Lion (10.7.2) preinstalled back in January of this year (2012). I migrated my user accounts from my old MacBook Pro 15" (2008) running OS X Snow Leopard. Almost right away I started having issues of all sorts, including Admin accounts that wouldn't allow me admin priveledges, hidden user groups, apps that wouldn't run, multiple obscure error messages and a host of other issues. After scouring forums like this one I used Disk Utility and not only discovered innumerable permission errors but also disk errors like these:Â
Invalid volume file count (It should be 1656658 instead of 1656636) Invalid volume directory count (It should be 345764 instead of 345743) Invalid volume free block count
[code]....
And now, this morning, after a month or two of all that... and after installing the Java Security Upgrade last night, I can't get into my accounts at all. On first boot-up it hung for 20 minutes before I shut it down. After running Disk Utility from Recovery Drive and repairing the drive I rebooted and got the log-in screen. I clicked on my user icon, typed the correct password, was shown they white/grey screen for a few flickering seconds then was brought back to the log-in screen. I rebooted to the Recovery Disk, ran Disk Utility, saw all the same errors again, repaired the disk, rebooted and got the same problems with logging in again.Â
I've repeated this cycle five times today, as both a normal boot-up and in "Safe Mode" all with the same results. I've repaired the disk using Disk Utility from Recovery Disk as well as accessing the disk in Target Mode, and always there are the same errors needing to be repaired.Â
I don't buy that I'm dealing with a hardware issue. My antivirus and security software are all up-to-date. What the heck is going on? Why do I keep having these disk problems? Why can't I access my accounts anymore? Why does it keep hanging during boot-up? Why am I about to throw the machine out my bedroom window?
Info: MacBook Pro, Mac OS X (10.7.3), MacBook Pro 17" (early 2012), Lion
My wife's macbook pro started shutting down by itself randomly, so i performed Disk Utility Verify Disk and found these errors: Invalid volume file count(It should be 800651 instead of 800653)Invalid volume directory count(It should be 191005 instead of 191003)The volume Macintosh HD needs to be repaired. Error: Filesystem verify or repair failed. As i do not have the Mac OS Leopard disks physically with me, I target-disk started her mac on my mac, and use my mac to run Disk Utility on her hard-disk, and repaired the disk without problems.Â
However, this is the 3rd or 4th time this has happened. After the 1st time, i figured something is causing it, so i checked this forum, and found that for some, the Blackberry Messenger app causes programs, so i promptly uninstalled it fully (including associated system files) and this problem didnt come back for a while. Or could this be a sign the hard disk is physically failing soon? It is out of warranty now. We have regular Time-machine backups. We are actually kinda waiting out until the new line of macbook pro's come out..
Laptop stats: MacBook Pro 15" 2.4 GHZ Intel Core 2 Duo 2 GB RAM HDD: 250GB Graphics: NVDIA GeForce 9400M VRAM 256MBÂ OS: Mac OS Leopard
I'm creating a Service in Automator, and would like incorporate an Apple script that will "cut" the first word in any Numbers cell that I select, and "paste" it into the cell directly to the left of the the cell I've selected. Let's assume the column I'm selecting from is Column C. As a very rough start, here is what I have (with some of things I'm trying to accomplish in brackets): on run {input, parameters} try set MyText to input as string set FirstWord to first word of MyText set [remove the first word and a single space from what I've selected]tell application "Numbers"tell table 1 of sheet 1 of document 1 set theRow to [the row of the cell I've selected] set value of cell 3 of theRow to FirstWord end tellend tell end try return inputend run.
Are the hard drives variable in each model? Any chance that people who have received theirs could post which model and hard drive it came with, to get an idea of what each is shipping with?
When moving the mouse about, if you are moving it slowly, the mouse pointer hardly moves atall, is there a way to disable this variable tracking speed affect?
I'm animating a PNG file in a FC7 project. The image goes from one side of the screen to the other, and I would like to use the ease controls to smooth the movement, but the program does not allow me to do it in the control + J window. I can do it with a video clip, but not with this single frame animation. Is there a way a can do that?
Macbook Pro (2014) when I work with Microsoft office, Word, and use the "command v" keys the entire Word doc freezes and I need to reboot entire computer. What is this?
I start Microsoft Entourage, the software opens at least 17 windows and sometimes more.When I click on the upper section of a window in Safari, or Word, the window folds to the dock and when I click on a word, the entire word is selected.
I have a Mac OS X version 10.5.7 i am working on Word 2008 for Mac, version 12.0.1 (080305).
My problem, i created one text box in a document, somehow 2 more appeared. I made the mistake of thinking that to delete the extra text boxes, i simply highlight them and delete them. Silly stupid me, nothing that simple exists and i have wasted an hour trying to figure it out. The help button does squat, barely gives you any info on a text box much less trying to delete it. Does anyone know how to delete a text box in a word document?
i'm looking at moving over to the Mac in a couple days and i just need to know the best free Word Processor that can open .doc files. 99% of my docs made in Word are of the 97-2003 variety and not 2007's .docx.Â
My university wants us all to use RTF files. As I am sure you all know text edit sucks.But it automatically opens all my RTFs.I have to manually get word to open them which is a pain in the ass.How can I fix this so that all RTF's are automatically opened by WORD?I am still on the old version of word because I have to use ENDNOTE - which has no support for Word 2011 right now. I have a copy of 2011 sitting on my desk and I am itching to use it, but I will loose 200+ citations if I do.
Perhaps this has been answered before but nothing turned up in my search. I'm a Mac convert switching from MS XP, where I was using Word 2007. Over time, I compiled several special dictionaries. If I switch to Office 2008 for Mac will I be able to transfer these from Word 2007?
I understand that Word for Mac does not ahve VBA support, therefore no macros like in Word 2007. Does office 2008 (Word) have some sort of macro capability.
I have a MacBook. Last week I bought Microsoft Office for Mac. I would like to open documents sent in Word to be opened in Word. But my mac converts them to Pages.
Info: MacBook, Mac OS X (10.7.4), Microsoft Office for Mac
Today I went into my bookmarks page and decided to see if anything was in RSS, The only thing was google news. So I double clicked on that, it took several long seconds to pull up google news. When I back out to my bookmarks page I noticed that the number of bookmarks next to bookmarks bar said zero or nothing! It should have said 6101! Does anyone know why this would happen?
I am seeing last played as accurate but play counts are either not registering at all or they are registering and then disappearing at a later date. Â
Should I disable iTunes Match? I like having my playcounts!!Â
My 11 month old macbook pro (2011) was recently sent under warrenty for Harddisk SPIN RETRY COUNT value increase. They changed the harddisk and installed new Toshiba harddisk. Which ran 100% S.M.A.R.T health for two weeks and now it is showing same Spin retry count problem. I am thinking its not the harddisk but something else is causing the problem( may be power supply problem). I am from nepal so it takes a lot of effort to send it in for repair.
Any ideas on this...my Imac (2.16 Ghz. running system 10.6.8) has bee having difficulty in starting up (lost of hard drive noise and crawling to start up) lately and I have Drive Genius 3 as a diagnostic tool, so I ran "Repair" and "Verify Permissions" and came up with the message" Permissions Error : ARDAgent. app....I gathered some info on these boards to use the app Pacifist (V 3.0.2), to re-install the ARDAgent and it should clear up the problem...followed the plan, ran Verify Permissions in Drive Genius 3, which said it was repaired...I then ran Verify to confirm and came back with Verify Failed, Invalid Directory Count, should be 38 instead of 39, and should be 47 instead of 45...But am getting the same results when I run Drive Genius 3 which is the Volume is repaired, but the Verify has failed.... A real stumper...any ideas? Also just up graded to Firefox 12.0 which is when the slowdown started to appear
13-inch, Aluminum, Late 2008 battery wasn't holding a charge based on the fact that its been used and abused since 2008. Around the same time (2 months ago) my MagSafe power supply started becoming frayed and damaged. So, I decided to buy both a new power supply and battery. I bought the power supply from Apple.com and the battery from Best Buy. Ever since my new purchase I no longer get a count down on my remaining battery level. It either says (charged) or (Not Charging) based on if I have the power supply plugged in. If I leave the power supply out and the battery dies it no longer goes into the power save mode. Now it just turns my laptop off. I have tried a couple things like SMC reset but no luck. Any suggestions? Maybe I am doing the SMC reset wrong? I unplug the MacBook and take the battery out and hold down the power button for 5 seconds. I cant tell that its done anything. Another problem that started happen more recently.. When i close the lid of my MacBook it seems that its no longer going to sleep. The fan is running high and the battery dies..Â
Info: MacBook, Mac OS X (10.7.4), 13", Aluminum, Late 2008 - MacBook