English
Forum

Scroll bar with -/+ Scrollbereich

 
- Page 1 -



GDL
Hallöle,

must the Scrollbereich one Scroll bar not of less to plus weg.
See example:
CompileMarkSeparation
declare ende%,scrollbalken&
cls
scrollbalken&=create("hscroll",%hwnd,"",10,20,300,25)
SetScrollRange scrollbalken&,-200,200
SetScrollPos scrollbalken&,-10
sleep 300
SetScrollPos scrollbalken&,150
sleep 300
SetScrollPos scrollbalken&,-200
sleep 300
SetScrollPos scrollbalken&,0
'setscrollpos geht im negativen Bereich
'durch Drücken auf den kleinen nach Linkspfeil kann man auch den negativen Bereich anfahren
'mit dem Regler den negativen Bereich anfahren geht nicht. Regler springt immer zum positiven Anschlag

whilenot ende%

wend


Grüßle
Georg
 
XProfan X3
Windows7 Xprofan 8,9,10 [...]  [...] 
10/19/14  
 



« this Posting watts as Solution marked. »


RGH
there was objectively another bow drin, the though always drin was:
The suitable Message gives The Scrollposition as Word (0 ... 65535) back. If the Value is greater than 32767 is, must therefore 65536 abgezogen go, around the right position (-32767 ... +32767) To detect. this step fehlte bislang.

After nunmehr almost 20 years becomes too this bow gefixt!

Greeting
Roland
 
XProfan X2
Intel Duo E8400 3,0 GHz / 4 GB RAM / 1000 GB HDD - ATI Radeon HD 4770 512 MB - Windows 7 Home Premium 32Bit - XProfan X4
05/18/15  
 




Jörg
Sellmeyer
If you negatives values having want, must You tappt im dunkeln to the Reading quasi calculate:
CompileMarkSeparation
declare ende%,scrollbalken&
cls
scrollbalken&=create("hscroll",%hwnd,"",10,30,300,25)'Scroll mit Werten von 0 bis ...
SetScrollRange scrollbalken&,0,400
'SetScrollPos scrollbalken&,-10
'sleep 300
SetScrollPos scrollbalken&,150
sleep 300
SetScrollPos scrollbalken&,-200
sleep 300
SetScrollPos scrollbalken&,0
'setscrollpos geht im negativen Bereich

whilenot ende%

    Waitinput
    Locate 1,1
    Print GetScrollPos(scrollbalken&) - 200," "'Position auslesen und gewünschten Nullpunkt abziehen

wend


Nachtrag:
I seh straight, that loudly Help really too negatives values possible his müssten. One old mitgeschleppter bow?
 
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
10/20/14  
 




Georg
Teles
Hmm, jau Help says: niedrigster worth ( -32767 ), highest worth ( 32767 )

The beam jumping sowohl in XProfan X2, in XProfan 10.0 as well as in 8.0, sees to one bow from
 
XProfan X2
TC-Programming [...] 
XProfan 8.0 - 10.0 - X2 - X3 - X4

10/20/14  
 




Jörg
Sellmeyer
for your tack schicker and vielseitiger might ohnehin a Trackbar his:
CompileMarkSeparation
 $H commctrl.ph
DEF GETSYSCOLOR(1) !"USER32","GetSysColor"
declare slider1&,slider2&
Set("TrueColor", 1)
cls GETSYSCOLOR(15)
Set("decimals", 0)
slider1&=Control("MSCTLS_TRACKBAR32", "Trackbar01", $54010004, 10, 100, 400, 40, %hwnd, 2011, %hInstance, $00010004)'Horizontale Trackbar
slider2&=Control("MSCTLS_TRACKBAR32", "Trackbar02", $54000017, 50, 200, 40, 100, %hwnd, 2012, %hInstance, $00010004)
SendMessage(slider1&,~TBM_SETRANGE,1,MakeLong(-100,100))'die 1 erzwingt das Neuzeichnen des Sliders
SendMessage(slider2&,~TBM_SETRANGE,1,MakeLong(-200,400))
SendMessage(slider1&,~TBM_SETTIC,1,0)

whilenot %scankey=27

    waitinput
    locate 1,1
    print "Trackbar 1:";SendMessage(slider1&,$0400,0,0);"  "
    print "Trackbar 2:";SendMessage(slider2&,$0400,0,0);"  "

Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
10/20/14  
 




GDL
Hi,

thanks.
left and right yet NEN small Button for 1Schrittweite and it working.

Grüßle
Georg
 
XProfan X3
Windows7 Xprofan 8,9,10 [...]  [...] 
10/21/14  
 




RGH
there was objectively another bow drin, the though always drin was:
The suitable Message gives The Scrollposition as Word (0 ... 65535) back. If the Value is greater than 32767 is, must therefore 65536 abgezogen go, around the right position (-32767 ... +32767) To detect. this step fehlte bislang.

After nunmehr almost 20 years becomes too this bow gefixt!

Greeting
Roland
 
XProfan X2
Intel Duo E8400 3,0 GHz / 4 GB RAM / 1000 GB HDD - ATI Radeon HD 4770 512 MB - Windows 7 Home Premium 32Bit - XProfan X4
05/18/15  
 




GDL
Hi Roland,

always the Georg with its Spezialprogrammen. Grins.

Grüßle
Georg
 
XProfan X3
Windows7 Xprofan 8,9,10 [...]  [...] 
05/19/15  
 



Answer


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

9.734 Views

Untitledvor 0 min.
Thomas Freier02/04/23
RudiB.09/17/22
H.Brill02/18/22
Jörg Sellmeyer06/07/20
More...

Themeninformationen



Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie