init lserp cs 5.0
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Zhaizj.Framework.Utils
|
||||
{
|
||||
public class WebState
|
||||
{
|
||||
[DllImport("wininet.dll")]
|
||||
private extern static bool InternetGetConnectedState(out int connectionDescription, int reservedValue);
|
||||
|
||||
public static bool IsInternetConnected()
|
||||
{
|
||||
int i = 0;
|
||||
bool state = InternetGetConnectedState(out i, 0);
|
||||
return state;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user