Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Problem with turing
Index -> Programming, Turing -> Turing Help
Goto page Previous  1, 2, 3, 4, 5, 6
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
Dan




PostPosted: Sat Dec 07, 2002 1:44 pm   Post subject: hummm

i tested out your code by taking the code you have there andadding vars and it wroked fine. so i think the problem may be in a difrent part of your code. i whode sugeste look trow the code for the times when you use the var itemuseamazon and make shure you do not have a loop or somting that sets it back to 0 or somting.
Computer Science Canada Help with programming in C, C++, Java, PHP, Ruby, Turing, VB and more!
Sponsor
Sponsor
Sponsor
sponsor
krishon




PostPosted: Sat Dec 07, 2002 2:01 pm   Post subject: (No subject)

could i just send u the code, cuz i looked ova it several times and i still cannot fix it.
krishon




PostPosted: Sat Dec 07, 2002 5:43 pm   Post subject: (No subject)

tony or dan, how can i calibrate the slider thing made from the GUI. I found the code for the slider but i dun't know how control the volume.
Tony




PostPosted: Sat Dec 07, 2002 6:16 pm   Post subject: (No subject)

code:

import GUI in "%/oot/lib/GUI"

var slider : int

procedure SliderMoved(value:int)
locate(2,1)
put "Horizontal Slider:",value
end SliderMoved

slider:= GUI.CreateHorizontalSlider(10,10,250,50,150,50,SliderMoved)

loop
    exit when GUI.ProcessEvent
end loop


Here's the working code

GUI.CreateHorizontalSlider(x,y,length,min,max,start, PROCEDURE)

the value of slider is passed on to the procedure SliderMoved and can be stored and/or displayed in there.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
krishon




PostPosted: Sat Dec 07, 2002 7:05 pm   Post subject: (No subject)

i didn't phrase my question right, i'm sorry. I meant to say i already drew the slider, but i do not know how to use the slider to control the actual volume of the computer. My friend mentioned about calibrating the slider to the volume of the computer, but he does not know how to do it.
krishon




PostPosted: Sat Dec 07, 2002 9:40 pm   Post subject: (No subject)

could someone reply today or 2moro, cuz this is due on wednesday, thx Very Happy
Tony




PostPosted: Sat Dec 07, 2002 10:07 pm   Post subject: (No subject)

ya, well basically you obtain the value of the slider and the set volume level to that value.

The problem is, you can't do that in turing, as you need access to sound-card hardware and turing can't do that.

You can include some dlls for that in C++ and perhard reference them in VB as well if you need to do that.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 6 of 6  [ 82 Posts ]
Goto page Previous  1, 2, 3, 4, 5, 6
Jump to:   


Style:  
Search: