You are on page 1of 3

//rem this program generates a fibonacci series.

sub main
dim i as integer
dim j as integer
dim fib as integer
dim n as integer
dim k as integer
i= inputbox("enter the starting value")
j= inputbox("enter the next value")

k= inputbox("enter the total number of entries to be displayed")


for n = 1 to k step 1
fib = i+j
i=j
j=fib
msgbox fib
next

end sub

//rem this program takes values and prints their sum//

sub main
dim i as integer
dim j as integer
dim trns as integer
dim iter as integer
dim entry
msgbox " this program takes values and prints them one by one"

for i = 1 to 5 step 1
entry=inputbox(" please enter integer values")

j=j+entry
next

msgbox j

end sub

//rem this program calculates a factorial of any number less than88/

sub main
dim x as single
dim msgtext, pi
dim factorial as integer
pi=3.14159
i: x=inputbox("enter an integer between 1 and 88: ")
if x<=0 then
exit sub
elseif x>88 then
msgbox "the number you entered is too large. try again."
goto i
end if
factorial=sqr(2*pi*x)*(x^x/exp(x))
msgtext="the estimated factorial is: " & format(factorial, "scientific")
msgbox msgtext
end sub

//open notepad

sub main
shell "notepad.exe",3
inputkeys "hello, world.{enter}notepad is maximized."
end sub

//call script function

sub main
startapplication("notepad.exe")
appactivate "untitled - notepad"
doevents
inputkeys "hello, world.{enter}"
msgbox" generate the fibonacci series"
callscript "harsh 17"
end sub

//

sub main

dim result as integer

'initially recorded: 12/18/2007 4:38:35 pm


'script name: rechhh

window setcontext, "class=shell_traywnd", ""


toolbar click, "text=quick launch;\;itemtext=show desktop", "coords=11,8"

startapplication("notepad.exe")
appactivate "untitled - notepad"
doevents

inputkeys "hey lets generate fibonacci series.{enter}"


inputkeys "^shc{enter}"
inputkeys "%{f4}"
msgbox" generate the fibonacci series"

callscript "harsh 17"

end sub

//

sub main

sqashellexecute "d:\frame.xls","",""
end sub

// type location wise in excel sheet//

sub main

sqashellexecute "d:\frame.xls","",""
inputkeys "fail{tab}{tab}{tab}{tab}{tab}teri to fail ho gaya"
inputkeys "{down}{tab}{tab}{tab}waah pass ho gaya"
inputkeys "{tab}{left}{left}we've done it"

end sub

//

sub main

dim i as integer
dim j as integer
dim k as integer
dim rc(10,10) as integer

sqashellexecute "d:\frame.xls","",""
k= inputbox("enter the integer value")
j= inputbox("enter the name")

for i = 1 to k step 1
inputkeys "{tab}"
next

for j = 1 to j step 1
inputkeys "{down}"
next

inputkeys "status"

rc(k,j) =1000
'msgbox rc(k,j)

'msgbox rc(k,j) =

'msgbox rc(i,j)

end sub
//

You might also like