Wikipedia:Reference desk/Archives/Computing/2012 April 27

= April 27 =

MS-Excel
What is MS-Excel? — Preceding unsigned comment added by Aadya mishra (talk • contribs) 05:14, 27 April 2012 (UTC)


 * It means Microsoft Excel. Bubba73 You talkin' to me? 05:37, 27 April 2012 (UTC)

iPhone Camcorder/iMovie
Why cannot i import camcorder films from my iPhone into iMovie please?--85.211.154.241 (talk) 05:56, 27 April 2012 (UTC)
 * Do any of these links help? If not, it would be useful if you told us the particular problem you are having and the version of iMovie and other software you are using. --Colapeninsula (talk) 09:04, 27 April 2012 (UTC)

iPhone3 and iMovie 11.--85.211.154.241 (talk) 15:12, 27 April 2012 (UTC)

Sorry, forgot to thank you for the links, I think that the first one will be helpful. — Preceding unsigned comment added by 85.211.154.241 (talk) 15:18, 27 April 2012 (UTC)

Leading spaces are stripped out of Access table
I am using Access 2007 and importing data from a .csv file into text fields in a table. Some of the text fields have leading spaces which are needed and I want to keep them but Access strips them all out when the data is imported. How can I stop this happening please? Gurumaister (talk) 07:39, 27 April 2012 (UTC)
 * Can you put quotation marks around the individual data items, including the leading spaces? Comma-separated values suggests this. --Colapeninsula (talk) 09:10, 27 April 2012 (UTC)

Unfortunately, I can't. The .csv is an export of a name and address file from another (non-Access) database so the data comes out without quotation marks. Surely having leading spaces stripped out should be a matter of choice and therefore optional? I am finding it very frustrating. Gurumaister (talk) 13:22, 27 April 2012 (UTC)


 * Access handles all unquoted spaces before data as just ignorable whitespace and ignores it. I don't see any way around that with Access's interface. Your options, as I see them, are 1. Have the other database spit out the data in a quoted fashion, or 2. Put together some kind of CSV pre-processor that adds the quotes in for you automatically. (The latter is only a moderately difficult scripting task, as far as scripting tasks go.) --Mr.98 (talk) 14:27, 27 April 2012 (UTC)


 * This Python script does that (blindly - even elements without whitespace get quoted anyway). It reads stdin and write stdout. -- Finlay McWalterჷTalk 14:55, 27 April 2012 (UTC)


 * Can you get an intermediate file between database 1 and 2 (this is in line with what 98 talks about as a pre-processor)? Shadowjams (talk) 16:02, 27 April 2012 (UTC)


 * Can you predict which fields should have leading white-space? If so you can write an update query in Access that re-adds the whitespaces back in as part of either the import routine or a separate query post import of data. ny156uk (talk) 13:52, 28 April 2012 (UTC)
 * Presumably the amount of whitespace varies in an unpredictable way, otherwise it would be a simple workaround to just tack on some whitespace. --Mr.98 (talk) 14:41, 28 April 2012 (UTC)

Python exception fail
Why isn't this exception caught?

try: j = "rgb".index(instring.pop(0)) ... except ValueError,IndexError: ...

Traceback (most recent call last): File "mug1.py", line 36, in    j = "rgb".index(instring.pop(0)) IndexError: pop from empty list

I tried unpacking the expression: ch = instring.pop(0) j = "rgb".index(ch) but that didn't help. —Tamfang (talk) 19:37, 27 April 2012 (UTC)
 * You need parens around ValueError,IndexError to make it a tuple. As it is you're catching ValueError into an object called IndexError. --Sean 19:48, 27 April 2012 (UTC)
 * I see. That's a feature I haven't used much. Thanks! —Tamfang (talk) 00:06, 28 April 2012 (UTC)