MS DOS
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
Go Back   Web Development Archives FAQs MS DOS

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Web Development Archives Sponsor:
  #1  
Old June 26th, 2008, 01:19 PM
dynamic1 dynamic1 is offline
Registered User
Dev Archives Newbie (0 - 499 posts)
 
Join Date: Jun 2008
Posts: 1 dynamic1 User rank is Just a Lowly Private (1 - 20 Reputation Level)  
Time spent in forums: 4 m 55 sec
Reputation Power: 0
Script to find and open file. Help.

Hello All.

I’m at the end of my wit here and I was wondering if any one could help me out.

My job requires me to monitor an application for several issues that may arise. For every issue there is a corresponding guide/manual on how to deal with the issue. All the guides are stored in one central location. So I would typical browse the central location and find the correct manual.

Originally the application itself was designed to automatically open the corresponding guide once the issue alert was received. However, for what ever reason it never worked and no one seemed to be motivated to make it work.


Well, I thought to my self here is a perfect opportunity to get organizational wide recognition. If I can get this to work, all will echo my name though out our organization. My name will be synonymous with greatness. However, my efforts have proven to be bitter sweet and I fear people will not recognize me as the intellectual dynamo I truly am.


So far I’ve been able to reduce the time it takes me to find the guides/manuals by running these two commands in a DOS screen:

echo off
FOR %G IN (*.xls) do (findstr /M "issue name" "%G")

Once the answer is returned I run copy the guide name into the following command and run it.

Start excel "guide name"


If at all possible I would like to just automate the entire process so that I just have to enter the issue name. I’ve come up with the script below, but am having problems coding the batch file to open the corresponding guide. Can any one help?






REM section (1) used to prompt for job name.

@Echo Off
:LOOP
ClS
Echo.
Set /P Job=Enter the issue name^>
Echo.
Set /P Answ=..Enter Y/y to proceed^>
If /I not "%Answ%"=="Y" GoTo :LOOP


Echo...Just a moment while I find a guide for the job %job%







REM Section (2) used to find the guide.



f:
echo off
Rem the double percent sighn i.e "%%" are only used in batch files. other wise it would be a single percent sign.


FOR %%G IN (*.xls) do (findstr /M %job% "%%G")


Rem this line will later be used to to automaticallys start the support guide.
Rem start excel "TSFS EBOInsurance Tidal Monitoring Worksheet Feb-11-08 MS.xls"




REM this continues where the section (1) left off.
Set Strg=
Set File=
Set Answ=
::End_Of-Batch

Reply With Quote
Reply

Viewing: Web Development Archives FAQs MS DOS > Script to find and open file. Help.


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest Threads | Shoutbox
Forum Jump

 Free IT White Papers!
 
How to Present Effectively Online
This white paper offers practical and actionable advice on the key steps that any presenter should consider as they plan and execute a Webinar or online meeting.

Request Your Free Technology Downloads!
 
Open Source Security Myths
Open Source Software (OSS) is computer software whose source code is available to the general public with relaxed or non-existent intellectual property restrictions (or arrangement such as the public domain), and is usually developed with the input of many contributors.

Request Your Free Technology Downloads!
 
Power and Cooling Capacity Management for Data Centers
This paper describes the principles for achieving power and cooling capacity management.

Request Your Free Technology Downloads!
 
Scalable, Fault-Tolerant NAS for Oracle - The Next Generation
For several years NAS has been evolving as a storage alternative for Oracle databases, and for good reason: NAS is quite often the simplest, most cost-effective storage approach for Oracle. Learn about the benefits that HP's approach to scalable NAS brings to Oracle environments in this comprehensive white paper.

Request Your Free Technology Downloads!
 
Understanding Web Application Security Challenges
This white paper discusses many common threats and preventive measures for Web application security, and explains what you can do to help protect your organization.

Request Your Free Technology Downloads!
 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2009 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway
Stay green...Green IT