PBOSL - A OpenSource Library-Collection for PureBasic

Applications, Games, Tools, User libs and useful stuff coded in PureBasic
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Post by ts-soft »

Heis Spiter wrote:You're right. I've some problems with mathematics words in English :oops:. If someone can correct it in PBOSL ;).
i will change it for next version in

Code: Select all

Result.l = RandomPrime(Maximum)
Heis Spiter wrote: About bugs, I think I've found a bug in NTService. The function removeservice doesn't work. It's strange ! I would delete a service, so I use this function that didn't work. To see where it failed, I tried with source, and with source it works... :shock:
Sorry, i have test it with the examples, it works for me :?:
Stest.exe /install
Service "NT-Services the easy way" is installed and
Stest.exe /remove
Service "NT-Services the easy way" is removed
Can you post a codeexample, please?
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
User avatar
GeoTrail
Addict
Addict
Posts: 2794
Joined: Fri Feb 13, 2004 12:45 am
Location: Bergen, Norway
Contact:

Post by GeoTrail »

I have used the remove service and that worked fine for me. Did you remember to stop it first?
I Stepped On A Cornflake!!! Now I'm A Cereal Killer!
Heis Spiter
User
User
Posts: 41
Joined: Fri Aug 22, 2003 7:10 pm
Location: 76 (FRANCE)
Contact:

Post by Heis Spiter »

No :lol:. That explains all ;). I'm a bit absent-minded :?.
I've too a suggestion to do. My program doesn't support Pause/Resume. And I've seen that Avast service doesn't purpose those options. How can I do to delete those options to my service ? (After install, or during install)
User avatar
GeoTrail
Addict
Addict
Posts: 2794
Joined: Fri Feb 13, 2004 12:45 am
Location: Bergen, Norway
Contact:

Post by GeoTrail »

I'm not really sure what you mean. Could you explain abit more?
I Stepped On A Cornflake!!! Now I'm A Cereal Killer!
Heis Spiter
User
User
Posts: 41
Joined: Fri Aug 22, 2003 7:10 pm
Location: 76 (FRANCE)
Contact:

Post by Heis Spiter »

Ok. When you have created a service with the lib, your service has four options : Start, Pause, Resume, Stop. My programme can't support Pause and Resume. And I've seen that Avast! has only two options : Start, Stop. So, I would like to know how I can do to have only Start and Stop.
User avatar
GeoTrail
Addict
Addict
Posts: 2794
Joined: Fri Feb 13, 2004 12:45 am
Location: Bergen, Norway
Contact:

Post by GeoTrail »

I see what you mean and that is a good question.
Was wondering about that myself.
I'd also like to be able to add a service, but not as automatic , but to run manually when needed.
I Stepped On A Cornflake!!! Now I'm A Cereal Killer!
Heis Spiter
User
User
Posts: 41
Joined: Fri Aug 22, 2003 7:10 pm
Location: 76 (FRANCE)
Contact:

Post by Heis Spiter »

GeoTrail wrote:I'd also like to be able to add a service, but not as automatic , but to run manually when needed.
When you install your service, use this constant

Code: Select all

#SERVICE_DEMAND_START   = $00000003
instead this constant

Code: Select all

#SERVICE_AUTO_START     = $00000002
User avatar
GeoTrail
Addict
Addict
Posts: 2794
Joined: Fri Feb 13, 2004 12:45 am
Location: Bergen, Norway
Contact:

Post by GeoTrail »

That's great. Just what I needed. Thanks m8 :)
I Stepped On A Cornflake!!! Now I'm A Cereal Killer!
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Post by ts-soft »

For the next PBOSL-Update, i have added the constants to the pbosl.chm

You can also help to corrected the helpfile by creating a account on webPM, send me a PM, please
(translated by webtranslator, sorry)
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Post by ts-soft »

Update: PBOSL_RandomPrime, PBOSL_PurePDF (little Bugfix)
New Version: PBOSL_SQLite3 (see examples, help is coming soon...)
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Gansta93
Enthusiast
Enthusiast
Posts: 238
Joined: Wed Oct 20, 2004 7:16 pm
Location: The Village
Contact:

Post by Gansta93 »

GeoTrail wrote:Does anyone have some info about the status service?
GetServiceStatus() retreives a numeric value from 1 to 4. I found that 1 means disabled and 4 is enabled, but I don't know if it's running or not.
These are the constents I have taken with autocompletion typing #Service_ and looking for constents whish have a name looking as a state.

Code: Select all

#SERVICE_STOPPED = 1
#SERVICE_INACTIVE = 2
#SERVICE_STATE_ALL = 3
#SERVICE_RUNNING = 4
#SERVICE_PAUSED = 7
Strange... there is not 5 and 6... but if someone confirme, I will add it in the help because I can test it, I am on Win 98 SE.
I know my method is not the best, but it seams to work. ;-)
Message edited, mistake with first constent.
Be seeing you! :-)

Gansta93
If you speak french, you can visite Le Monde de Gansta93 (Gansta93's World)
Gansta93
Enthusiast
Enthusiast
Posts: 238
Joined: Wed Oct 20, 2004 7:16 pm
Location: The Village
Contact:

Post by Gansta93 »

A suggestion:
To compile the help file, only two files of HTMLHelpWorkshop are requiered : HHA.dll and HHP.exe.
Why not propose a seperated pack with thes two files if the user has not HTMLHelpWorkshop or just include thes two file in the zip archive which conteins the sources of help? If we do it, it won't be necessary to edit make.bat and it will be simply

Code: Select all

@echo off
@generate.exe /quiet
@cd output
..\hhc.exe PBOSL.hhp
so it'll be compatible with all configurations.
What do you think? :?:
Be seeing you! :-)

Gansta93
If you speak french, you can visite Le Monde de Gansta93 (Gansta93's World)
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Post by ts-soft »

the hhc.exe is not redistributable, only as original-setup.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Gansta93
Enthusiast
Enthusiast
Posts: 238
Joined: Wed Oct 20, 2004 7:16 pm
Location: The Village
Contact:

Post by Gansta93 »

ts-soft wrote:the hhc.exe is not redistributable, only as original-setup.
Oops, this is the consequence of not reading licences. :-) I'm understand, thx.
Be seeing you! :-)

Gansta93
If you speak french, you can visite Le Monde de Gansta93 (Gansta93's World)
Gansta93
Enthusiast
Enthusiast
Posts: 238
Joined: Wed Oct 20, 2004 7:16 pm
Location: The Village
Contact:

Post by Gansta93 »

About GetServiceStatus(), I have it. :-D

Code: Select all

#SERVICE_STOPPED = 1
#SERVICE_START_PENDING = 2
#SERVICE_STOP_PENDING = 3
#SERVICE_RUNNING = 4
#SERVICE_CONTINUE_PENDING = 5
#SERVICE_PAUSE_PENDING = 6
#SERVICE_PAUSED = 7
Here are the explications of constents (I will take thes in the help with WebPM but not if TsSoft is disagrea).
#SERVICE_STOPPED = The service is not running.
#SERVICE_START_PENDING = The service is starting.
#SERVICE_STOP_PENDING = The service is stopping.
#SERVICE_RUNNING = The service is running.
#SERVICE_CONTINUE_PENDING = The service continue is pending.
#SERVICE_PAUSE_PENDING = The service pause is pending.
#SERVICE_PAUSED = The service is paused.
I was on a good way! :-D
Be seeing you! :-)

Gansta93
If you speak french, you can visite Le Monde de Gansta93 (Gansta93's World)
Post Reply