Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 264133
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T22:39:36+00:00 2026-05-11T22:39:36+00:00

I have a batch file that will detect if the user has the .Net

  • 0

I have a batch file that will detect if the user has the .Net framework installed by going to the directory and checking if the CONFIG directory exists.

If the directory doesn’t exist then the user doesn’t have the .Net framework installed. The batch file will then continue on to install the .Net framework. However, there is a problem as the .Net frameworks need to be installed before running the setup to install my dialer. So I have put a PAUSE statement so the user will press any button to continue after the framework has been installed.

However, our client doesn’t like this as some of their customers don’t understand and they press a key before the framework has finished installing. This then causes the setup to fail as the framework haven’t been installed first.

I am using the PAUSE that will wait for the user input. However, is there a way that the batch will wait until the framework is finished automatically instead of using the PAUSE command?

Many thanks for any suggestions,

@ECHO OFF
REM Copy the configuration file
copy config.xml "%AppData%\DataLinks.xml"

REM Search for the CONFIG file, if this doesn't exit then the user doesn't have the .Net framework 2.0
SET FileName=%windir%\Microsoft.NET\Framework\v2.0.50727\CONFIG
IF EXIST %FileName% GOTO INSTALL_DIALER
ECHO.You currently do not have the Microsoft(c) .NET Framework 2.0 installed.
ECHO.This is required by the setup program for MyApplication.
ECHO.
ECHO.The Microsoft(c) .NET Framework 2.0 will now be installed on you system.
ECHO.After completion setup will continue to install MyApplication on your system.
ECHO.
REM Install the .Net framework and wait for the user to input before install the dialer 
PAUSE
ECHO Installing... Please wait...
SET FileName =
Start .\NetFx20SP2_x86.exe
ECHO Once the .Net Framework has completed. Press any key to continue to install the dialer.
PAUSE
Start .\setup.exe
ECHO ON
EXIT

REM .Net framework has been skipped contine to install the dialer.
:INSTALL_DIALER
ECHO *** Skiped Dotnet Framework 2.0.50727 ***
ECHO Installing... Please wait...
SET FileName=
Start .\setup.exe
ECHO ON
EXIT
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-11T22:39:36+00:00Added an answer on May 11, 2026 at 10:39 pm

    you can use

    START /WAIT NetFx20SP2_x86
    

    too.
    remember that

    REM comment
    

    is equal to

    ::comment
    

    and that using .\ is unnecessary, and file extensions are too, unless there are dirs/files with conflicting names.
    You also do not need cleaning the “filename” variable twice (the “=” pointing nothing twice) and

    ECHO.something
    

    is equal

    ECHO something
    

    only except for blank lines

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 129k
  • Answers 129k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer What I see: you pass an array (loginOutBuffer) to Socket.BeginSend()… May 12, 2026 at 5:50 am
  • Editorial Team
    Editorial Team added an answer I found that because the InfoPath form was created in… May 12, 2026 at 5:50 am
  • Editorial Team
    Editorial Team added an answer If you use an ObservableCollection of serializable objects implementing INotifyPropertyChanged,… May 12, 2026 at 5:50 am

Related Questions

I've got a windows batch file, with a few sub-routines in it something like
I have a process that needs to run under administrative privileges. I need the
I have a text file that contains a list of filenames, minus the extension,
I have a VB6 application that needs to update it's self. For this purpose,

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.