+ Post New Thread
Results 1 to 4 of 4
Educational Software Thread, Stellarium in Technical; Hi everyone, For our astrophysics course a teacher has requested the installation of Stellarium [1]. This in itself is not ...
  1. #1
    jonathanhaddock's Avatar
    Join Date
    Dec 2007
    Location
    Barton Court Grammar, Canterbury
    Posts
    58
    Thank Post
    0
    Thanked 6 Times in 4 Posts
    Rep Power
    15

    Stellarium

    Hi everyone,

    For our astrophysics course a teacher has requested the installation of Stellarium [1]. This in itself is not a problem but it appears the software doesn't automatically create its user directory unless the user is an administrator - clearly no good for students.

    Has anyone had the same problem, and solved it (short of manually creating the user directories for each user)?

    We're using Windows Server 2003 to store the students' home areas and Windows XP Pro as the client operating system.

    [1] Stellarium.org

    Thanks in advance,
    Jonathan Haddock
    Network Manager (and Webmaster)
    Barton Court Grammar School

  2. #2

    plexer's Avatar
    Join Date
    Dec 2005
    Location
    Norfolk
    Posts
    13,343
    Thank Post
    624
    Thanked 1,584 Times in 1,421 Posts
    Rep Power
    414
    Just run a login script:

    if not exist h:\stellararium mkdir h:\stellararium

    Or something?

    Ben

  3. #3
    jonathanhaddock's Avatar
    Join Date
    Dec 2007
    Location
    Barton Court Grammar, Canterbury
    Posts
    58
    Thank Post
    0
    Thanked 6 Times in 4 Posts
    Rep Power
    15

    Arrow !!SOLVED (With code)!!

    Hi Plexer,

    Thanks for your response - I hadn't considered a logon script (which is unusual for me) and that is indeed the solution I'm going with.

    On my network at least, although I think it's the general ruling, you cannot give a .bat or .cmd as a logon script - it has to be something that uses the WSHost (VB Script for example) so I've found a script that does the same here [2].

    I've pasted my code below, slightly modified over the original link. Hope this is useful to someone else!

    Code:
    Public objFSO
    
    Sub Main()
    Set objFSO = CreateObject("Scripting.FileSystemObject")
    Call
    GeneratePath("H:\StellariumUserData")
    End Sub
    
    ' ---------------------------------------------------------------------
    '* @info Generate a folder tree from the path
    '*
    '* @param (String) Path
    '* @return (Boolean) Folder Exists: Recursion continues (Y/N)
    ' ---------------------------------------------------------------------
    Function GeneratePath(pFolderPath)
    GeneratePath = False
    If Not objFSO.FolderExists(pFolderPath) Then
    If GeneratePath(objFSO.GetParentFolderName(pFolderPath)) Then
    GeneratePath = True
    Call objFSO.CreateFolder(pFolderPath)
    End If
    Else
    GeneratePath = True
    End If
    End Function
    
    Call Main
    You also need to ensure you adjust the parameters passed to Stellarium via its shortcut to include the user directory, see the Stellarium User Manual[2]. Example below:

    "C:\Program Files\Stellarium\stellarium.exe" -u "%HOMESHARE%\StellariumUserData"
    [1]Create folder in vbscript
    [2]Stellarium User Guide

  4. #4

    RabbieBurns's Avatar
    Join Date
    Apr 2008
    Location
    Sydney
    Posts
    5,512
    Thank Post
    1,320
    Thanked 469 Times in 306 Posts
    Blog Entries
    6
    Rep Power
    199
    Quote Originally Posted by jonathanhaddock View Post
    uling, you cannot give a .bat or .cmd as a logon script - it has to be something that uses the WSHost (VB Script for example)
    all our login scripts are .bat files

SHARE:
+ Post New Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •