Copyright: Alessandro Oddera Software


Contents
 	Oddera Drag&Script help

Introduction:

Basic concepts

HTML example

Autocad example

DOS example

Templates

Send To Interface

Quick:

Drag&Script variables

Open and Save List

Output file

Relative Path

Path radio buttons

Invert slash

Save local

Right Click

Auto Drag

Order Information


 Basic concepts

This program let you create a list of files, simply dragging them over it.

This can be very useful for:

 	writing web HTML pages,

creating script for programs, like Autocad,

creating DOS batch file, for users and programmers.

Oddera Drag&Script will create a text file containing a list of the file you have dragged over it, it will write Header and Queue before and after any file name.

Oddera Drag&Script will write MainHeader at the beginning of text file, and MainQueue at the end of text file.

To create a file you must:

•	drag some files over Oddera Drag&Script

•	optionally write Header and Queue

•	optionally write MainHeader and MainQueue

•	click Create button

•	clic View button to open Notepad and see the result

Example:

You drag two file named:

C:\Document\MyFileOne.doc

C:\Document\MyFileTwo.doc

You type in the Header text box: "This is the header "

You type in the Queue text box: " This is the queue"

the output file will be:

line 1: This is the header C:\Document\MyFileOne.doc This is the queue

line 2: This is the header C:\Document\MyFileTwo.doc This is the queue


Html example
 Html

Very often when writing HTML code is necessary to include a serie of file names with appropriate tags.

Note: in these examples you must type the double quote  in the Header and Queue text

Example 1 (creating a simple HTML list)

Suppose you have the following three graphic files:

C:\Html\WebPage\Images\ImageOne.jpg

C:\Html\WebPage\Images\ImageTwo.jpg

C:\Html\WebPage\Images\ImageThree.jpg

Suppose you are working with file:

C:\Html\WebPage\MyGallery\Gallery.htm

If you want realize appropriate links for all images you can do so:

Check the Relative Path radio button

Set Header text to:

<IMG SRC="

Set Queue text to:

" ALT="Image" vspace=7 BORDER=0  > <BR> A Photo () <P>

Now you can click Create button, then View button to open Notepad and see the output.

The output will be so:

<IMG SRC="..\Images\ImageOne.jpg" ALT="Image" vspace=7 BORDER=0  > <BR> A Photo () <P>

<IMG SRC="..\Images\ImageTwo.jpg" ALT="Image" vspace=7 BORDER=0  > <BR> A Photo () <P>

<IMG SRC="..\Images\ImageThree.jpg" ALT="Image" vspace=7 BORDER=0  > <BR> A Photo () <P>

Now you can copy the lines above into your Gallery.htm, and manually insert the appropriate title for the image:

<IMG SRC="..\Images\ImageOne.jpg" ALT="Image" vspace=7 BORDER=0  > <BR> A Photo (My house) <P>

<IMG SRC="..\Images\ImageTwo.jpg" ALT="Image" vspace=7 BORDER=0  > <BR> A Photo (My girl) <P>

<IMG SRC="..\Images\ImageThree.jpg" ALT="Image" vspace=7 BORDER=0  > <BR> A Photo (My cat) <P>

Example 2 (automatically set Alternative text and image text)

We will use the same files of example 1:

C:\Html\WebPage\Images\ImageOne.jpg

C:\Html\WebPage\Images\ImageTwo.jpg

C:\Html\WebPage\Images\ImageThree.jpg

We will use more advanced Drag&Script variables  :

If you want realize appropriate links for all images you can do so:

Set Relative Path like in example 1

Set Header text to:

<IMG SRC="

Set Queue text to:

" ALT="AO_NAME" vspace=7 BORDER=0  > <BR> AO_NAME <P>

The output file will be:

<IMG SRC="..\Images\ImageOne.jpg" ALT="ImageOne" vspace=7 BORDER=0  > <BR> ImageOne <P>

<IMG SRC="..\Images\ImageTwo.jpg" ALT="ImageTwo" vspace=7 BORDER=0  > <BR> ImageTwo <P>

<IMG SRC="..\Images\ImageThree.jpg" ALT="ImageThree" vspace=7 BORDER=0  > <BR> ImageThree <P>

this is wrong and don't work with many browser, cause of you used symbol \ instead of /

to solve the problem simply check the button "Invert slash", the output will be:

<IMG SRC="../Images/ImageOne.jpg" ALT="ImageOne" vspace=7 BORDER=0  > <BR> ImageOne <P>

<IMG SRC="../Images/ImageTwo.jpg" ALT="ImageTwo" vspace=7 BORDER=0  > <BR> ImageTwo <P>

<IMG SRC="../Images/ImageThree.jpg" ALT="ImageThree" vspace=7 BORDER=0  > <BR> ImageThree <P>

Example 3 (automatically create a link beetwen image and little icon)

We will use the same files of example 1:

C:\Html\WebPage\Images\ImageOne.jpg

C:\Html\WebPage\Images\ImageTwo.jpg

C:\Html\WebPage\Images\ImageThree.jpg

Suppose these files are little bitmap (i.e. 50x50 pixels), and you have related big images named:

C:\Html\WebPage\Images\ImageOne_Big.jpg

C:\Html\WebPage\Images\ImageTwo_Big.jpg

C:\Html\WebPage\Images\ImageThree_Big.jpg

We want when the user click the little image the Internet browser show the big image.

We will use more advanced Drag&Script variables  :

If you want realize appropriate links for all images you can do so:

Check the Relative Path radio button

Check the Invert slash radio button

Set Header text to:

<A HREF="AO_RELPATH/AO_NAME_BigAO_EXT"><IMG hspace=10 SRC="

Set Queue text to:

" ALT="AO_NAME" > </A>

The output file will be:

<A HREF="../Images/ImageOne_Big.jpg "><IMG hspace=10 SRC="../Images/ImageOne.jpg " ALT="ImageOne"> </A>

<A HREF="../Images/ImageTwo_Big.jpg "><IMG hspace=10 SRC="../Images/ImageTwo.jpg " ALT="ImageTwo"> </A>

<A HREF="../Images/ImageThree_Big.jpg"><IMG hspace=10 SRC="../Images/ImageThree.jpg " ALT="ImageThree"> </A>

More:

You can also set Main Header and Main Queue, i.e.:

Set Main Header text to:

<HTML>

<HEAD>

<TITLE>Oddera Drag&Scrip generator</TITLE>

</HEAD>

<BODY>

Set Main Queue text to:

</BODY> </HTML>

This will place appropriate html tag to the beginning and end of output file.


 Autocad

Some programs, like Autocad can read a script file and execute the command written inside it.

Note: in these examples you must NOT type the double quote " in the Header and Queue text, remember Acad use space and return to execute commands.

Example 1 (plot some files)

This example is very useful for Autocad, you can create a long list of file to print, create a script file, then let Acad print during the night.

Suppose you have the following three files:

C:\MyDrawing\DrawOne.dwg

C:\MyDrawing\DrawTwo.dwg

C:\MyDrawing\DrawThree.dwg

Suppose you are working with file:

C:\MyDrawing\MyScript.scr

If you want to create appropriate script to plot these files:

Uncheck the Relative Path radio button

Set Header text to:

"_open "

Set Queue text to:

" _plot

"

Now you can click Create button, then View button to open Notepad and see the output.

From Autocad you can use command SCRIPT to execute C:\MyDrawing\MyScript.scr

Example 2 (create an Autocad slides presentation)

Suppose you have the following three files:

C:\MyDrawing\DrawOne.sld

C:\MyDrawing\DrawTwo.sld

C:\MyDrawing\DrawThree.sld

Suppose you are working with file:

C:\MyDrawing\MyScript.scr

If you want to create appropriate script to make a slide presentation:

Uncheck the Relative Path radio button

Set Header text to:

"_vslide "

Set Queue text to:

"

_delay=2000

"

Now you can click Create button, then View button to open Notepad and see the output.

From Autocad you can use command SCRIPT to execute C:\MyDrawing\MyScript.scr


 DOS

Windows 95 is nice, but is really hard to perform some file automation with it, i.e.:

Example 1 (rename some files)

Suppose you have the following three files:

C:\Document\One.txt

C:\Document\Two.txt

C:\Document\Three.txt

You want change the file extension from txt to doc

Suppose you are working with file:

C:\Document\MyScript.bat

If you want to create appropriate script to plot these files:

Uncheck the Relative Path radio button

Set Header text to:

rename

Set Queue text to:

AO_NAME.doc

Now execute MyScript.bat, it will rename the three file so:

One.doc

Two.doc

Three.doc

Example 2 (for programmers: creating an installation list)

Suppose you are developing a program, the program is composed from a lot of files you distribute on a diskette, time to time you add some files to it, your batch installation file is something like that:

copy myprog.exe %1

copy file1.dat %1

copy file2.dat %1

Suppose you are working with file:

C:\Install\MyScript.bat

If you want to create appropriate batch file:

Uncheck the Relative Path radio button

Set Radio button No Path

Set Header text to:

copy

Set Queue text to:

 %1

this will create your MyScript.bat for installation.

Now you can use from File menu the command Save List to save the list of files, when you need to add some files to your program, you can use Open List to restore previously selected files, and add to it only the newest, then you can create again the MyScript.bat.

Obviously you can do something more advanced that a batch file, i.e. you can create an output with list and command for enhanced program, like Install Shield, inserting variable name and so on.


 Templates

Templates are file with your settings, it's very important you save your favorite settings in a template, settings are:

Header text

Queue text

Main Header text

Main Queue text

Path type (Full, Relative, No path,None)

Invert \ to /

and so on.

Local informations like output file will be saved in template only if you check the Relative Path radio button.

Saved template can be quickly access from Template menu.

See: Save local


 Send To Interface

Send to Inteface is a great thing to improve your productivity, you can access Drag&Script directly from your Win95 Explorer, and create line of code into Clipboard ready to copy in your documents.

To enable Send To Interface you must create a Shortcut for Drag&Script.exe in your \Windows\Sendto folder, do the following:

•	From your Win95 Explorer (File manager) go to Drag&Script folder and right click over "Drag&Script.exe", then choose "Copy".

•	Now go to your \Windows\Sendto folder, right click in right pane of Explorer and choose "Create Shortcut".

•	Tha's all, you can choose the action Drag&Script must to do from Drag&Script File menu "Set Send To Interface"

What Send To Inteface do:

You can right click any file from Win95 Explorer, then choose Sendto-> Drag&Script; Drag&Script will analize the file, and make one of the following actions (depending of your settings)

•	Create a Relative Path for your file, and put the created path into Clipboard (i.e. ../../Mydrawing/Draw22.jpg)

•	Create a "line" (header, filename, queue) and put it into Clipboard (i.e. <IMG SRC= ../../MyDrawing/Draw22.jpg>

If you are writing things like HTML code, you can keep your HTML editor and Explorer visible, and iconize Drag&Script, from Explorer right click over a file and use Sendto Drag&Script command, then switch in your HTML editor and choose Paste command.

That's quick, that's fast, that's great!!!


Order Informations

Order Informations:

Your support is VITAL to allow us to continue producing more great updates to this and other programs like it.

Thank you to view order section.

Oddera Drag&Script's price

One copy: $19.95

For technical support or comments about this program, you may write to:

aoddera@ unige.it

Home page at:

http://www.prog.arch.unige.it/~aoddera/Homeao.htm

For your convenience we have contracted another company, NorthStar Solutions, to process any orders you may wish to place with your Visa, MasterCard, or Discover card.

NorthStar Solutions can be easily contacted *for orders only* via any of the following methods:

** PHONED ORDERS **

Calls are taken 10 am - 8 pm, EST, Monday thru Saturday.

1-800-699-6395 (From the U.S. only.) Toll Free

1-803-699-6395 (wherever you are)

** FAXED ORDERS **

Available 24 hours.  International & business orders are encouraged.

1-803-699-5465

** E-MAILED ORDERS **

CompuServe: 71561,2751

America Online: starmail

Internet: 71561.2751@compuserve.com

** MAILED ORDERS **

You may register with a check or money order.

Make them payable to "NorthStar Solutions" and send them to:

PO Box 25262, Columbia, SC  29224

Please provide (or be prepared to provide) the following informations:

*-- Your full name.

*-- The program name and program version you are registering.

*-- Your Visa, MasterCard, or Discover # and its expiration date (if using credit card).

*-- Your phone number.

*-- Your mailing address.

*-- Your E-Mail address if you have it (so NorthStar Solutions can send you an E-Mail confirming your order and so we can contact you easily with any important follow-up information, upgrade announcements, etc.).


You can use special internal variables to split file name in separate components, the following example suppose a file named:

C:\Document\MyText.doc followed by other 9 files

AO_DRIVE  	the drive name i.e.: C:

AO_PATH   	the path i.e.: \Document

AO_NAME  	the file name i.e.: MyText

AO_EXT 	the file extension (including dot) i.e.:  .doc

AO_RELPATH	the relative path i.e.: ..\Document (this depend from where you save your output file)

AO_GETSELINDEX	the number of file in list: 1

AO_GETCOUNT	the total number of files in list: 10

All names are case sensitive, you MUST write it all capitalized.

Internal variables are used in Header and Queue text.

i.e. you can set the Header to:

Name: AO_NAME, on drive: AO_DRIVE, full name is:

to obtain:

Name: MyText, on drive C:, full name is: C:\Document\MyText.doc.


The commands Open and Save List from File menu are intended for programmers.

These commands leave you save a list of files dragged on Drag&Script, it will save only the file names, no more.

This can be useful if you have a list created with files from different folders, and you plain to make future changes (i.e. adding or removing some files time to time), so you can save the list, and restore it without needing to select again all the files.


The Output file is the file where your script will be created. You must supply a valid file name. You should use an extension valid for your use, i.e. .htm for HTML code, .scr for Autocad script, .bat for batch file, and so on.


Relative path will be calculated between position of any file in list-box, and RELPATH variable.

RELPATH variable will be automatically set to position of output file.

RELPATH variabled is the gray text at the bottom right corner.

To manually change RELPATH var drag a folder over "Relative Path" radio button, it's useful to create and copy a single line (rigth click over list box) without changing output file name.

Relative path will be used only if you check the Relative Path radio button.

The relative path is used often in HTML code, it make your code disk-undependent, so you can easily move a group of folder and the links still works.

See: HTML example


The Path Radio Buttons define how file name will be included in your script.

The Full Path button write file path and file name.

The Relative Path button enable the use of Relative Path.

The No Path write only file name.

The None radio button write nothing, in such case is probable you want use Advanced Drag&Script variables .


The Invert Slash check box is useful to write HTML code.

It will change any recourrence of symbol \ in your file with /

i.e.

\MyFolder\MyFile.htm

will become:

/MyFolder/MyFile.htm

Some WEB browser (and server) like Msie work with these sintaxes both, but some other browser like Netscape are confused if you use the normal DOS \, so is recommended you ever invert the \ when you are writing HTML code.

The right HTML sintax is:

/MyFolder/MyFile.htm


The Save Local check box work with Templates.

If the Save Local check box is checked, local informations will be saved and restored from templates.

Local informations are relative to your computer.

Local informations are:

Output file: C:\MyData\Test.txt

Relative Path: C:\MyData


Right click over the file list to open context menu.


You have varius way to access Auto Drag feature:

•	drag a single file over Auto Drag button

•	drag a single file over Relative Path radio button

•	drag a single file over OutFile button or Output file text box

With Auto Drag you will be able to:

•	Copy file name to Clipboard, or

•	Copy a single "line" (head, filename, queue) in to Clipboard, or

•	Set temporary Relative Path (this is the only way to set a Relative Path different from Output File), or

•	Set the Output file