Search found 5995 matches

by dodicat
Nov 30, 2019 13:49
Forum: General
Topic: (Solved) How to sort datasheet (x-dim array) by a few columns (at once in 1 loop) ?
Replies: 32
Views: 990

Re: How to sort datasheet (x-dim array) by a few columns (at once in 1 loop) ?

Here is another method using the tried and tested c runtime sort. To sort the fields one by one the udt is made to hold array fields. I have added another female name (gender equality) Example. #include once "crt.bi" '========= set up c sort ========= #define up <,> #define down >,< #defin...
by dodicat
Nov 30, 2019 13:00
Forum: General
Topic: (Solved) How to sort datasheet (x-dim array) by a few columns (at once in 1 loop) ?
Replies: 32
Views: 990

Re: How to sort datasheet (x-dim array) by a few columns (at once in 1 loop) ?

Thanks jj2007. Still using quicksort, you can adjust slightly to sort columns one by one, but still storing the data in a udt. (Simply by swapping only the field) #define up <,> #define down >,< #macro SetQsort(datatype,fname,b1,b2,dot) Sub fname(array() As datatype,begin As Long,Finish As Long) Dim...
by dodicat
Nov 29, 2019 18:05
Forum: General
Topic: (Solved) How to sort datasheet (x-dim array) by a few columns (at once in 1 loop) ?
Replies: 32
Views: 990

Re: How to sort datasheet (x-dim array) by a few columns ?

If you use a udt array holding the information then quicksort would do. You must set each sort, give it a name, direction and field. #define up <,> #define down >,< #macro SetQsort(datatype,fname,b1,b2,dot) Sub fname(array() As datatype,begin As Long,Finish As Long) Dim As Long i=begin,j=finish Dim ...
by dodicat
Nov 28, 2019 12:54
Forum: General
Topic: Squares
Replies: 7362
Views: 443114

Re: Squares

Hi Albert. I cannot beat mid with a custom function for mid ATM, but I am sure it could be done. const maxlen=200 function middle(_in as string, x as long,y as long) byref as const string #macro copy(dest,src,size) For n As Long=0 To size-1 (dest)[n]=(src)[n] Next #endmacro dim as zstring * maxlen g...
by dodicat
Nov 28, 2019 11:41
Forum: General
Topic: [updated topic] member function ptr
Replies: 31
Views: 813

Re: [updated topic] member function ptr

Hi dafhi. They have to be static to get their address in memory. There are horrible looking hacks, but too awful to remember. type mytype extends object declare operator cast as string declare constructor( as string ) declare static function aa as single declare static function bb as single ' .. oth...
by dodicat
Nov 27, 2019 17:13
Forum: General
Topic: Squares
Replies: 7362
Views: 443114

Re: Squares

You are getting plenty of advice Stonemonkey.
Good to see you in squares.
I really liked your two rotating shapes a week or so back.
I reckon if you persevere here in squares you will leave us all standing, and gibbering.
Maybe Albert needs a new insight in his compression (AND UN COMPRESSION)
by dodicat
Nov 24, 2019 13:50
Forum: General
Topic: Squares
Replies: 7362
Views: 443114

Re: Squares

Also stonemonkey, I have many functions for gmp (the best known library I think) ' 1 December 2016 - orinal by dodicat ' 11 December 2016 - frisian, added mpf_clear/mpz_clear statements ' changed some code by using GMP code, cleaned up some init/init_set stuff ' reduced the number of big integer/flo...
by dodicat
Nov 24, 2019 13:24
Forum: Windows
Topic: ld.exe: cannot find -lsqlite
Replies: 7
Views: 233

Re: ld.exe: cannot find -lsqlite

As paul doe says, if you put the .bi the .bas and the .dll into the same folder it should run. Make sure that the .bi file correctly calls the dll. example in the .bi file it will say near the top something like: ... #inclib "sqlite" <------ must be the correct name of the dll file ... For...
by dodicat
Nov 23, 2019 13:21
Forum: General
Topic: Squares
Replies: 7362
Views: 443114

Re: Squares

If the random data is numerical (0 to 9) or [48] to [57] then it is compressible of course(substitutions).
But random [0] to [255] , unless you can convert to numerical is different.
The problem is that base 256 to base 10 is about 2-3 times bigger, so substitutions methods are not the best IMO.
by dodicat
Nov 21, 2019 17:20
Forum: Windows
Topic: transfer windows 10 application
Replies: 3
Views: 190

Re: transfer windows 10 application

Some things don't need installed, only copied. For instance the game RETURN TO CASTLE WOLFENSTEIN which is 677 mb in size and is contained in one folder can simply be copied via a pen drive, and it works fine wherever it ends up. Some programs alter the registry of course, but maybe not too much, it...
by dodicat
Nov 20, 2019 19:25
Forum: Tips and Tricks
Topic: Brownian motion.
Replies: 36
Views: 1344

Re: Brownian motion.

Sorry to see that Imortis had to chop things out (before I got a chance to read them). And deltarho[] is off to PB for 90 days, what is all that about? And paul doe's . . . "@dodicat: I'm truly sorry. I know you don't like me (you may have your reasons)". Sorry for what? Did Imortis chop t...
by dodicat
Nov 20, 2019 13:00
Forum: Projects
Topic: WinFBE Editor and FreeBASIC Compiler (All-in-One Package) (Updated December 13, 2019)
Replies: 601
Views: 94357

Re: WinFBE Editor and FreeBASIC Compiler (All-in-One Package) (Updated November 17, 2019)

Observation: When using the freebasic command Exec to run something (e.g. run fbc.exe to compile a file), I notice that the chr(34) is not needed around the compiler path (The compiler path may include spaces). But a distinct chr(32,34) is needed around the file path. I put an old compiler in a fold...
by dodicat
Nov 19, 2019 18:24
Forum: Tips and Tricks
Topic: Brownian motion.
Replies: 36
Views: 1344

Re: Brownian motion.

I have tested all the freebasic ides I have, there are plenty. Only fbide brings up an include file to flag an error. One thing about fbide, it is done and dusted, you use it warts and all. No need for downloading never ending updates. After all, the ide is only a tool to do what you want. Enough wo...
by dodicat
Nov 19, 2019 17:08
Forum: Tips and Tricks
Topic: Brownian motion.
Replies: 36
Views: 1344

Re: Brownian motion.

fbide shows an include file if there is an error in it, (you can create a pseudo error) 'fbide dim as long lastsleeptime=32 #include "windows.bi" dim as zstring * 32 Machine dim as long b = 32 GetComputerName(Machine, @lastsleeptime) messagebox(0,machine,"your box",0)
by dodicat
Nov 19, 2019 10:02
Forum: Tips and Tricks
Topic: Brownian motion.
Replies: 36
Views: 1344

Re: Brownian motion.

deltarho[]
Including windows.bi fetches a long enum with lastsleeptime at integer 15.
Thus the _lastsleeptime.

Compile this code with -pp switch and you will see it.

Code: Select all

#define WIN_INCLUDEALL
#include "windows.bi"

Go to advanced search