Search found 38 matches

by Wayne Diamond
Fri Mar 19, 2004 3:33 am
Forum: Tricks 'n' Tips
Topic: Delete your own Exe (For UnInstaller )
Replies: 7
Views: 4104

Hrmmm. Rings didn't write this, he just ported my Powerbasic code that i wrote back in 2002:
http://www.powerbasic.com/support/forum ... 01350.html
by Wayne Diamond
Fri Jan 23, 2004 7:35 pm
Forum: Coding Questions
Topic: Speed of PureBasic
Replies: 54
Views: 18342

Basically what I meant is that this:
For x = 1 to Whatever
Do Nothing
Loop
... is basically going to compile to the same assembly-level code, regardless of which compiler you use, so if you're wanting to compare the speed of one language to another, using such a useless loop is probably the worst ...
by Wayne Diamond
Fri Jan 23, 2004 5:05 pm
Forum: Coding Questions
Topic: Speed of PureBasic
Replies: 54
Views: 18342

With all due respect ....
For xx.l = 1 To 100000000
zz.f = zz.f * yy.f
Next
This is a useless test. Why? 1) such code would NEVER exist in a real program (it's a useless loop that does nothing), and 2) such basic code/few instructions would pretty much be converted to the same assembly ...
by Wayne Diamond
Thu Jan 22, 2004 2:22 pm
Forum: Tricks 'n' Tips
Topic: IsAlpha IsNumeric
Replies: 53
Views: 20463

For this users a version they can understand is better sometimes
instead using a procedure they dont understand a bit.
True, but as long as they understand how to CALL an assembly function and know what it RETURNS, then knowledge of the internal workings isn't really required - they just need to ...
by Wayne Diamond
Thu Jan 22, 2004 3:55 am
Forum: General Discussion
Topic: JECXZ - "error: jump out of range" !?
Replies: 4
Views: 2327

JECXZ - "error: jump out of range" !?

I've 99% ported a compression/decompression algorithm known as SuperTiny over from Powerbasic to Purebasic (im slowly but surely porting all my crypto code over as my recent posts show!), but I'm encountering a couple of ASM problems that I wasnt having with Powerbasic.

If you try to compile the ...
by Wayne Diamond
Fri Jan 16, 2004 2:19 pm
Forum: Coding Questions
Topic: Console or GUI application??
Replies: 2
Views: 1282

Seldon,
The first part of your challenge is finding out your owner ... this is easily achieved in all Windows OS's from 95 up by the toolhelp api.
In particular, look at PROCESSENTRY32 ... it has a value th32ParentProcessID, so you can check that to find your owner process.

Now that you've found ...
by Wayne Diamond
Tue Jan 06, 2004 3:30 am
Forum: Tricks 'n' Tips
Topic: UUEncode \ UUDecode
Replies: 15
Views: 7092

I have half a dozen different variations of Base 64 including inline asm but haven't had a chance to port any over to Purebasic yet, maybe later this week with any luck

Regards,
Wayne
by Wayne Diamond
Mon Jan 05, 2004 9:39 am
Forum: Tricks 'n' Tips
Topic: UUEncode \ UUDecode
Replies: 15
Views: 7092

Seldon, that's correct. The only thing you'd probably need to do is strip out any carriage returns/line feeds (0x0D and 0x0A respectively).

Regards,
Wayne
by Wayne Diamond
Mon Jan 05, 2004 6:43 am
Forum: Tricks 'n' Tips
Topic: UUEncode \ UUDecode
Replies: 15
Views: 7092

RJP,
Can I use these for this function?
Yes, that's they're primary use (email-related), as that is pretty much the only time that UUEncoding is ever used on the Internet.

I also don't know how to tell where to start to grab the portion of the email that is the attachment.
In my demo you'll ...
by Wayne Diamond
Sat Jan 03, 2004 8:29 am
Forum: Coding Questions
Topic: POP3 decoder - Rfc 2047
Replies: 5
Views: 2404

Here is a UUEncode \ UUDecode demo:
viewtopic.php?t=8989

Regards,
Wayne
by Wayne Diamond
Sat Jan 03, 2004 8:26 am
Forum: Tricks 'n' Tips
Topic: UUEncode \ UUDecode
Replies: 15
Views: 7092

UUEncode \ UUDecode

Code updated For 5.20+

Procedure.s UUDecode(sInBuf.s)
sOutBuf.s = ""
For lLoop = 1 To Len(sInBuf) Step 4
sOutBuf = sOutBuf + Chr((Asc(Mid(sInBuf, lLoop, 1)) - 32) * 4 + (Asc(Mid(sInBuf, lLoop + 1, 1)) - 32) / 16)
sOutBuf = sOutBuf + Chr((Asc(Mid(sInBuf, lLoop + 1, 1)) % 16) * 16 + (Asc(Mid ...
by Wayne Diamond
Fri Jan 02, 2004 6:59 pm
Forum: Coding Questions
Topic: POP3 decoder - Rfc 2047
Replies: 5
Views: 2404

I'll write some UUEncode/UUDecode functions tomorrow, currently 2am here so too late to start now
by Wayne Diamond
Fri Jan 02, 2004 4:52 pm
Forum: Feature Requests and Wishlists
Topic: Feature requests
Replies: 18
Views: 4798

then you can use RSet(Hex(20), 6, "0")
Yep that works well, nice one :)
by Wayne Diamond
Fri Jan 02, 2004 2:43 pm
Forum: Feature Requests and Wishlists
Topic: Feature requests
Replies: 18
Views: 4798

Here's a Purebasic version of what i meant with the Hex function. It's not as efficient as i'd like but it'll do for now.
Procedure.s HexEx(inValue.l, inLength.l)
outHex.s = Hex(inValue): minLen.l = Len(outHex): outHex = Space(inLength) + outHex
outHex = ReplaceString(outHex, " ", "0", 1, 1): If ...
by Wayne Diamond
Fri Jan 02, 2004 2:13 pm
Forum: Feature Requests and Wishlists
Topic: Feature requests
Replies: 18
Views: 4798

Thanks, ive got macros working easily enough with inline asm now, but it'd also be nice to have macros at the Purebasic/preprocessor level!
I've also now got a very sexy color scheme, damn it looks good.

I see no reason to remove language constructs that already exist - if you don't use them they ...