Page 3 of 4
Posted: Mon Mar 08, 2004 7:38 pm
by Kris_a
Sorry, I saw this and just had to improve it...!!
Code: Select all
Procedure.l GetOSVersion()
Vers.l = OSVersion()
select vers
case #PB_OS_Windows_NT3_51
procedurereturn 1
case #PB_OS_Windows_95
procedurereturn 2
case #PB_OS_Windows_NT_4
procedurereturn 3
case #PB_OS_Windows_98
procedurereturn 4
case #PB_OS_Windows_ME
procedurereturn 5
case #PB_OS_Windows_2000
procedurereturn 6
case #PB_OS_Windows_XP
procedurereturn 7
case #PB_OS_Windows_Future
procedurereturn 8
endselect
procedurereturn -1
EndProcedure
Posted: Mon Mar 08, 2004 10:37 pm
by DriakTravo
LoL, thanks for improving my code, I am still kinda new to programming and still don't know the most efficient way of doing things. I was just trying to make sence out of the OSVersion()
Posted: Tue Mar 09, 2004 1:16 am
by PB
> I was just trying to make sence out of the OSVersion()
These two examples were made directly from the manual/help:
Code: Select all
Select OSVersion()
Case #PB_OS_Windows_NT3_51 : Debug "You are running NT 3.51"
Case #PB_OS_Windows_95 : Debug "You are running 95"
Case #PB_OS_Windows_NT_4 : Debug "You are running NT 4"
Case #PB_OS_Windows_98 : Debug "You are running 98"
Case #PB_OS_Windows_ME : Debug "You are running ME"
Case #PB_OS_Windows_2000 : Debug "You are running 2000"
Case #PB_OS_Windows_XP : Debug "You are running XP"
Case #PB_OS_Windows_Future : Debug "You are running Unknown"
EndSelect
Code: Select all
If OSVersion()=>#PB_OS_Windows_98
Debug "You are running 98 or higher."
EndIf
..
Posted: Tue Mar 09, 2004 10:36 am
by NoahPhense
GPI wrote:@GPI
Why you had to say badwords just for that?
Some Standard "Words":
Code: Select all
AFAIK : as far as i know
BTW: by the way
FAQ(S): Frequently asked question(s)
FUP(2): Floow up (to)
IM([NS]H)O: in my([not so] humble) opinion
LOL: laughing out loud
OT: off topic
Q&A: questions and answers
RTFL: rolling on the floor laughing
RT(F)M: read the (fucking) manual
THX: thanks
TIA: thanks in advance
Freak said, that you should see in the help-file about "osversion()" and then you ask for something, which stand in the help-file.
Hmm, and I've been using rofl all these years..
Code: Select all
ROFL: rolling on the floor laughing
- john
Posted: Tue Mar 09, 2004 11:15 am
by Fred
I don't see the point of the 'GetOSVersion()' wrapper. The PB constants are already sorted in this order and are much more explanatory than using 1, 2, 3, 4 or wathever

Posted: Tue Mar 09, 2004 11:15 am
by DriakTravo
LMAO: Laugh my ass off
Posted: Tue Mar 09, 2004 3:00 pm
by LarsG
and to combine a couple, for the ultimate:
ROFLMAO -
Rolling
On the
Floor
Laughing
My
Ass
Off

Posted: Tue Mar 09, 2004 7:12 pm
by merendo
*lol* can also mean: Lots of Laughs
..
Posted: Wed Mar 10, 2004 12:51 am
by NoahPhense
Code: Select all
OS = Val(Bin(OSVersion()))
Select OS
Case 101
Debug "Windows NT 3.51"
Case 1010
Debug "Windows 95"
Case 10100
Debug "Windows NT 4.0"
Case 11110
Debug "Windows 98"
Case 101000
Debug "Window ME"
Case 110010
Debug "Windows 2000"
Case 111100
Debug "Windows XP"
Case 1100100
Debug "Future Version of Windows"
Default
Debug "Hmmm?"
EndSelect
rofl
- np
Posted: Wed Mar 10, 2004 1:36 am
by DriakTravo
Default
Debug "Hmmm?"
ROFLMAO!!!!!

Posted: Wed Mar 10, 2004 6:02 am
by Soulfire
Code: Select all
Select OSVersion()
Case #PB_OS_Windows_NT3_51 : Debug "lmfao"
Case #PB_OS_Windows_95 : Debug "rofl"
Case #PB_OS_Windows_NT_4 : Debug "lol"
Case #PB_OS_Windows_98 : Debug "stfu"
Case #PB_OS_Windows_ME : Debug "smd"
Case #PB_OS_Windows_2000 : Debug "nm"
Case #PB_OS_Windows_XP : Debug "gj"
Case #PB_OS_Windows_Future : Debug "wtf?"
EndSelect
Posted: Wed Mar 10, 2004 6:20 am
by Dreglor
is it me or is this topic is way off
Posted: Wed Mar 10, 2004 10:20 am
by LarsG
Dreglor wrote:is it me or is this topic is way off
It's probably just you...

..
Posted: Wed Mar 10, 2004 3:59 pm
by NoahPhense
Dreglor wrote:is it me or is this topic is way off
Code: Select all
Declare.l IsTopicWayOff()
Enumeration
#_No
#_Yes
EndEnumeration
If IsTopicWayOff() = #_Yes
Debug "Maybe just a little..."
Else
Debug "Nah.. "
EndIf
End
Procedure.l IsTopicWayOff()
hmm = Random(1)
If hmm = 0
ProcedureReturn #_No
Else
ProcedureReturn #_Yes
EndIf
EndProcedure
- np
omg
Posted: Thu Mar 11, 2004 1:04 am
by dagcrack
Oooo! 8O I think that... we got the point about the command
Hey guys I just wanted to know why it gave 60.