Так проблема решена? Вон, накидал библиотеку на ФБ, 8 килобайт. Исходники библиотеки и тестовый проект внутри архива:
http://filebeam.com/a20d70f76f1fd44d7aeb212c9e6ce828
Использовать так:
-
- Option Explicit
-
- Private Declare Function Init Lib "calendar.dll" (ByVal hWnd As Long, ByVal x_pos As Integer, ByVal y_pos As Integer, ByVal wnd_width As Integer, ByVal wnd_height As Integer, ByVal call_back As Long, ByVal wnd_proc As Long) As Long
- Private Declare Function GetCurrentSelectYear Lib "calendar.dll" () As Long
- Private Declare Function GetCurrentSelectMonth Lib "calendar.dll" () As Long
- Private Declare Function GetCurrentSelectDay Lib "calendar.dll" () As Long
-
- Dim res As Long
-
- Private Sub Command1_Click()
-
- Dim cur_year As Long
- Dim cur_month As Long
- Dim cur_day As Long
-
- cur_year = GetCurrentSelectYear()
- cur_month = GetCurrentSelectMonth()
- cur_day = GetCurrentSelectDay()
-
- MsgBox "Пользователь выбрал " & Str(cur_year) & " год, " & Str(cur_month) & " месяц, " & Str(cur_day) & " день."
-
- End Sub
-
- Private Sub Form_Load()
-
- res = Init(Me.hWnd, 10, 10, 190, 165, 0, 0)
-
- End Sub
Очень простая библиотека, нельзя устанавливать программно дату и прочее.
Ответить
|