Wikipedia:Reference desk/Archives/Computing/2009 May 5
Computing desk | ||
---|---|---|
< May 4 | << Apr | May | Jun >> | May 6 > |
Welcome to the Wikipedia Computing Reference Desk Archives |
---|
The page you are currently viewing is an archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages. |
May 5
[edit]Need help with ASP
[edit]Hi All,
I working on getting a basic email sent from a website hosted at volusion.com.
They don't provide access to CDO, and but they did give an alternate solution: an 'smtp' class of their own. Am getting an error tho, but their support isnt very good so I'm trying here.:
The what i have so far (the class is from volusion.com):
<% Class vsmtp Public VsmtpKey Public EmailSubject Public EmailFrom Public EmailTo Public TextBody Public HTMLBody Private Attachment Private AttachmentFolder Public Sub AddAttachment(ByRef FilePath) If AttachmentFolder = "" Then AttachmentFolder = Server.MapPath("/v") End If If StrComp(Left(FilePath,Len(AttachmentFolder)),AttachmentFolder,vbTextCompare) = 0 Then FilePath = Replace(Mid(FilePath,Len(AttachmentFolder)-1),"\","/") End If If StrComp(Left(FilePath,3),"/v/",vbTextCompare) <> 0 Or InStr(FilePath,",") > 0 Then Err.Raise 512, "vsmtp.AddAttachment", "Invalid Attachment Path" End If If IsEmpty(Attachment) Then Attachment = FilePath Else Attachment = Attachment & "," & FilePath End If End Sub Public Sub Send() Dim HTTPRequest Set HTTPRequest = CreateObject("WinHTTP.WinHTTPRequest.5.1") HTTPRequest.Open "POST", "http://" & Request.ServerVariables("LOCAL_ADDR") & "/vsmtp.asp", False HTTPRequest.SetRequestHeader "Content-Type", "application/x-www-form-urlencoded" HTTPRequest.SetRequestHeader "Host", Request.ServerVariables("SERVER_NAME") HTTPRequest.Send _ "VsmtpKey=" & Server.URLEncode(VsmtpKey) &_ "&Subject=" & Server.URLEncode(EmailSubject) &_ "&FromEmailAddress=" & Server.URLEncode(EmailFrom) &_ "&ToEmailAddress=" & Server.URLEncode(EmailTo) &_ "&Body_HTML=" & Server.URLEncode(HTMLBody) &_ "&Body_TextOnly=" & Server.URLEncode(TextBody) &_ "&Attachment_CSV=" & Server.URLEncode(Attachment) If HTTPRequest.ResponseText <> "True" Then Set HTTPRequest = Nothing Err.Raise 8, "vsmtp.Send", "Unable to send email. Check logs for details." End If Set HTTPRequest = Nothing End Sub End Class %> <% Set m = new vsmtp m.VsmtpKey = "my long key here" m.EmailSubject = "Test Subject" m.EmailFrom = "test@testdomain.com" m.EmailTo = "test@testdomain.com" m.TextBody = "Hello World!" m.HTMLBody = "Hello World" m.Send() Set m = nothing %>
note: When I comment out m.Send() I get no errors, so i'm guessing thats where the problem is. Also Im new to asp, how can I get the error description to show?
TIA PrinzPH (talk) 00:43, 5 May 2009 (UTC)
- I am no expert in VBScript, but it looks to me that the volusion supplied class is attempting to use an uninitialized variable
Attachment
. Try adding the following to the top of the following to the top of theSend
method.
If IsEmpty(Attachment) Then Attachment = "" End If
- If
Attachment
is undefined, it might be invalidating the expression in therHTTPRequest.Send
statement. If that doesn't help, try adding... & " " & Err.Description)
to the end of theErr.Raise
statement, which might give you a more informative error message. -- Tcncv (talk) 01:21, 5 May 2009 (UTC)
![](http://upload.wikimedia.org/wikipedia/en/thumb/f/fb/Yes_check.svg/20px-Yes_check.svg.png)
- Thanks for the reply, tried it, didn't work and I found the reason: Turns out the '(serverip)/vsmtp.asp' does not exist. It took me a long while to locate the log files. Thanks any ways! PrinzPH (talk) 18:07, 7 May 2009 (UTC)
An easy and cheap (preferably free) way to read & convert JPEG 2000 files to regular JPG?
[edit]What I would like to do here is get scans from the Internet Archive which are in JPEG 2000 format, convert them to JPG, and upload them to Commons. The Archive used to provide book downloads in JPG, but converted over to JPEG 2000 after a certain date, so more recent scans no longer have the option to be downloaded in JPG format. Thanks. --BrokenSphereMsg me 05:13, 5 May 2009 (UTC)
- I guess I'm not really offering a suggestion for software or a method to do this conversion, but if you're going to do this you might consider converting the images to PNG rather than JPEG, so that you aren't compounding compression artifacts. —Bkell (talk) 07:17, 5 May 2009 (UTC)
- Adobe Photoshop will do the job. It's almost free, at the low price of $999. You can download a 30-day trial, though. Plus, Photoshop supports automated conversions of groups of files, if you're dealing with a sizable collection.--67.174.107.10 (talk) 07:25, 5 May 2009 (UTC)
- Read [2]. There are a few free options that might work for you. --Stefan talk 09:11, 5 May 2009 (UTC)
- GIMP has a JPEG2000 plugin to open those files and it is easy to save them as JPG once they are open. -- kainaw™ 14:54, 5 May 2009 (UTC)
- ImageMagick is good for scripting or converting large numbers of files. I think it supports JPG2000. APL (talk) 15:12, 5 May 2009 (UTC)
- If you want to do batch conversin if images, IrfanView is a good choce. I'll say it's easier to use than all the above programs. F (talk) 07:34, 6 May 2009 (UTC)
- Thanks for the recs. In looking at the list of software that works with the file format I was unsure of which ones to try out, so I wanted to get people's input. Will report how it goes if I have issues. --BrokenSphereMsg me 17:26, 6 May 2009 (UTC)
Google and Wordpress
[edit]I've recently started a blog with the help of Google's free blog service, and it seems that Google doesn't support Wordpress.Is it possible to install Wordpress for blogs in Google? Please help. 117.194.231.202 (talk) 07:46, 4 May 2009 (UTC)
In case it helps, I'm talking about something like this http://aanushaghosh.blogspot.com/ blog. 117.194.229.230 (talk) 06:00, 5 May 2009 (UTC)
- No - if you want a Wordpress blog, just sign up at Wordpress.com — Matt Eason (Talk • Contribs) 07:08, 5 May 2009 (UTC)
Bitrate vs Quality
[edit]I have a video in VOB format with:
Variable Bit Rate Video Stream (12.8 Mbps, 9800 kbps nominal)
Constant Bit Rate Audio Stream (448 kbps)
I would like to convert this video to MP4 iPod format, but am unsure what bitrates to use so as to get the best quality. Video quality must not be so low as to cause noticeable artifacts in the video, and Audio quality must not be so low as to cause random static or buzzing in the audio stream. I'm using SUPER to convert the videos and it would be a LONG conversion process. Numbers are good. Thanks in advance. Buffered Input Output 12:46, 5 May 2009 (UTC)
creating lists in Excel
[edit]I am trying to use Excel to create picking slips for product in a storage facility. Is there some version of the LOOKUP function (or other worksheet function) that will return more than a single value for the cell being looked up? I would especially like to be able to control the number of values returned.
On one sheet, let's say I have a whole bunch of different items (apples, lemons, pears, etc) in a column with the column next to it listing the slots where each lot can be found. Maybe there are dozens of fruits, with dozens of lots apiece. On a second sheet, I'd like a way of saying "apples, 3" and having it return the first three values for apples found on the first sheet. The MATCH and LOOKUP functions can return the first value, but nothing else. Is this possible? I have Excel 2007. Matt Deres (talk) 13:55, 5 May 2009 (UTC)
Have a look at using a Pivot-table = you should be able to place the items in to show each of the available items and have a drop-down list to choose the item you're interested in. It may mean reorganising the data in the background depending on how 'table' like the information you have is. Worth a look though as pivot-tables are extremely flexible and very useful in many situations (once mastered). ny156uk (talk) 15:47, 5 May 2009 (UTC)
- Pivot tables seem to provide me with what I want, but not the way that I want it. :) For one thing, there seems to be a lot of extraneous stuff that gets added to the screen that I don't need. Also, it seems difficult to get the table to work fluidly; I don't want to have to redo the query every time circumstances change. With something like the LOOKUP function, I can easily use references to other cells to semi-automate queries and make the sheet more user-friendly for people who don't like Excel (!). Any other suggestions? Matt Deres (talk) 16:35, 6 May 2009 (UTC)
- I've managed to do at least some of what you want by using a mixture of MATCH, INDEX and OFFSET and some "helper" columns. If your fruits are in a named range called FruitList and "Apples" (or whatever) is in A2, then =MATCH(A2,FruitList,0) in B2 gives the position of Apples in the list. Then in C2 put =MATCH(A2,OFFSET(FruitList,B2,0),0), which means "look for Apples, starting after the previous one you found"), and in D2 =MATCH(A2,OFFSET(FruitList,B2+C2,0),0). Then if the slots are in SlotList you can use the formulas: =INDEX(SlotList,B2), =INDEX(SlotList,B2+C2) and =INDEX(SlotList,B2+C2+D2) to get the names of the slots. AndrewWTaylor (talk) 16:59, 6 May 2009 (UTC)
- Ho, ho, ho! That's the kind of thing I had in mind. I make use of hidden columns, etc. all the time, but hadn't figured this arrangement out. Well done! I was hoping for something straightforward, but that doesn't appear to me to be an option, so this is a huge step forward for me from what I'd been playing with. Thanks very much. Matt Deres (talk) 02:33, 9 May 2009 (UTC)
Game too slow
[edit]I just bought a new game, GTA IV, on my laptop, Windows Vista platform. It has a 1 GB ram and a built in NVIDIA GeForce card. Yet it was unable to play this game. The game plays in still images, very slow....the configuration is not enough. So what are my options ? Is it possible to make the game play better by downloading (free) game accelerators ? Will it help if i upgrade my RAM ? Is it possible to put a new graphics card in a laptop ? What do i do to make this and other new games play ? Rkr1991 (talk) 14:01, 5 May 2009 (UTC)
- "Game accelerators" are fake. I don't have this game on my PC, but the Grand Theft Auto IV article has a "System Requirements" matrix that shows that 1GB ram is a minimum requirement, which doesn't bode well. You should compare the model of your GeForce card with the "minimum" and "recommended" card types - maybe your GeForce card is particularly old (believable since laptop GeForce chips are usually pretty weak). You need to make sure you have the very latest GeForce driver (use the nvidia website). If that doesn't work, you may need a beefier setup with more RAM and a better graphics card. Tempshill (talk) 14:22, 5 May 2009 (UTC)
I got an NVIDIA GeForce Go 7150M graphics card. Is it too old ? So what do i do know ? Is it possible to download any free update for this which would make it work ? And first of all can a new graphics card be inserted into a laptop ? Will increasing ram speed halp ?Rkr1991 (talk) 14:31, 5 May 2009 (UTC)
- The 7150s are not high-performance cards, and I think the "Go" cards are even worse (to conserve energy.) They also came out mid-2007. I hate to break it to you, but what you've got is a low-end video card that came out nearly two years ago. I don't think you're going to be able to play GTA4 with this machine. GTA4 requires a pretty high-performance system. Sorry. APL (talk) 15:09, 5 May 2009 (UTC)
Have you tried to play the game on minimum settings? Lots of games have lower resolutions/draw distances/less enemies/whatever so that you can play them on lesser machines more smoothly - lots of people seem to leave it on standard and put up with jerky-playing but it's better (in my eyes) to play at worse-quality smoother. Anyhoo it may be worth a try as often the resolution can be reduced to a smoother-running level. ny156uk (talk) 15:45, 5 May 2009 (UTC)
- It's also worth noting that GTA IV's PC version is well-known for having various problems and glitches, including serious framerate problems. I believe Rockstar has released a number of patches for the game, but I'm not sure how well they address these issues. In any case, as the game is known to be pretty buggy, the problem might not get solved by simply buying a new graphics card. (Or, you know, it might. But you might want to look at what kind of results others have reported before you make your purchase...) -- Captain Disdain (talk) 23:34, 5 May 2009 (UTC)
- I used Windows Vista with 1 GB of RAM and while I kind of like Vista it seems to me that 1 GB of RAM is not enough for anything beyond basic use. Everything runs great when I am just using Firefox and such, but when I try to use Photoshop it all grinds to unusable slowness. Perhaps my problem is something else and not that Vista is a major memory hog, but my understanding is that it is. My current working theory is that 1 GB of RAM is not enough to run anything serious under Vista. Pfly (talk) 08:35, 6 May 2009 (UTC)
Vista is widely regarded as Microsoft's devious way of getting people to shell out for XP.
I don't know about your part of the world. In mine (Tokyo), the computer "makers" (companies that sell computers made for them in China, Taiwan, etc) all dutifully put in their catalogues the Japanese-language equivalent of "[name of company] recommends Windows Vista [particular version]"; however, they say less conspicuously but still clearly that the products are also available with XP. Meanwhile, the retailers make it very clear that XP is an option. This seems to be a big sales point.
NB I have no personal preference here. Actually I've used Vista a lot more than I've used XP, though I've only used Vista on spanking new, expensive machines belonging to others. I only retain a single Windows machine, on which I am typing this very message, using K-Meleon contentedly running under Windows 2000 on a nine (?) -year-old computer with 192MB of RAM. (Not that I'd dream of touting this as a games computer.)
So you may wish to consider "downgrading" to XP (or even 2000), if you can't add more RAM (or even if you can). -- Hoary (talk) 08:47, 6 May 2009 (UTC)
- I dispute most of what Hoary wrote. Anyway, Vista doesn't have anything to do with the problems the OP is experiencing. He needs to change his settings to minimum possible graphics options and see if that works. If not, his graphics chipset is probably insufficient, and his RAM is, too. Tempshill (talk) 15:30, 6 May 2009 (UTC)
- I have GTA4 for PC myself. I think the short answer here is that the laptop in question is well below the minimum specification for playing the game, and even somebody with the minimum specification will probably still find the performance of the game to be unacceptably bad. The game performance is more dependent on CPU and graphics than RAM though. Rjwilmsi 18:23, 6 May 2009 (UTC)
- GTA IV is a very high requirement game on the PC and even with (for example) a GTX 200 series GPU, a 2.5+Ghz quad core processor and 4GB of RAM, you still can't play the game on the highest settings. With a similar setup to what I listed, I need to keep the settings on medium or I get a lot of stuttering and dropped frames. On top of that, I would reccomend a MINIMUM of a 512MB GPU with 1GB or more being prefereable because this particular game stores a lot of texture data. A fast and multicore processor will also help. If you have a modern desktop, I'd reccomend installing it on that or seeing what happens when you turn down all settings to minimum. Downgrading to XP will not help in this case. 206.131.39.6 (talk) 18:35, 6 May 2009 (UTC)
Digital audio player with resume-from-playlist function
[edit]- moved from WP:RD/S
I am looking for a digital audio player with a function that allows me to resume from playlists. Let me explain: I have a playlist 1 of, say, 10 tracks. I listen to it for awhile and get to the middle of track 3. I turn off the player, turn it on a while later, and would like it to resume where I left off (in the middle of track 3), and continue to track 4 of the same playlist when track 3 is done. I listen for a bit longer, get to the middle of track 5. I stop playing, and load up playlist 2, composed of, say, 8 tracks. I start listening to playlist 2, stopping when I get to 20s into track 6 (of playlist 2). I stop, and switch again to playlist 1 - at which point I would like it to resume from where I left off on playlist 1, namely the middle of track 5 (of playlist 1). In other words, I would like a player which not only stores the location where I last stopped, both when I turn it off, and when I switch playlist (where it should store my location within a track and the track's position within a playlist). Are there any players which do this? Thanks in advance! — QuantumEleven 15:15, 5 May 2009 (UTC)
- This for sure belongs at the Computing Reference desk. Looie496 (talk) 16:27, 5 May 2009 (UTC)
- I'm unfamiliar with other devices (read: Apple fanboy), but I know in iTunes there is a setting to set songs to play where you left off. There may even be an option to set a whole playlist to act like that and have that transfer over to a newer iPod that would support it. -- MacAddct1984 (talk • contribs) 16:37, 5 May 2009 (UTC)
Comparing two CPUs
[edit]Lets say I have one CPU that has a clock rate of 2 GHz and 4 cores. I have another CPU which has a clock rate of 1 GHz but 8 cores. Other than that all specs are the same.
2*4 == 1*8
So which one is faster? Assuming their prices are the same, which one should you buy?
Thanks! —Preceding unsigned comment added by 77.127.234.68 (talk) 18:59, 5 May 2009 (UTC)
- Not information to compare the two. See Megahertz myth. Taggart.BBS (talk) 19:25, 5 May 2009 (UTC)
- If the two CPUs are exactly the same, except for the fact that one has twice the number of cores, but runs at half the speed, and other components (particularly things like the Northbridge also perform the same in both configurations, then the theoretical speed would be the same
- That said, I can't think of any range of CPUs which have variants with double the cores at half the speed - though you could perhaps Underclock a multi-core CPU so you could end up with this situation.
- Its difficult to write software that works optimally on multi-core CPUs - with more cores, you're less likely to use all of the CPU's power - so if there was a real world choice between the two for typical home/office use (e.g. Web browsing, office apps, games, etc.) 4 Cores at 2Ghz would likely be faster than 8 cores at 1Ghz. Cheers, davidprior t/c 20:43, 5 May 2009 (UTC)
- Amdahl's law says that N processors each running at speed M give you less performance than one processor running at speed NxM. So in your example, 4 core at 2GHz wins over 8 core at 1GHz - no matter what. Worse still - many programs are still not written to make use of more than one or two cores - so unless you're running lots of programs in parallel, it's rare indeed for more than a few cores to be doing much work. With more cores you may also get contention for resources - so even in programs that are designed to work with more cores - they may run faster on fewer. But it's a deep and tricky subject...you can almost certainly find corner cases where this is not the case. SteveBaker (talk) 03:24, 6 May 2009 (UTC)
List of different processors and their speeds or ages
[edit]I'm considering buying a secondhand computer from a shop that has several different models for sale. Since its very cheap to buy extra memory from eBay, I want to buy the computer with the fastest or most recent CPU. I have read the article Megahertz myth. Is there a list to be had anywhere that orders the ages, speeds, or desirabilities of CPUs over the past few years please? I want to be able to quickly glance at the list while in the shop and use it to select the computer with the best CPU. 89.241.158.255 (talk) 20:02, 5 May 2009 (UTC)
- Benchmark (computing)#External links includes CPU benchmark database which seems to have most modern CPUs in it - as for ages / release dates, the pages within Category:Lists of microprocessors would be a good place to start. Cheers, davidprior t/c 20:54, 5 May 2009 (UTC)
- It depends on the kinds of software you're going to run - but the speed of your memory and the memory bus is typically the bottleneck...so pay attention to motherboard speeds and the speed of the RAM you add.
- I have some other advice - which is: Don't buy the latest technology. Buy something a little older that's a LOT cheaper. Counter-intuitively, this gets you a faster computer...bear with me!
- If you have a fixed amount of money to spend on computer technology each year - your computer will be faster (on average) if you buy cheaper, slightly outdated, compute power and replace it more frequently - versus buying the very latest, greatest technology, but spending so much that you have to keep it longer before upgrading again. I studied this rather carefully as a work assignment about 5 years ago and concluded that buying year-old technology would save you about 60% of the cost and therefore allow you to upgrade almost three times as frequently - resulting (back then) in having a computer that's about 40% faster on average. However this depends on the rate of progress of the technology and the rate of price drop for older technology and all of that is pretty variable - so you'll have to make your own call on that one. SteveBaker (talk) 03:12, 6 May 2009 (UTC)
Thanks. Is there a list anywhere that ranks the desirability of common older models of computers sold say from 2003 to 2006 please? 78.145.24.191 (talk) 12:47, 7 May 2009 (UTC)
- "Models of computers", no, because there are too many manufacturers and configurations to make a chart that is possible to understand; but this chart at Tom's Hardware is a processor ranking from 2004 that tested the CPUs' speed at compressing files with WinRAR. Over to the right there's a 2006 chart and a 2007 chart, and under each one there are many benchmarks other than WinRAR that you can examine. By the way, a tip: Ask new questions at the bottom of the page rather than appending a question here - the readership of answerers is better at the bottom of the page. Tempshill (talk) 20:51, 7 May 2009 (UTC)
CMOS AND gate
[edit]When constructing an AND gate using CMOS logic, why can't one simply reverse Vss and Vdd instead of combining NAND and an inverter? 173.73.140.91 (talk) 21:13, 5 May 2009 (UTC)
- See the MOSFET article, as it has a fairly good description of FET operation. The NAND circuit consists of a combination of p-channel and n-channel FETs. The p-channel FETs (the ones with the small circle) are connected with the drain towards Vdd (+voltage) and the n-channel FETs are connected with the source towards Vss (-Voltage). What is not apparent is that there is also a substrate connection which is connected to either Vdd (for p-channel FETs) or Vss (for n-channel FETs). The diagrams on this web page (about half way down) shows these connections more clearly. To form a channel in a p-channel FET, a negative gate-to-source (gate-to-substrate) voltage must be applied. Similarly, to form a channel in a n-channel FET, a positive gate-to-drain (gate-to-substrate) voltage must be applied. If the Vss and Vdd voltages were swapped, neither of these conditions would occur and no active channels would form. The result (I believe) would be that the output would be undriven. -- Tcncv (talk) 01:24, 6 May 2009 (UTC)