الفريق العربي للبرمجةأرشيف المنتديات · 2000 – 2023
نسخة أرشيفية للقراءة فقط — التسجيل والمشاركة مغلقان، والمحتوى محفوظ كما كان.

دخول الانترنت من خلال برنامج C#

مغلق
بدأه prog_heba في 1 فبراير 2005 · 2 رد · 677 مشاهدة · في Microsoft Visual C#.NET
مشاركة: واتساب X فيسبوك تيليجرام
#1 صاحب الموضوع

السلام عليكم

دي اول مشاركة ليا في هذا المنتدي ,,,,,,, و اتمني من الله دوام توفيق هذا المنتدي

انا عايزة اعمل برنامج يسمح للمستخدم الدخول علي الانترنت

بمعني اني عايزة اعمل Dial-up في البرنامج الخاص بي

جزاكم الله خيرا

Heba Emara

Software Developer

www.eurwork.com

#2

http://www.codeproject.com/aspnet/webdialup.asp

او ممكن من ال Api

الدالة->RasDial Lib

من الملف "rasapi32.dll"

using System.Runtime.InteropServices;

[StructLayout(LayoutKind.Sequential, Pack=4, CharSet=CharSet.Auto)]
struct RASDIALPARAMS
{
public int dwSize;
[MarshalAs( UnmanagedType.ByValTStr, SizeConst=257)]
public string szEntryName;
[MarshalAs( UnmanagedType.ByValTStr, SizeConst=129)]
public string szPhoneNumber;
[MarshalAs( UnmanagedType.ByValTStr, SizeConst=129)]
public string szCallbackNumber;
[MarshalAs( UnmanagedType.ByValTStr, SizeConst=257)]
public string szUserName;
[MarshalAs( UnmanagedType.ByValTStr, SizeConst=257)]
public string szPassword;
[MarshalAs( UnmanagedType.ByValTStr, SizeConst=16)]
public string szDomain;
}

[DllImport("rasapi32.dll", CharSet=CharSet.Auto) ]
public static extern int RasDial( IntPtr dummy, string lpszPhonebook,
ref RASDIALPARAMS lpRasDialParams, int dwNotifierType,
IntPtr lpvNotifier, ref IntPtr lphRasConn );

RASDIALPARAMS par;
par.dwSize = Marshal.SizeOf(typeof(RASDIALPARAMS));
par.szEntryName = "";
par.szPhoneNumber = "123";
par.szCallbackNumber = "";
par.szUserName = "";
par.szPassword = "";
par.szDomain = "";
IntPtr rashand = IntPtr.Zero;
IntPtr hwnd = IntPtr.Zero;
int rc = RasDial( IntPtr.Zero, null,
ref par, -1, hwnd, ref rashand );

ahabdeen.jpg

<marquee>

مش موجود بصفة دايمة للامتحانات

</marquee>

#3

السلام عليكم

مشكورر اخي الفاضل

رغم ان صاحب المشكلة لم يرد عليك ؟؟؟؟

ولكم مني تحية

هذا الموضوع مغلق.

مواضيع مشابهة