Results 1 to 16 of 16

Thread: ** SORTED ** Autorun

  1. #1

    Thread Starter
    Hyperactive Member parkes's Avatar
    Join Date
    Jan 1999
    Location
    Unitied Kingdom
    Posts
    303

    ** SORTED ** Autorun

    I'm putting a few simple webpages on a CD thats going to a customer. I was wondering if its possible to make the CD autorun

    I've created the autorun file, but doesn't seem to work, get an error message about not being able to access the file.

    File content:-

    [autorun]
    open=index.htm

    Doesn't work.

    Help!
    Last edited by parkes; Jun 7th, 2002 at 02:51 AM.
    Thanks in advance for any help provided.

    VB 6 Enterprise Edition SP4
    ADO, SQL 7/2000, ASP and some JavaScript


    >> Life goes on, but for how long? <<
    If you can smile when things go wrong, you have someone in mind to blame

  2. #2

    Thread Starter
    Hyperactive Member parkes's Avatar
    Join Date
    Jan 1999
    Location
    Unitied Kingdom
    Posts
    303
    Sorry about the 3 postings, my PC went mental for a few seconds and kept refreshing the screen.
    Thanks in advance for any help provided.

    VB 6 Enterprise Edition SP4
    ADO, SQL 7/2000, ASP and some JavaScript


    >> Life goes on, but for how long? <<
    If you can smile when things go wrong, you have someone in mind to blame

  3. #3
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444
    I found that if I burnt the CD in multisession mode it gave me some error about not being a valid Win32 application. I decided to use a proper auto play program rather than just web pages in the end, they work a lot better and are more flexible.

  4. #4
    Banished Cander's Avatar
    Join Date
    Dec 2000
    Location
    Why do you care?
    Posts
    6,913
    the only way i see is to write an exe that shellexecutes the html file then autorun the exe
    Stack Overflow
    See the features of Visual Studio 2010 and C# 4.0: The 10-4 show on Channel9

  5. #5
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444
    Actually you saying that reminded me that there is another way of writing an autorun file. YOu can use something like shellexecute=index.htm but I don't think that's quite it. The user needs IE5+ installed. There's something about it in the MS knowledge base somewhere.

  6. #6
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    Expanding on Cander's idea, write a .exe (in C, not VB), that calls the ShellExecute API on the first argument. Then use that in the autorun:

    open=shellex.exe page.html
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  7. #7
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    Check MSDN for the right syntax - I think you might need quoting to pass the argument in.
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  8. #8
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444
    If you haven't got C++ go to http://kickme.to/FOSI/ and download AutoPlay Menu Studio Pro 3.0, it's pretty easy to use.

  9. #9
    Banished Cander's Avatar
    Join Date
    Dec 2000
    Location
    Why do you care?
    Posts
    6,913
    another idea...see if autorun will run a .vbs vbscript file which can shell out to ie ...

    worth a try..
    Stack Overflow
    See the features of Visual Studio 2010 and C# 4.0: The 10-4 show on Channel9

  10. #10
    Hyperactive Member progressive's Avatar
    Join Date
    Sep 2001
    Location
    Manchester, UK
    Posts
    404
    A simple solution that I have used.
    That requires no programming knowledge.

    In your autorun file put
    Code:
    [AUTORUN]
    open=setup.bat
    Then create a .bat file(setup.bat used in this example) and put

    Code:
    start index.html
    exit
    A .bat file is simply command line instructions for DOS and doesn't require compiling runtime dll's or any other dependent files.

    This is a neat little method that I have used. Sometimes a dos window is left open but you can live with that

  11. #11
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    Originally posted by Cander
    another idea...see if autorun will run a .vbs vbscript file which can shell out to ie ...

    worth a try..
    Hmm, due to stupid virus writers I bet a lot of people are running stuff (I think Norton Antivirus, etc) that would interfere with getting this to smoothly work.
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  12. #12
    Hyperactive Member progressive's Avatar
    Join Date
    Sep 2001
    Location
    Manchester, UK
    Posts
    404
    The vbs solution shouldn't be a problem,

    Virus software works by scanning files on a users system looking for a virus’s signature, a unique string of bytes that identifies the virus like a fingerprint. Then takes the necessary action to rid (disinfect) the system of the Virus.

  13. #13
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    No, Norton AV includes a Script Blocker component that intercepts attempts to run scripts. Lots of people have also set *.vbs files to open with notepad instead of wsh, too, after all the viruses.
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  14. #14
    Hyperactive Member progressive's Avatar
    Join Date
    Sep 2001
    Location
    Manchester, UK
    Posts
    404
    In that case then...this would cause problems.

    The *.bat solution I posted has worked reliably for me in the past.

    How have you got on Parkes ??

  15. #15
    Hyperactive Member progressive's Avatar
    Join Date
    Sep 2001
    Location
    Manchester, UK
    Posts
    404
    In that case then...this would cause problems.

    The *.bat solution I posted has worked reliably for me in the past.

    How have you got on Parkes ??

  16. #16

    Thread Starter
    Hyperactive Member parkes's Avatar
    Join Date
    Jan 1999
    Location
    Unitied Kingdom
    Posts
    303
    Sorry should have replied sooner, thanks progressive that .bat file works fine.
    Thanks in advance for any help provided.

    VB 6 Enterprise Edition SP4
    ADO, SQL 7/2000, ASP and some JavaScript


    >> Life goes on, but for how long? <<
    If you can smile when things go wrong, you have someone in mind to blame

Posting Permissions

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



Click Here to Expand Forum to Full Width