Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a scheduled task that runs on my user machines at startup that currently brings up a 'configuring your station' style message in a command prompt window that is replaced by a vbscript msgbox saying that it has completed when it's finished.

I'd like to replace the command window with a small image that is displayed in a window that can't be closed or is displayed floating on the desktop with no frames. The image will have the company logo and the message. Once the task has completed, I'd like it to remove the image when the completed msgbox appears.

When I picture this in my head, it reminds me of the clan screens you get when you load into a Counter Strike Source server.

This is what I have so far:

This brings the splash screen up but you have to Alt+F4 to remove it. Here's the thread I found with this code: Need a VBScript for Open a local Image File by using Command prompt

I don't know how to get it to be closed once the scheduled task completes.
With my current knowledge I'm going to be using autoit to do this. There's probably a better way, though.

<html>
<hta:application id="oHTA"
    border="none"
    caption="no"
    contextmenu="no"
    innerborder="no"
    scroll="no"
    showintaskbar="no"
/>
<script language="VBScript">
    Sub Window_OnLoad
        ' Resize and position the window
        width = 575 : height = 390
        window.resizeTo width, height
        window.moveTo screen.availWidth\2 - width\2, screen.availHeight\2 - height\2

    End Sub
</script>
<body>
<table border=0 width="100%" height="100%">
    <tr>
        <td align="center" valign="middle">
            <img src="image.bmp"/>
        </td>
    </tr>
</table>
</body>
</html>
share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

Build a VB script with a custom form and no buttons, then just call it where you would display the command window.

share|improve this answer
    
You would want to set BorderStyle or an attribute with a similar name (I can't remember for sure) to None. –  jcrawfordor Jun 14 '11 at 17:18
    
Yes, you can modify the custom form in such a way as to look like a "splash screen" or to make it appear flat, or consist entirely of a custom image. There is decent flexibility in what you are allowed to do with this. –  music2myear Jun 14 '11 at 18:53
    
I added what I've done based on this answer, but I'm not 100% there yet. –  Tyler Faile Jun 14 '11 at 20:14
    
Nevermind! I'm satisfied with what I was able to do using autoit. I was able to close the window at the appropriate time in my script. Thanks! –  Tyler Faile Jun 14 '11 at 20:21
    
Glad to be of assistance. –  music2myear Jun 14 '11 at 20:37
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.