devxlogo

Check whether RAS is installed

Check whether RAS is installed

When you work with RAS APIs, you should have to make sure if RAS library is installed on the system. A simple way is to verify the existence of the Rasapi32.dll file in the windows system directory; the same thing can be obtained with a call to the InternetGetConnectedState API, as the following code demonstrates:

Private Declare Function InternetGetConnectedState Lib "wininet.dll" (ByRef _    lpdwFalgs As Long, ByVal dwReserved As Long) As BooleanConst INTERNET_RAS_INSTALLED = 16' Check whether RAS is installedFunction IsRASInstalled() As Boolean    Dim connStatus As Long    InternetGetConnectedState connStatus, 0&    IsRASInstalled = (connStatus And INTERNET_RAS_INSTALLED)End Function

See also  Monetize TikTok For Your Business
devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist