Search found 2971 matches

by mk-soft
Sat Oct 23, 2021 3:01 pm
Forum: Coding Questions
Topic: Pointer to a map
Replies: 10
Views: 1145

Re: Pointer to a map

Callbacks works fine with Prototypes ... ;-TOP Prototype.s MapCallback(Map sVal.s()) Procedure.s MyGetMapL(Map sVal.s()) Protected r1.s ForEach sVal() r1 + LCase(sVal()) + ";" Next ProcedureReturn r1 EndProcedure Procedure.s MyGetMapU(Map sVal.s()) Protected r1.s ForEach sVal() r1 + UCase(...
by mk-soft
Sat Oct 23, 2021 1:40 pm
Forum: Windows
Topic: Test PB 5.73x64 over Windows11
Replies: 3
Views: 118

Re: Test PB 5.73x64 over Windows11

According to ProcessExplorer, 'ieframe.dll' and 'jscript9.dll' are used.

With windows 10 there is also a script error too.
by mk-soft
Sat Oct 23, 2021 1:27 pm
Forum: Coding Questions
Topic: Pointer to a map
Replies: 10
Views: 1145

Re: Pointer to a map

Map are PB internally managed.
What do you mean by OS callbacks. Enum API's are something completely different.
by mk-soft
Fri Oct 22, 2021 5:18 pm
Forum: Assembly Programming
Topic: [SOLVED] Trying to make AbsInt()
Replies: 16
Views: 2228

Re: [SOLVED] Trying to make AbsInt()

Long time later ... Update - Add AbsInt ;-TOP my mk-soft Macro AbsL(Value) (Value * (Value >> 31) | 1) EndMacro Macro AbsQ(Value) (Value * (Value >> 63) | 1) EndMacro CompilerIf #PB_Compiler_Processor = #PB_Processor_x86 Macro AbsInt(Value) (Value * (Value >> 31) | 1) EndMacro CompilerElse Macro Abs...
by mk-soft
Fri Oct 22, 2021 4:02 pm
Forum: Feature Requests and Wishlists
Topic: [Done] Need ClearArray() command
Replies: 7
Views: 2383

Re: [Done] Need ClearArray() command

Important

NOT USE FILLMEMORY WITH STRING ARRAYS
by mk-soft
Thu Oct 21, 2021 10:54 pm
Forum: Coding Questions
Topic: Help with Packer, please. - Zip signature
Replies: 3
Views: 245

Re: Help with Packer, please. - Zip signature

; TOP by mk-soft DataSection EmptyZip: Data.a 'P', 'K', 5, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 EndEmptyZip: EndDataSection Procedure CreateEmptyZipFile(FileName.s) Protected file file = CreateFile(#PB_Any, FileName) If file WriteData(file, ?EmptyZip, 22) CloseFile(file) Procedur...
by mk-soft
Sun Oct 17, 2021 10:59 am
Forum: Coding Questions
Topic: StringGadget Vertical?
Replies: 43
Views: 11805

Re: StringGadget Vertical?

Alternatively with a FrameGadget ... Update Procedure GetTextHight(FontID = #PB_Default) Static img Protected r1 If Not img img = CreateImage(#PB_Any, 16, 16) EndIf If StartDrawing(ImageOutput(img)) If FontID : DrawingFont(FontID) : EndIf r1 = TextHeight("X") StopDrawing() EndIf ProcedureR...
by mk-soft
Fri Oct 15, 2021 5:03 pm
Forum: Linux
Topic: Linux Reboot/Shutdown using PB app
Replies: 6
Views: 676

Re: Linux Reboot/Shutdown using PB app

Part from RunAsAdmin and modified ... not testet ... Procedure SuDo(user.s, passwd.s, program.s) Protected cmd.s If user = UserName() cmd.s = "-c " + #DQUOTE$ + "echo " + passwd + " | sudo -S " + program + #DQUOTE$ Else cmd.s = "-c " + #DQUOTE$ + "echo &q...
by mk-soft
Fri Oct 15, 2021 9:10 am
Forum: General Discussion
Topic: Only a 'Tick'
Replies: 1
Views: 647

Re: Only a 'Tick'

Perhaps with own constants

Code: Select all

#QUOTE = 39
#DQUOTE = 34

DataSection
  label:
  Data.a 'D', 'a', 't', 'a', '.', 'a', ' ', #QUOTE, 'D', #QUOTE, ',', #QUOTE, 'a', #QUOTE, ',', #QUOTE, 't', #QUOTE, ',', #QUOTE, 'a', #QUOTE
  Data.a 0
EndDataSection

Debug PeekS(?label, -1, #PB_Ascii)
by mk-soft
Thu Oct 14, 2021 9:19 pm
Forum: Linux
Topic: Linux Reboot/Shutdown using PB app
Replies: 6
Views: 676

Re: Linux Reboot/Shutdown using PB app

Perhaps help ...

Link: viewtopic.php?f=12&t=71693
by mk-soft
Thu Oct 14, 2021 3:36 pm
Forum: General Discussion
Topic: Tablacus Script Control x64
Replies: 1
Views: 427

Re: Tablacus Script Control x64

The TablacusScriptControl X64 uses Microsoft ActiveScript internally.
It can also use ActiveScript directly at PB.

Link: Module ActiveScript for VB-Script ...
by mk-soft
Mon Oct 11, 2021 4:50 pm
Forum: Bugs - C backend
Topic: Structured array memory address with offset not being calculated correctly
Replies: 1
Views: 526

Re: Structured array memory address with offset not being calculated correctly

Its a bug with bracketing Global Dim Array1.point(100,100); Procedure Test() Protected *Src Protected OffsetXY = 3 ;*src = @Array1() + OffsetXY ;/ <- Bug here. ; !p_src=(void*)(((s_point*)a_array1.a)+v_offsetxy) ; <- PB_CompilerC : v_offsetxy is type size s_point (3*8 bytes) ; change code !p_src=(vo...
by mk-soft
Sun Oct 10, 2021 12:28 pm
Forum: Announcement
Topic: PureBasic 6.00 Alpha 5 released !
Replies: 245
Views: 51673

Re: PureBasic 6.00 Alpha 5 released !

You have to add the C-Backend compiler for x86 yourself in the IDE under settings/compiler.
by mk-soft
Sun Oct 10, 2021 12:10 pm
Forum: Feature Requests and Wishlists
Topic: Calling ProcedureReturn from within a loop. More information needed in docs to clarify if this is a valid thing to do.
Replies: 6
Views: 811

Re: Calling ProcedureReturn from within a loop. More information needed in docs to clarify if this is a valid thing to d

But remember that resources you have created yourself must also be released again.
This applies to AllocateMemory, AllocateStructure, dynamic objects with PB_Any (CreateImage, etc).
by mk-soft
Sun Oct 10, 2021 12:03 pm
Forum: Coding Questions
Topic: TreeGadget collapse nodes
Replies: 9
Views: 1258

Re: TreeGadget collapse nodes

You are right,

I look later for windows