Home / Microsoft / Microsoft DOS / send all ur succesfull scripts
0 Members and 3 Guests are viewing this topic. « previous next »
Pages: 1 2 [3]  All - (Bottom) Print
Author Topic: send all ur succesfull scripts  (Read 3314 times)
Helpmeh
Egghead



Thanked: 117
Posts: 3,608

Experience: Experienced
OS: Windows XP


Roar.

1
« Reply #30 on: November 27, 2009, 05:04:45 AM »

When did you purchase Computer Hope in order for the thread to be yours?

I asked a simple question.
Obviously he clicked the offer to buy CH when he registered.
IP logged

Where's MagicSpeed?
Quote from: 'matt'
He's playing a game called IRL. Great graphics, *censored* gameplay.
pds
Topic Starter
Beginner



Thanked: 2
Posts: 58



konichiwa kamisan ^_^

« Reply #31 on: December 09, 2009, 08:50:28 AM »

i have made a automatic cd opener in dos with vbs

MENU SOURCE
Code: [Select]
@echo off
cls
title PDS CD/DVD RAW OPENER (DOS) VER 2.9
:INPUT
echo copyright by team p.d.s.
set/p "input=>
if %input%==help goto HELP
if %input%==open goto OPEN
if %input%==take out goto OPEN2
if %input%==exit goto EXIT
if %input%==cmd goto C
if %close%==close goto CLOSE
:HELP
echo
open = to open your cdrom slot
echo exit = to close this window
echo C CMD/DOS
echo e-mail:pdsboss@gmail.com
goto INPUT
:EXIT
exit
:OPEN
start open.vbs
:C
cls
command.com

OPEN source (.vbs)

Code: [Select]
Set oWMP = CreateObject("WMPlayer.OCX.7")
Set colCDROMs = oWMP.cdromCollection
colCDROMs. item(i).Eject

(i hope you like this stuff)
copyright by pds *me*
IP logged
BC_Programmer
Mastermind


Thanked: 697
Posts: 15,881

Computer: Specs
Experience: Beginner
OS: Windows 7


Pinkie Pie is best pony

BC-Programming.com 1 1
« Reply #32 on: December 09, 2009, 10:09:56 AM »

VB4,5 and 6 Code module equivalent that requires no external ActiveX dependencies.

Code: [Select]
Option Explicit
Private Declare Function mciSendString Lib "winmm.dll" Alias "mciSendStringA" (ByVal lpstrCommand As String, ByVal lpstrReturnString As String, ByVal uReturnLength As Long, ByVal hwndCallback As Long) As Long

Public Sub CloseCD()
     Dim Lngreturn As Long
     Dim Strreturn As Long
     Lngreturn = mciSendString("set CDAudio door closed", Strreturn, 127, 0)
End Sub
Public Sub OpenCD()
     Dim Lngreturn As Long
     Dim Strreturn As Long
     Lngreturn = mciSendString("set CDAudio door open", Strreturn, 127, 0)
End Sub

There are other MCI commands that could be executed, including opening a sequencer and playing CD audio, seeking, etc. However I haven't used MCI for a very long time.
IP logged

My Blog

BASeBlock 2.3.0 (NOW WITH MACGUFFINS!)
Salmon Trout
Sage



Thanked: 546
Posts: 7,952

Computer: Specs
Experience: Beginner
OS: Unknown

1
« Reply #33 on: December 09, 2009, 12:45:54 PM »

Autoit is so handy! Even allows one-liners from the prompt.

Code: [Select]
C:\>Autoit3 /AutoIt3ExecuteLine  "CDTRay ('X:', 'open')"
C:\>Autoit3 /AutoIt3ExecuteLine  "CDTRay ('X:', 'closed')"

X: is my optical drive's letter.



IP logged


Proud to be European
ghostdog74
Mentor



Thanked: 26
Posts: 1,511


« Reply #34 on: December 09, 2009, 09:15:09 PM »

Autoit is so handy! Even allows one-liners from the prompt.

Code: [Select]
C:\>Autoit3 /AutoIt3ExecuteLine  "CDTRay ('X:', 'open')"
C:\>Autoit3 /AutoIt3ExecuteLine  "CDTRay ('X:', 'closed')"

X: is my optical drive's letter.

well, that's called abstraction :).

vbscript:
Code: [Select]
Const CDROM = 4
Set objFS=CreateObject("Scripting.FileSystemObject")
Set shell = CreateObject("Shell.Application")
For Each drives in objFS.Drives
  If drives.DriveType = CDROM Then
    cd=drives.DriveLetter & ":\"   
    'Eject
  shell.Namespace(17).ParseName(cd).InvokeVerb("E&ject")   
  End If
Next
Code: [Select]
c:\test> cscript //nologo eject.vbs
there, also one line :)
IP logged

pds
Topic Starter
Beginner



Thanked: 2
Posts: 58



konichiwa kamisan ^_^

« Reply #35 on: December 12, 2009, 02:33:37 AM »

i only know C++ C# C DOS
I'm study VBS
IP logged
ghostdog74
Mentor



Thanked: 26
Posts: 1,511


« Reply #36 on: December 12, 2009, 02:42:56 AM »

Code: [Select]
Set oWMP = CreateObject("WMPlayer.OCX.7")
Set colCDROMs = oWMP.cdromCollection
colCDROMs. item(i).Eject

(i hope you like this stuff)
copyright by pds *me*
what is "i"  in "item(i)" ? and why is there a space between colCDROMs. and "item(i)" ??
IP logged

pds
Topic Starter
Beginner



Thanked: 2
Posts: 58



konichiwa kamisan ^_^

« Reply #37 on: December 13, 2009, 04:34:26 AM »

those are values, object, commands and variables
IP logged
ghostdog74
Mentor



Thanked: 26
Posts: 1,511


« Reply #38 on: December 13, 2009, 05:24:34 AM »

those are values, object, commands and variables
i know what they are called. What i mean is , where is "i" variable defined in the vbs??
IP logged

pds
Topic Starter
Beginner



Thanked: 2
Posts: 58



konichiwa kamisan ^_^

« Reply #39 on: December 13, 2009, 06:40:03 AM »

you know variable "i" in vbs i that (i) (350)
IP logged
Salmon Trout
Sage



Thanked: 546
Posts: 7,952

Computer: Specs
Experience: Beginner
OS: Unknown

1
« Reply #40 on: December 13, 2009, 07:01:52 AM »

pds, unfortunately you are (and have been) posting nonsense. if you cannot answer questions properly, do not answer them at all.
IP logged


Proud to be European
ghostdog74
Mentor



Thanked: 26
Posts: 1,511


« Reply #41 on: December 13, 2009, 06:07:45 PM »

i can only guess that those code are not written by him but cut and paste and then doing it blindly
IP logged

Helpmeh
Egghead



Thanked: 117
Posts: 3,608

Experience: Experienced
OS: Windows XP


Roar.

1
« Reply #42 on: December 13, 2009, 07:38:16 PM »

i can only guess that those code are not written by him but cut and paste and then doing it blindly
and what makes it funnier is that she "copyrighted" them so we would think she made them.
IP logged

Where's MagicSpeed?
Quote from: 'matt'
He's playing a game called IRL. Great graphics, *censored* gameplay.
Quantos
Guru



Thanked: 158
Posts: 4,041

Experience: Experienced
OS: Windows Vista


Union Proud IW 720

Iron Workers Local 720 1 1
« Reply #43 on: December 13, 2009, 09:11:15 PM »

wat? No. Your post applies quite well.  ;D
I thought you meant poster as in the image that I posted, sorry man, didn't realize that you meant the OP.
IP logged

"Ah the agony, ah the shame, making one man's privates - public for a game..."  Mel Brooks
pds
Topic Starter
Beginner



Thanked: 2
Posts: 58



konichiwa kamisan ^_^

« Reply #44 on: December 14, 2009, 08:11:33 AM »

this script isn't written by me but by a friend

i only made a dos menu for it.

why your so hard on me if you wanna play the game so i can play it hard too
IP logged
Pages: 1 2 [3]  All - (Top) Print 
Home / Microsoft / Microsoft DOS / send all ur succesfull scripts « previous next »
 


Login with username, password and session length

Old Forum Search | Forum Rules
Copyright © 2010 Computer Hope ® All rights reserved.
Powered by SMF 2.0 RC3 | SMF © 2006–2010, Simple Machines LLC
Page created in 0.114 seconds with 19 queries.