Archive

Posts Tagged ‘Vbscript’

Bash Shell/wmi Vbscript Script

November 8th, 2009 Comments off

We are the License Management department in IT Services of a Global 50 company headquartered in Germany with data centers in over 30 countries. We have an urgent need for a expert HPUX sys admin (preffered) with BASH and WMI VBScript scripting skills to update several scripts in HP Asset Tool that help us discover installations of specific software titles.

HPAT is an agent-less tool that runs on unix/linux/sun (BASH shell scripts) and Windows (WMI VBScript). It consists of a central HPAT server and HP free database that stores the results. The HPAT server connects to the servers being “scanned” vie ssh and copies over the scripts to be executed, including general hardware and software scripts and specific software discovery scripts. Output from the scripts is then formatted using XML and stored in the SQL database on the HPAT server. Reports are then written in SQL and stored as csv/excel files. The operation is similar under Windows

We are looking for a BASH scripting expert (required), also with WMI VBScript (required) experience and a solid SQL background (preferred), to help us over the next 4 weeks update the software discovery scripts to recognize our top 21 suppliers (about 500 titles). the majority of the discovery script structure is “cut and paste” from one script to the next. The differences are in the names of the files to be discovered. the HP HPAT will provide an orientation session and support during the engagement.

The engagement can be done eithe onsite in the Czech Republic or remotely anywhere in the world. Secure access will be given to the HPAT Server via VPN. HP and company support will be provided from the Czech Republic (english speaking) during normal working hours, as well as email.

Script Samples and full SOW will be provided to interested parties. Engagement will start late next week (11/12/2009) if the right candidate is available.

Vbscript Office 2007 Upgrade

August 25th, 2009 Comments off

I am trying to come up with a vbscript that does the following:

-Checks for “Microsoft Office Access 2003″ on the computer and runs a setup.exe from a network share accordingly and quits.
-If that’s not installed, then it checks for “Microsoft Office Professional 2003″ and runs the setup.exe from the network share if it’s detects and quits.

If it doesn’t detect either, then script:

-Checks for “Microsoft Office 2003 Standard” and runs a network share setup.exe if it’s detected and quits.

If 2003 standard not detected, then:

-Checks for “Microsoft Office 2003 Professional” and runs a network share setup.exe if it’s detected and quits.

If it doesn’t find any of all of the above titles, then script should go ahead and run a setup.exe from a network share and quits.

Is this possible?

Vbscript Fixed Limit Delimiter

July 9th, 2009 Comments off

Hi There. We need to have two possibly three VBScript functions modified to read fixed limit delimited text files which are output from a testing system, then build SQL statements to insert them into an Oracle database. We are using a proprietary system that uses VBScript and the system takes care of all the database connections, so that isn’t something you need to worry about on our end. As long as you have a similar type database, and can create the three simple tables with 5 exact same columns each, to get the script functioning properly, we will insert the proper db connections using existing functionality in our script. Currently the VBScript function (and would appreciate it staying VBScript) reads comma delimited text files for a similarly related legacy system’s output files, so the script is mostly written. With my less complex scripting ability, I made some attempts, but need a more proficient expert to finish and get the script functioning properly. For the right person, this shouldn’t take more than an hour or two. We do need this done quickly to avoid minimal downtime.

I have attached the Script to be modified and the two types of files it needs to read and insert into the database tables.

I will pay promptly through paypal or your reasonable method of choice. Thank you for your consideration on this!

Vb Gui To Replace Dos Menu

April 7th, 2009 Comments off

This small project is to create a VB front end that should replace a simple DOS menu.
Currently the DOS menu promtps the user for 5 arguments (name_string, scenario, user, pass, site) and then allows the user to select one of the 30 menu items.
Depending on the menu item choose, the Batch file just call a VBscript.
I don’t need integration with that script. Just the VB front end that will pass the command depending on what the user has clicked.
I also don’t need a fully populated VB GUI, as long as I can then edit the source, I will add more options myself.
Easy but no time.

**********
User Input
**********
set /P target_san=Enter Target Name]. (%target_name%):
If ‘%target_san%’==” goto SYNTAX
set /P scenario=Enter Scenario [A, B, C] (%scenario%):
If ‘%scenario%’==” goto SYNTAX
set /P username=Enter Username (%username%):
If ‘%username%’==” goto SYNTAX
set /P password=Enter Password (%password%):
If ‘%password%’==” goto SYNTAX
set /P trigram=Enter Site Trigram(%trigram%):
If ‘%trigram%’==” goto SYNTAX
……
Target name should be radio buttons with 3 names hardcoded
scenario is a drop down.
rest is InpuBox.

echo. General settings
echo. ———————
echo. 1. Action 1
echo. 2. Action 2
etc….

:ENTER
set /p choice=
if ‘%choice%’==’1′ set label=action_01
if ‘%choice%’==’2′ set label=action_02
etc…

Each choice is unique (there are 40 of them) so a radio box is enough.
No multiple tick box are required and drop down list too prone to errors.

Then a big Green button that says go :-)

REM ************************************
REM Command sent to the VBscript
REM ************************************

cscript “:PathVBscript.vbs” %target_name% %LABEL% %scenario% %username% %password% %trigram%

So the VB GUI is just used to create the command line above and display what’s going on in a DOS prompt embedded in the interface. The VBscript issues some Command Prompt so we need to see them.

Convert Vbscript To Javascript

March 17th, 2009 No comments

I have a very small project.. convert the following VBScript code to JavaScript (so it will work in Firefox and IE.. not just Internet Explorer!):

<script language=”VBScript”>
<!–
Sub generate_FSCommand(ByVal command, ByVal args)
call generate_DoFSCommand(command, args)
end sub
–>
</script>

This code is being called forth from a Flash component. It works great within Internet Explorer.

This is the JavaScript code that is called from the VbScript:

<script language=”JavaScript”>
<!–
function generate_DoFSCommand(command, args) {
f = document.productDetails;
if ( command == “agf_arg” ) {
f['xV'].value = args;
f['xVs'].value = args;
}
}
–>
</script>

Bear