Separate application paths?

Is there a way to have each application (word processing, spreadsheet, etc.) save to a separate folder? I currently use a separate folder for MS Word, Excel, etc. I don't want to use a common folder like "My Documents" for everything. I want to continue with my current folder arrangement.

[321 byte] By [janchadwell] at [2007-11-25 22:34:45]
# 1

Hello there:

In orden to change "My documents" in SO go to "tools/options/staroffice/paths" select ".Click on "my documents" path and in "edit".

I hope that help.

Regards.

jose at 2007-7-5 2:52:49 > top of Java-index,StarOffice,StarSuite...
# 2

Hi Jose,

Your suggestion allows a change for the path to save ALL of the various applications to a different folder. I want to save each application to its own separate folder. For example, I want to save all StarOffice word processing docs to c:\work\staroffice\wp. I want to save all spreadsheets to c:\work\staroffice\sheets. When I open or save something, I want the program to automatically open the proper folder.

It does not appear that Star Office can do this as it stands.... All the MS Office applications can, all the WordPerfect applications can, and all of the Lotus Smartsuite applications can. I am surprised that Star Office can't.....

janchadwell at 2007-7-5 2:52:49 > top of Java-index,StarOffice,StarSuite...
# 3
Hello: Investigating your question.I will let you know as soon as possible. Regards.
jose at 2007-7-5 2:52:49 > top of Java-index,StarOffice,StarSuite...
# 4
Thanks Jose. I like the look and feel of the application modules. If I can find a work-around or way to have the separate folders like I am used to having, I will be off and running with StarOffice. Jan
janchadwell at 2007-7-5 2:52:49 > top of Java-index,StarOffice,StarSuite...
# 5

Hi there :)

In StarOffice[TM] it is possible to modify the default directory for saving/loading documents.

To change the default directory:

1. Select "Tools - Options - StarOffice - Paths".

2. In the "Default" selection field, choose the "My Documents" entry (click to highlight), then press [Edit].

3. The "Select Path" dialog will appear. Here, it is possible to assign and/or modify the path to the directory.

4. After assigning the path in the Path field, click "Select" to add this entry to the Default Path dialog. Click [OK] to confirm and apply the new default setting.

Now, when saving documents, the file will be placed in the new default directory.

If different folders should exist for each of the StarOffice program modules, for example, it is possible to create single sub-folders within the default directory.

After creating the sub-folders ("File - Save - "Create New Directory" icon"), the sub-folders will appear in the Save dialog field. Now, it is only necessary to choose one sub-folder. For example, double-click the "Writer" sub-folder to assign the file and save it here. This is only one extra step to save the document in its own module's folder.

Otherwise, it is currently not possible to automatically detect and open the associated module folder when opening or saving a particular file in StarOffice[TM].

This information has been forwarded to our Development team as feature enhancement request. It is not yet possible to determine if or when this feature can be implemented in a future version of StarOffice[TM].

ying at 2007-7-5 2:52:49 > top of Java-index,StarOffice,StarSuite...
# 6

Hi Jan,

As indicated what you want isn't built into SO but the following macro can accomplish it. You would need to save this to the main Standard library then install it on the Function bar and assign it an icon. It will also work in lieu of Save As.

A copy of the macro is also in the attached file. If you want to try it and need further help just ask.

<pre>Sub Main

GlobalScope.BasicLibraries.LoadLibrary("Tools")

oDoc = thisComponent

If (oDoc.SupportsService("com.sun.star.presentation.PresentationDocument" ;)) then

DocT = "spres"

ElseIf (oDoc.SupportsService("com.sun.star.text.WebDocument")) then

DocT = "shtml"

Else

DocT = GetDocumentType(oDoc) 'a built in routine at Tools - Misc

EndIf

Select Case DocT

Case "swriter" : DocPath = "C:\docs\Writer\" : ext = ".sxw"

Case "sdraw" : DocPath = "C:\docs\Draw\" : ext = ".sxd"

Case "scalc" : DocPath = "C:\docs\Calc\" : ext = ".sxc"

Case "smath" : DocPath = "C:\docs\Math\" : ext = ".sxm"

Case "spres" : DocPath = "C:\docs\Presentation\" : ext = ".sxi"

Case "shtml" : DocPath = "C:\docs\Html\" : ext = ".html"

Case Else : DocPath = "C:\docs\" : ext = ""

End Select

GetFileName:

a$ = "Add your file name below. An extension is optional and will be honored, " & Chr(13)

b$ = "otherwise an appropriatee extension will be added." & Chr(13)

c$ = "You may also modify the path, if you like."

DocPath = InputBox(a$ & b$ & c$,"Save as",DocPath)

If (DocPath = "") then End

If (Instr(DocPath, ".") = 0) then DocPath = DocPath + ext

If (FileExists(DocPath)) then

iAns = MsgBox ("The file '" & DocPath & "' already exists. OVERWRITE?",3,"Existing File")

If (iAns = 2) then End

If (iAns <> 6) then GoTo GetFileName

EndIf

oDoc.StoreAsURL(ConvertToURL(DocPath), Array())

End Sub</pre>

JohnV at 2007-7-5 2:52:50 > top of Java-index,StarOffice,StarSuite...
# 7
Thank you Ying Zou. I appreciate the consideration. This would make SO have the "feel" most of us have come to expect from "office suite" products. Jan
janchadwell at 2007-7-5 2:52:50 > top of Java-index,StarOffice,StarSuite...
# 8
Hi John, Thanks for the input. I will give it a try.... Jan
janchadwell at 2007-7-5 2:52:50 > top of Java-index,StarOffice,StarSuite...
# 9

Hi, John,

I'll echo Jan's interest in seeing application-specific Save As defaults incorporated in Star Office one of these days. I, too, tend to organize documents of different types in different directories, rather than using a MyDocuments catchall.

I appreciate the macro you included, and I downloaded it. I'm a little confused about how to use it, though. The adel.sxw file isn't editable, so I copied the text from your posting, edited the save-as paths to match mine, then saved the file to the clipboard. I then opened the Tools,Macro,RecordMacro menu and pasted the clipboard.

I then saved it in the MyMacros,Standard directory as savas . In the next panel, I associated the macro with the File, Save Document As command. The File,Save As dialogue, however, remains the same - all document types default to the same directory as before.

Obviously, I'm bungling something - could you illuminate a dunce, please?

Thanks,

Starkey

[quote title=JohnV wrote on Wed, 04 February 2004 22:36]Hi Jan,

As indicated what you want isn't built into SO but the following macro can accoplish it. You would need to save this to the main Standard library then install it on the Function bar and assign it an icon. It will also work in lieu of Save As.

A copy of the macro is also in the attached file. If you want to try it and need further help just ask.

Starkey at 2007-7-5 2:52:50 > top of Java-index,StarOffice,StarSuite...
# 10

Starkey,

Please understand that the posted macro is out of date because it deals with file extension for SO7 and not the new default extensions for SO8 and I don't have time at the moment to rewrite it but I may in the near future. It appears to have been downloaded quite a bit so perhaps folks are using it.

As to how to handle a macro that you copy and paste see this link:

<a href="http&#58;&#47;&#47;www.oooforum.org/forum/viewtopic.phtml?t=7 995" target="_blank">http://www.oooforum.org/forum/viewtopic.phtml?t=7995</a&g t;

However looking at your post you may have done about the same thing in a strange way.

Give me a day or so and I'll have another look at this.

JohnV at 2007-7-5 2:52:50 > top of Java-index,StarOffice,StarSuite...
# 11

Here is an updated version of a macro to save files to a different directory for each application. Unfortunately, I can not make it work for new Base files.

I attached the macro to the Create Document event and found that in OOo2.0.0 (SO8 unpatched) it throws an error if a new Presentation is opened. In OOo2.0.1 (SO8 1st patch) the Presentation error goes away but it sometimes, and seemingly randomly, throws another error but this is a known bug.

You may find attaching the macro to the Create Document event overkill (I did) and want to create a tool bar icon or key combo for it. Either way remember that once you run the macro on a new file you don't need to use it again on that file because it is already saved where you want it.

A file containing the macro is attached.

JohnV at 2007-7-5 2:52:50 > top of Java-index,StarOffice,StarSuite...