|
Zhentar posted:I like for what I've used it for. I don't know the answer to you question though.
|
# ? Oct 3, 2012 20:11 |
|
|
# ? May 29, 2024 03:39 |
|
totalnewbie posted:Okay, well, today's results also positive. Code here: http://pastebin.com/PWs0J8t7 If you believe the network is the bottleneck you might be out of luck unless you want to put a lot more effort into it. Assuming this is VBA/VBScript, threading isn't supported in either language. If you want to some fake thread-like behavior, you can have your code start a new process for each data file (via objShell.Exec or Shell), but you'd need to move your logic into a separate code file which was then executed (once for each data file) by your "main" code.
|
# ? Oct 3, 2012 20:37 |
|
Yeah, if that is indeed the bottleneck then I will just live with it. This implementation just feels better and I think is probably easier to adapt to other uses - which is why I was so hopeful to find something more efficient in the first place. The code is definitely cleaner and easier to follow IMO so there is always that Thanks for the suggestions, though. Maybe when I am really bored... totalnewbie fucked around with this message at 20:48 on Oct 3, 2012 |
# ? Oct 3, 2012 20:46 |
|
Titan Coeus posted:If you believe the network is the bottleneck you might be out of luck unless you want to put a lot more effort into it. Assuming this is VBA/VBScript, threading isn't supported in either language. Threading also gets more complicated when it involves COM interop. I'd bet the bottleneck isn't in the networking (that would be a pretty drat slow network), but in the Excel stuff. Excel's COM interop is not exactly blazing fast.
|
# ? Oct 3, 2012 21:11 |
|
Have to change some legacy code, web application that doesn't have https -- would it be "reasonably acceptable" to check if JS is enabled clientside, and then attempt to basic-SHA512 it with external IP or some other stuff as a nonce of a sort (any suggestions?), and HTTP POST that along with adding &prehashed=1 or something to the postdata as a stopgap? I already know this is disgusting and session hijacking and .js files modified in transit etc, but nothing can do :\
|
# ? Oct 3, 2012 22:38 |
|
Biowarfare posted:Have to change some legacy code, web application that doesn't have https -- would it be "reasonably acceptable" to check if JS is enabled clientside, and then attempt to basic-SHA512 it with external IP or some other stuff as a nonce of a sort (any suggestions?), and HTTP POST that along with adding &prehashed=1 or something to the postdata as a stopgap? No, that's completely worthless. I'm not even sure what you're saying, because you're using pronouns that lack antecedents, but whatever it is, it's completely worthless. (What is the "it" in "basic-SHA512 it"?) (What does "basic-SHA512" even mean?) (What is "external IP"?) (What is the other stuff?) (It doesn't matter, what you're proposing is completely worthless and doesn't add any security.) shrughes fucked around with this message at 09:34 on Oct 4, 2012 |
# ? Oct 4, 2012 09:25 |
|
So we started getting this error on our website today: Fatal error: require() [function.require]: Failed opening required '../Sorting Systems/sortingheader.php' (include_path='.;C:\php5\pear') in D:\Hosting\2630349\html\Products\Sorting-Systems\sorting.php on line 43 It happened out of no where with nothing changing as far as us putting any new files or changing any directories. Talked with the host provider, they said they had upgraded their php to 5.3 and we were still on 5.2, so we did the upgrade and it was still broken the line 43 it is refering to is this <?php require("../Sorting Systems/sortingheader.php"); ?> Did some function change in the php upgrade? I am at a complete loss here. e: poo poo I think I broke the tables, apologies.
|
# ? Oct 4, 2012 15:34 |
|
I have no idea whether something changed in PHP, but the error refers at one point to a directory called "Sorting Systems" and at another to a directory called "Sorting-Systems". Which is it? Does the require statement use the correct version?
|
# ? Oct 4, 2012 15:38 |
|
Hammerite posted:I have no idea whether something changed in PHP, but the error refers at one point to a directory called "Sorting Systems" and at another to a directory called "Sorting-Systems". Which is it? Does the require statement use the correct version? Fixed. Thanks for the help. Flaggy fucked around with this message at 21:26 on Oct 4, 2012 |
# ? Oct 4, 2012 15:40 |
|
Carthag posted:Which supposedly should decode to a PICT image of a flower. I wrote a decode function and if I align it to the structure from Apple's docs on PICT files I get this: code:
code:
|
# ? Oct 4, 2012 22:40 |
|
Thanks, sorry I should have updated my post last night. I took another look at it and realized I had an off-by-one error in my decoding table
|
# ? Oct 5, 2012 00:01 |
|
I know nothing about coding and am in general stupid. But I think what I want to do is possible, and any help would be really appreciated! What I'm trying to do is get an RSS feed's XML converted to plain text headlines and descriptions that can be read by a computerized voice. (It's for android/tasker) I was proud of myself that I managed to program tasker to actually pick up an RSS and read its contents, but it read literally the entire contents of the XML file. So essentially what I'd like to do is convert an XML from a given RSS feed into something that looks like the screenshot but is actually just parsed into a normal text file that the phone will be able to read. Is there any way to do something like that which would update itself regularly or is what i'm looking for not actually a thing.
|
# ? Oct 5, 2012 04:14 |
|
Chillmatic posted:I was proud of myself that I managed to program tasker to actually pick up an RSS and read its contents, but it read literally the entire contents of the XML file. Well, that's what RSS is. If you want to use it, you need to parse it first, and then extract whatever information you need out of that. Use an RSS library rather than raw XML parser, though. It'll expose a high-level interface for dealing with feeds instead of DOM tree/SAX events. Java ecosystem loves everything XML so much there should be plenty of those around.
|
# ? Oct 5, 2012 11:46 |
|
I've got some Access 2010 questions- hopefully this is the right thread. I'm trying to make it so that when I click an item listed in a query in a subform, it updates a text box with info from that record. Here's what it looks like: So, ideally, when you click on the Algebra 2 record, the CRN text box on the top will fill in with the correct number for the selected class. Same thing with students and their ID number. How would I go about creating this behavior? The only events I seem to have access to are gain focus / lose focus for the subforms, when I really seem to need access to an event when a record is selected. Any ideas? I'm really new to Access, but not to programming in general. This is just a totally new paradigm for me.
|
# ? Oct 5, 2012 20:12 |
|
Is this going to support multiple users? Cause Access doesn't really do that at all.
|
# ? Oct 5, 2012 20:17 |
|
You really want SQL Server 2012 Express assuming a Windows/Microsoft place. It's a scaled down version of SQL Server that has some limitations but should be enough to get you started. Maybe the better question is why did you pick Access/VBA as the programming language instead of whatever you are more comfortable with?
|
# ? Oct 5, 2012 20:43 |
I have always found Access extremely weird to work in, counter-intuitive in pretty much everything. If you have a background in regular desktop software development (or even web development) you will probably find it easier to work with Visual C# Express (or Visual Basic Express) and SQL Server Express (as suggested above) and write a proper application. That will let you do your event-driven programming with commits to database when you want it to happen, instead of implicit-everything as Access does. Unless, of course, using Access is a strict requirement for the task.
|
|
# ? Oct 5, 2012 20:49 |
|
I am playing around with Microsoft Small Basic again (please don't laugh) and came around the following problem: Let's say I want to fill the screen with random pixels. It would be easy to generate random numbers within the dimensions of the resolution. But what if I want to avoid filling a spot more than once (and some very late because the number never comes up)?
|
# ? Oct 6, 2012 23:20 |
|
Are you just talking about sampling without replacement?
|
# ? Oct 7, 2012 01:36 |
|
I'm now attempting to migrate my terrible, horrible, no-good, very bad code over from Fortran into CUDA Fortran ( ). Here's the minimal working example (there are roughly 16,000 more lines where this came from): code:
code:
Edit: For reference, the CUDA Fortran Quick Reference Card, which seems to have exactly the same module structure as my error prone program. http://www.pgroup.com/lit/literature/pgi_cuf_qrc.pdf Edit 2, days later: I should have read the quick reference more thoroughly. shared variables, like I intended first_ran4_call to be, can *only* be declared within device or global subroutines/functions. Grundulum fucked around with this message at 21:01 on Oct 8, 2012 |
# ? Oct 7, 2012 01:53 |
|
Is there a good way to seed a noise function? As an example from http://freespace.virgin.net/hugo.elias/models/m_perlin.htm has a noise function like this:code:
Is there a proper way of doing this?
|
# ? Oct 7, 2012 06:09 |
|
The standard implementation I've seen is "A Recursive Implementation of the Perlin Noise Function", from Graphics Gems II.
|
# ? Oct 7, 2012 06:14 |
|
Roughly how long would it take to create a 3D engine/simulator using pretty much only OpenGL in C++? Surely there's already a huge amount of theory w.r.t. dealing with collisions and lighting and all that stuff? e: I appreciate that this is a really general question but I'm trying to work out if it'd be suitable to base a year long project on.
|
# ? Oct 8, 2012 14:38 |
|
What plain-text editors do you all recommend for coding / scripting? Working in Notepad++ is what I've been using so far, but I'm curious if there's anything better out there that is recommended.
|
# ? Oct 8, 2012 16:47 |
|
Mo_Steel posted:What plain-text editors do you all recommend for coding / scripting? Working in Notepad++ is what I've been using so far, but I'm curious if there's anything better out there that is recommended. I'm quite fond of JEdit. It only does syntax hilighting (no semantic analysis or automatic compilation or anything) but it's a nice general-purpose programmer's editor. For heavier stuff I've been using IntelliJ IDEA (with the lua, scala, and clojure plugins) - it's a full-power IDE, though, and the system requirements are pretty steep. vi and emacs are also common recommendations. At this point I'm not convinced they're worth learning if you don't already know them, though.
|
# ? Oct 8, 2012 16:52 |
|
Mo_Steel posted:What plain-text editors do you all recommend for coding / scripting? Working in Notepad++ is what I've been using so far, but I'm curious if there's anything better out there that is recommended. Sublime Text 2 is my other favorite right now. It is $60 but you don't have to purchase a license it just nags you occasionally. Also Emacs and Vim
|
# ? Oct 8, 2012 16:53 |
|
ToxicFrog posted:vi and emacs are also common recommendations. At this point I'm not convinced they're worth learning if you don't already know them, though. I take it you've never used either of them. They are very much worth the effort to learn and you only have to learn it once since it will work for any language you may be dealing with. Your productivity will thank you later.
|
# ? Oct 8, 2012 17:09 |
|
Modern Pragmatist posted:I take it you've never used either of them. They are very much worth the effort to learn and you only have to learn it once since it will work for any language you may be dealing with. Your productivity will thank you later. I've used both for months at a time. I am still open to being convinced, but the impression I got from both is that all of the "killer features" and customization that are supposedly their big advantages have been standard in graphical editors for at least a decade now, which have the added advantage of being more discoverable. It was also not at all my experience that you "only had to learn it once since it will work for any language", at least in the case of emacs; I was switching between C, C++, Scala, Lua, and bash, and each one required painstaking configuration - and, in some cases, modification - of poorly documented elisp scripts to get it working at all. Contrast this with JEdit (which only does basic syntax hilighting, but does work out of the box for every language I use) or IDEA (which makes it really easy to install new modes and generally does not require you to manually fix them). (Last time I had this conversation, vim's killer feature was regex-based, multi-file search and replace...in half again as many keystrokes as it takes to do the same thing in JEdit.) I don't want to start a massive editor flamewar or derail the thread, so we can take this to PM or IRC (or another thread, if there's a suitable one) if you like.
|
# ? Oct 8, 2012 17:20 |
|
I've been using acme for years, and now there's a nice video tour of it.
|
# ? Oct 8, 2012 17:45 |
|
I've never tried emacs, but vim is great, and I wish I could do all of my text editing using it. The initial learning curve isn't even really that steep - you start by learning how to move around in a file and enter insert mode, and that gets you basically productive, and then you learn all the other cool poo poo it can do as you go. Setting up a vimrc is pretty straightforward, and plugins are generally easy to find and the ones I've tried work well. Good luck making it look non-hideous on Windows, though...for some reason themes that look great in Linux look terrible or don't work in Windows, so I'm stuck with one of the less ugly defaults if I have to use it in Windows. I've only been using it for a couple of months, so I haven't exactly mastered it, but it's hands down my favorite text editor that I've tried.
|
# ? Oct 8, 2012 17:53 |
|
gariig posted:Sublime Text 2 is my other favorite right now. It is $60 but you don't have to purchase a license it just nags you occasionally. This is a good answer. I switched over to ST2 a few weeks ago and it's still awesome.
|
# ? Oct 8, 2012 18:23 |
|
Thermopyle posted:This is a good answer. I switched over to ST2 a few weeks ago and it's still awesome. I switch between it and vim at regular intervals. For people who aren't interested in learning a lifestyle editor like vim, I can't recommend ST2 highly enough.
|
# ? Oct 8, 2012 18:27 |
|
Sublime Text is pretty great as well. Also you can enable vim keybindings.
|
# ? Oct 8, 2012 18:28 |
|
Thanks for all the feedback; Sublime looks pretty slick so I'll give that a try for now and see how I feel about it.
|
# ? Oct 8, 2012 20:56 |
|
This should probably go in the homework help thread, but I figured this one attracts more attention. I'm using Dr Racket to do some development. I have this piece of code that should work, but it doesn't. It is throwing an error despite me using a perfectly legal command. code:
I'm in Advanced Student mode, if that helps. I also tried replacing cons with list, but that resulted in a different error, something about requiring an expression after an open parenthesis.
|
# ? Oct 9, 2012 00:42 |
|
Dissenting opinion on the editor thing: I like TextPad, but that might just be because I'm used to it. You can link it into MinGW/other compilers. What I like most about it is the relatively powerful regex search in files you don't have open, no real upward limit on file size, etc. For Linux I've joined the dark side and actually kinda like vim now.
|
# ? Oct 9, 2012 01:03 |
|
My GPS-enabled running watch generates XML files that basically store the workout state every second. So each second there is a <sample> node that contains the time offset (# secs offset from the workout's start), the lat/long, speed, time, distance, and heart rate metrics. For fun and to learn some web crap, I want to build a little website that duplicates much of the functionality of sites like TrainingPeaks.com that provide reporting, dashboards, and maps to review runs. I'm trying to decide how to store the data and wonder if anyone has suggestions about the most efficient way? My day job is super SQL heavy so my immediate reaction is to just shove it into SQL Server but I realize that time series data is sort of a niche thing and that there may be other structures that are better. Am I better off looking at something else, or should I just build a boring old data model and do the work in an RDBMS? Thanks.
|
# ? Oct 9, 2012 01:06 |
It's not really relational data, but it sounds like it still fits neatly into a single SQL relation, so it's probably not a bad choice. Storing it in an SQL database also gives you a language to analyse the data, so I'd say go ahead and do that. Alternatively you can play with one of those key-value stores/document databases/NoSQL systems, though I don't think you'll win much if anything by that.
|
|
# ? Oct 9, 2012 01:18 |
|
There are specifically-tuned time series database engines.
|
# ? Oct 9, 2012 01:21 |
|
|
# ? May 29, 2024 03:39 |
|
oRenj9 posted:This should probably go in the homework help thread, but I figured this one attracts more attention. Your main problem is that you made a very poor choice when naming your function's argument.
|
# ? Oct 9, 2012 01:31 |