Droopy's Lib

Applications, Games, Tools, User libs and useful stuff coded in PureBasic
lexvictory
Addict
Addict
Posts: 1027
Joined: Sun May 15, 2005 5:15 am
Location: Australia
Contact:

Post by lexvictory »

Sveinung wrote:The 'Microsoft OS -> Path' command PathAdd() doesn't work.
Getting an 'Invalid memory access'.
Most likely due to the string issue since 4.20; the path commands call the registry commands in the lib, which return a string, and the registry commands can be called from PB code.
This string issue means that any commands in the lib which rely on the registry commands will not work. (until I fix it)

I have not tested this command however, so I can't confirm if it's just your computer, though I doubt it would be.
Demonio Ardente

Currently managing Linux & OS X Tailbite
OS X TailBite now up to date with Windows!
User avatar
chi
Addict
Addict
Posts: 1087
Joined: Sat May 05, 2007 5:31 pm
Location: Austria

Post by chi »

when running the "Ldb F1 Test" example (pb 4.2) i get some ima´s...

- LdbSortNum
- LdbSortAlpha
- LdbSearch

hope this can be fixed easily... stuck atm ;)
lexvictory
Addict
Addict
Posts: 1027
Joined: Sun May 15, 2005 5:15 am
Location: Australia
Contact:

Post by lexvictory »

chi wrote:when running the "Ldb F1 Test" example (pb 4.2) i get some ima´s..
This issue has been known for a while, looking at it now it appears to be the same issue as the printer and path commands.
String functions calling other exported string functions.
Demonio Ardente

Currently managing Linux & OS X Tailbite
OS X TailBite now up to date with Windows!
User avatar
chi
Addict
Addict
Posts: 1087
Joined: Sat May 05, 2007 5:31 pm
Location: Austria

Post by chi »

funny thing... switched back to droopy´s lib v1.31.11 and everything (Ldb) works normal ;)
maybe this info may help?


chi
lexvictory
Addict
Addict
Posts: 1027
Joined: Sun May 15, 2005 5:15 am
Location: Australia
Contact:

Post by lexvictory »

chi wrote:funny thing... switched back to droopy´s lib v1.31.11 and everything (Ldb) works normal ;)
maybe this info may help?
It would be a TB change, the LDB functions were not changed between 1.31.11 and the current.
Demonio Ardente

Currently managing Linux & OS X Tailbite
OS X TailBite now up to date with Windows!
lexvictory
Addict
Addict
Posts: 1027
Joined: Sun May 15, 2005 5:15 am
Location: Australia
Contact:

Post by lexvictory »

@chi: ldb functions fix in the latest version (if you need them for 4.20 you will have to compile the lib manually or use as includefile)

@Sveinung: path commands should work again. Please test

@byo: Printer enum works now.


You should all download 1.31.15 for PB4.30 (see announcement topic)
Demonio Ardente

Currently managing Linux & OS X Tailbite
OS X TailBite now up to date with Windows!
User avatar
Sveinung
Enthusiast
Enthusiast
Posts: 142
Joined: Tue Oct 07, 2003 11:03 am
Location: Bergen, Norway

Post by Sveinung »

lexvictory wrote:Please test
Functions work perfectly now.

Regards
Sveinung
User avatar
chi
Addict
Addict
Posts: 1087
Joined: Sat May 05, 2007 5:31 pm
Location: Austria

Post by chi »

yeah! now i can switch to pb4.3. thx so much...
ldb functions work like a charm now 8)

cheers, chi
User avatar
chi
Addict
Addict
Posts: 1087
Joined: Sat May 05, 2007 5:31 pm
Location: Austria

Post by chi »

again... it´s me

strange behavior with Flag:

Code: Select all

FlagInit("HKEY_LOCAL_MACHINE\SOFTWARE\Droopy\")
FlagCreate("language") 
FlagSet("language","1") 
chk$=FlagGet("language")
Debug chk$
all i get is the droopy-parent with a reg_sz entry "Just a test to know if writing is possible" = OK
... and it crashes with debug=on (pb4.3)

bye, chi
lexvictory
Addict
Addict
Posts: 1027
Joined: Sun May 15, 2005 5:15 am
Location: Australia
Contact:

Post by lexvictory »

@chi: for some reason it works in x64, (using example from help file) but not x86.
You are probably better off using the Registry commands directly (RegGetValue(), etc) as the Flag commands are more or less simply wrapper functions.

Wrapper functions end up causing more problems than they solve sometimes when they are both in the same userlib.

Your other option is to create a dummy procedure eg:

Code: Select all

ProcedureDLL dummy()

ProcedureReturn 1
EndProcedure
Tailbite it, then take it from \purelibraries\userlibraries and create the folders \subsystems\nodroopy\purelibraries, copy it there and rename to 'Droopy', use the NoDroopy susbsystem and use Droopy.pb as an include (or remove the userlib files completely and use as include)

In other word: the short answer is to just use the Registry commands; they SHOULD work :)



I honestly have no idea why they would work in x64 and not x86...
It shouldnt make a difference that the x86 userlibs were created on and x64 system...
Demonio Ardente

Currently managing Linux & OS X Tailbite
OS X TailBite now up to date with Windows!
User avatar
chi
Addict
Addict
Posts: 1087
Joined: Sat May 05, 2007 5:31 pm
Location: Austria

Post by chi »

subsystem -> thx for that!
I don´t use Flag anyway... was just a bugreport ;)

bye, chi
lexvictory
Addict
Addict
Posts: 1027
Joined: Sun May 15, 2005 5:15 am
Location: Australia
Contact:

Post by lexvictory »

I use the subsystem to narrow down a bug when I include Droopy.pb into the test file :)
Demonio Ardente

Currently managing Linux & OS X Tailbite
OS X TailBite now up to date with Windows!
User avatar
Sveinung
Enthusiast
Enthusiast
Posts: 142
Joined: Tue Oct 07, 2003 11:03 am
Location: Bergen, Norway

Post by Sveinung »

Bug in the GetUserName function (line 2617)

There is missing an "@" infront of the nsize,so it should be
retour=GetUserName_(@Username, @nsize)

Regards
Sveinung
[/code]
lexvictory
Addict
Addict
Posts: 1027
Joined: Sun May 15, 2005 5:15 am
Location: Australia
Contact:

Post by lexvictory »

fixed: GetUserName()
GetPureBasicDirectoryInstallation() now works correctly (wasn't getting just PB path on my system)
Between() modified to allow for same left and right string (used in changed GetPureBasicDirectoryInstallation())
Demonio Ardente

Currently managing Linux & OS X Tailbite
OS X TailBite now up to date with Windows!
lexvictory
Addict
Addict
Posts: 1027
Joined: Sun May 15, 2005 5:15 am
Location: Australia
Contact:

Post by lexvictory »

If there is anyone who wishes to beta test a No-Subsystems version of the lib, please PM me.
No-Subsystems meaning you Don't have to make sure UserLibUnicode is in use when compiling in Unicode mode (Providing you don't use other UserLibs)
Demonio Ardente

Currently managing Linux & OS X Tailbite
OS X TailBite now up to date with Windows!
Post Reply