Cvp: Access Dosya Güncelleme İnternetten - userx - 04/03/2020
Sayın feraz
https://www.dropbox.com/s/lznm3dke1uy9ljn/metinVersiyon.txt
şeklinde dener misin?
Yok denedim olmuyor. Kusura bakma.
Cvp: Access Dosya Güncelleme İnternetten - feraz - 04/03/2020
(04/03/2020, 22:09)userx yazdı: Sayın feraz
https://www.dropbox.com/s/lznm3dke1uy9ljn/metinVersiyon.txt
şeklinde dener misin?
Yok denedim olmuyor. Kusura bakma.  
Ozan hocamız heralde halleder
Cvp: Access Dosya Güncelleme İnternetten - ozanakkaya - 05/03/2020
VersiyonNedir kodunu aşağıdaki ile değiştirerek dene.
Public Sub VersiyonNedir()
Dim versiyon_adresi As String
Dim IEb As Object
Dim temp As String
Dim sim_major_vers, sim_midi_vers, sim_minor_vers, gun_major_vers, gun_midi_vers, gun_minor_vers As Byte
If Len(Dir(CurrentProject.Path & "\guncelle.mdb")) > 0 Then
Kill CurrentProject.Path & "\guncelle.mdb"
End If
versiyon_adresi = "https://www.dropbox.com/s/lznm3dke1uy9ljn/metinVersiyon.txt"
Set IEb = CreateObject("InternetExplorer.Application")
IEb.Visible = True
With IEb
.Navigate versiyon_adresi
Do Until IEb.ReadyState = 4
DoEvents
Loop
For Each opt In IEb.Document.getElementsbyTagName("iframe")
If opt.classname = "previewhtml" Then
temp = opt.src
End If
Next
.Navigate temp
Do Until IEb.ReadyState = 4
DoEvents
Loop
For Each opt In IEb.Document.getElementsbyTagName("div")
temp = opt.innertext
Next
End With
lbl_guncel_versiyon.Caption = Mid$(temp, InStr(temp, ":") + 1, 6)
lbl_programin_versiyonu.Caption = Nz(DLookup("program_versiyonu", "tbl_program_ayarlari"), "0.0.00")
IEb.Quit
Set IEb = Nothing
sim_major_vers = Mid$(lbl_programin_versiyonu.Caption, 1, 1)
sim_midi_vers = Mid$(lbl_programin_versiyonu.Caption, 3, 1)
sim_minor_vers = Mid$(lbl_programin_versiyonu.Caption, 5, 2)
gun_major_vers = Mid$(lbl_guncel_versiyon.Caption, 1, 1)
gun_midi_vers = Mid$(lbl_guncel_versiyon.Caption, 3, 1)
gun_minor_vers = Mid$(lbl_guncel_versiyon.Caption, 5, 2)
If gun_major_vers > sim_major_vers Then
lbl_guncel_versiyon.ForeColor = RGB(255, 0, 0)
If MsgBox("A Kullandığınız programdan daha yeni bir versiyon bulunmaktadır." & vbCrLf & vbCrLf & "Yeni versiyonu indirmek istiyor musunuz?", vbExclamation + vbYesNo, "Yeni Sürüm Mevcut") = vbYes Then
URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncel_yakit_hesapla.mdb", CurrentProject.Path & "\guncel_yakıt_hesapla.mdb", 0, 0
URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncelle.mdb", CurrentProject.Path & "\guncelle.mdb", 0, 0
End If
ElseIf gun_midi_vers > sim_midi_vers Then
lbl_guncel_versiyon.ForeColor = RGB(255, 0, 0)
If MsgBox("B Kullandığınız programdan daha yeni bir versiyon bulunmaktadır." & vbCrLf & vbCrLf & "Yeni versiyonu indirmek istiyor musunuz?", vbExclamation + vbYesNo, "Yeni Sürüm Mevcut") = vbYes Then
URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncel_yakit_hesapla.mdb", CurrentProject.Path & "\guncel_yakıt_hesapla.mdb", 0, 0
URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncelle.mdb", CurrentProject.Path & "\guncelle.mdb", 0, 0
End If
ElseIf gun_minor_vers > sim_minor_vers Then
lbl_guncel_versiyon.ForeColor = RGB(255, 0, 0)
If MsgBox("C Kullandığınız programdan daha yeni bir versiyon bulunmaktadır." & vbCrLf & vbCrLf & "Yeni versiyonu indirmek istiyor musunuz?", vbExclamation + vbYesNo, "Yeni Sürüm Mevcut") = vbYes Then
URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncel_yakit_hesapla.mdb", CurrentProject.Path & "\guncel_yakıt_hesapla.mdb", 0, 0
URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncelle.mdb", CurrentProject.Path & "\guncelle.mdb", 0, 0
Dim accapp As Access.Application
Set accapp = New Access.Application
accapp.OpenCurrentDatabase CurrentProject.Path & "\guncelle.mdb"
Application.Quit
End If
Else
'MsgBox "Şu anda en son güncel versiyonu kullanıyorsunuz", vbInformation + vbOKOnly, ProgramAdi
lbl_guncel_versiyon.ForeColor = RGB(0, 0, 0)
End If
End Sub
Cvp: Access Dosya Güncelleme İnternetten - feraz - 05/03/2020
Ozan hocam elinize sağlık.
Kendim denemek için Test Guncelleme icin adında bir Access dosya ekledim DropBoxa.
Versiyon kontrol
Kod:
versiyon_adresi = "https://www.dropbox.com/s/lznm3dke1uy9ljn/metinVersiyon.txt"
bununla oluyor eklediğiniz kod ile.
Linkte altta.Acaba alttaki linkteki dosyayı güncelletebilirmiz?
Birde 64bit içinde yaparsanız seviniriz kodları.
Ben başaramadım ne yaptıysam.
https://www.dropbox.com/s/erziurvake051l1/Test%20Guncelleme%20icin.accdb?dl=0
Cvp: Access Dosya Güncelleme İnternetten - userx - 05/03/2020
Sayın feraz Test Guncelleme icin.accdb dosyanızı indirmek için;
URLDownloadToFile 0, "https://uc2eb9ff966c36d9a419a7dfbe76.dl.dropboxusercontent.com/cd/0/get/AzUNf0fWSLtyJuIAiW9QFSSkZwi64hpS6eTCDREF3jMJVvq8BMhQGRS-_zoIyx5x-p7NnfjDb66C13T93whsHE85_njZUWZZ9hY9EymJGr4_1Vd9A5GJCArhF8Sn8GLMplo/file?_download_id=99774241659988298606606306418383629577697291764419205526091347913&_notify_domain=www.dropbox.com&dl=1", CurrentProject.Path & "\guncel_yakıt_hesapla.mdb", 0, 0
yazarak dener misiniz?
Cvp: Access Dosya Güncelleme İnternetten - feraz - 05/03/2020
(05/03/2020, 20:07)userx yazdı: Sayın feraz Test Guncelleme icin.accdb dosyanızı indirmek için;
URLDownloadToFile 0, "https://uc2eb9ff966c36d9a419a7dfbe76.dl.dropboxusercontent.com/cd/0/get/AzUNf0fWSLtyJuIAiW9QFSSkZwi64hpS6eTCDREF3jMJVvq8BMhQGRS-_zoIyx5x-p7NnfjDb66C13T93whsHE85_njZUWZZ9hY9EymJGr4_1Vd9A5GJCArhF8Sn8GLMplo/file?_download_id=99774241659988298606606306418383629577697291764419205526091347913&_notify_domain=www.dropbox.com&dl=1", CurrentProject.Path & "\guncel_yakıt_hesapla.mdb", 0, 0
yazarak dener misiniz?
gun_minor_vers = Mid$(lbl_guncel_versiyon.Caption, 5, 2) alttaki gibi kodu ekledim ve yyandaki hata veriyor neden anlamadım.
Hata Dropboxtaki versiyonu bulamıyor anladığım.
Sağolun.
Kod:
Public Sub VersiyonNedir()
Dim versiyon_adresi As String
Dim IEb As Object
Dim temp As String
Dim sim_major_vers, sim_midi_vers, sim_minor_vers, gun_major_vers, gun_midi_vers, gun_minor_vers As Byte
If Len(Dir(CurrentProject.Path & "\guncelle.mdb")) > 0 Then
Kill CurrentProject.Path & "\guncelle.mdb"
End If
versiyon_adresi = "https://www.dropbox.com/s/lznm3dke1uy9ljn/metinVersiyon.txt"
Set IEb = CreateObject("InternetExplorer.Application")
IEb.Visible = True
With IEb
.Navigate versiyon_adresi
Do Until IEb.ReadyState = 4
DoEvents
Loop
For Each opt In IEb.Document.getElementsbyTagName("iframe")
If opt.classname = "previewhtml" Then
temp = opt.src
End If
Next
.Navigate temp
Do Until IEb.ReadyState = 4
DoEvents
Loop
For Each opt In IEb.Document.getElementsbyTagName("div")
temp = opt.innertext
Next
End With
lbl_guncel_versiyon.Caption = Mid$(temp, InStr(temp, ":") + 1, 6)
lbl_programin_versiyonu.Caption = Nz(DLookup("program_versiyonu", "tbl_program_ayarlari"), "0.0.00")
IEb.Quit
Set IEb = Nothing
sim_major_vers = Mid$(lbl_programin_versiyonu.Caption, 1, 1)
sim_midi_vers = Mid$(lbl_programin_versiyonu.Caption, 3, 1)
sim_minor_vers = Mid$(lbl_programin_versiyonu.Caption, 5, 2)
gun_major_vers = Mid$(lbl_guncel_versiyon.Caption, 1, 1)
gun_midi_vers = Mid$(lbl_guncel_versiyon.Caption, 3, 1)
gun_minor_vers = Mid$(lbl_guncel_versiyon.Caption, 5, 2)
If gun_major_vers > sim_major_vers Then
lbl_guncel_versiyon.ForeColor = RGB(255, 0, 0)
If MsgBox("A Kullandýðýnýz programdan daha yeni bir versiyon bulunmaktadýr." & vbCrLf & vbCrLf & "Yeni versiyonu indirmek istiyor musunuz?", vbExclamation + vbYesNo, "Yeni Sürüm Mevcut") = vbYes Then
URLDownloadToFile 0, "https://uc2eb9ff966c36d9a419a7dfbe76.dl.dropboxusercontent.com/cd/0/get/AzUNf0fWSLtyJuIAiW9QFSSkZwi64hpS6eTCDREF3jMJVvq8BMhQGRS-_zoIyx5x-p7NnfjDb66C13T93whsHE85_njZUWZZ9hY9EymJGr4_1Vd9A5GJCArhF8Sn8GLMplo/file?_download_id=99774241659988298606606306418383629577697291764419205526091347913&_notify_domain=www.dropbox.com&dl=1", CurrentProject.Path & "\guncel_yakýt_hesapla.mdb", 0, 0
' URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncel_yakit_hesapla.mdb", CurrentProject.Path & "\guncel_yakýt_hesapla.mdb", 0, 0
' URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncelle.mdb", CurrentProject.Path & "\guncelle.mdb", 0, 0
End If
ElseIf gun_midi_vers > sim_midi_vers Then
lbl_guncel_versiyon.ForeColor = RGB(255, 0, 0)
If MsgBox("B Kullandýðýnýz programdan daha yeni bir versiyon bulunmaktadýr." & vbCrLf & vbCrLf & "Yeni versiyonu indirmek istiyor musunuz?", vbExclamation + vbYesNo, "Yeni Sürüm Mevcut") = vbYes Then
URLDownloadToFile 0, "https://uc2eb9ff966c36d9a419a7dfbe76.dl.dropboxusercontent.com/cd/0/get/AzUNf0fWSLtyJuIAiW9QFSSkZwi64hpS6eTCDREF3jMJVvq8BMhQGRS-_zoIyx5x-p7NnfjDb66C13T93whsHE85_njZUWZZ9hY9EymJGr4_1Vd9A5GJCArhF8Sn8GLMplo/file?_download_id=99774241659988298606606306418383629577697291764419205526091347913&_notify_domain=www.dropbox.com&dl=1", CurrentProject.Path & "\guncel_yakýt_hesapla.mdb", 0, 0
' URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncel_yakit_hesapla.mdb", CurrentProject.Path & "\guncel_yakýt_hesapla.mdb", 0, 0
' URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncelle.mdb", CurrentProject.Path & "\guncelle.mdb", 0, 0
End If
ElseIf gun_minor_vers > sim_minor_vers Then
lbl_guncel_versiyon.ForeColor = RGB(255, 0, 0)
If MsgBox("C Kullandýðýnýz programdan daha yeni bir versiyon bulunmaktadýr." & vbCrLf & vbCrLf & "Yeni versiyonu indirmek istiyor musunuz?", vbExclamation + vbYesNo, "Yeni Sürüm Mevcut") = vbYes Then
URLDownloadToFile 0, "https://uc2eb9ff966c36d9a419a7dfbe76.dl.dropboxusercontent.com/cd/0/get/AzUNf0fWSLtyJuIAiW9QFSSkZwi64hpS6eTCDREF3jMJVvq8BMhQGRS-_zoIyx5x-p7NnfjDb66C13T93whsHE85_njZUWZZ9hY9EymJGr4_1Vd9A5GJCArhF8Sn8GLMplo/file?_download_id=99774241659988298606606306418383629577697291764419205526091347913&_notify_domain=www.dropbox.com&dl=1", CurrentProject.Path & "\guncel_yakýt_hesapla.mdb", 0, 0
' URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncel_yakit_hesapla.mdb", CurrentProject.Path & "\guncel_yakýt_hesapla.mdb", 0, 0
' URLDownloadToFile 0, "https://accesstr.net/sitegenel/guncelleme/guncelle.mdb", CurrentProject.Path & "\guncelle.mdb", 0, 0
Dim accapp As Access.Application
Set accapp = New Access.Application
accapp.OpenCurrentDatabase CurrentProject.Path & "\guncelle.mdb"
Application.Quit
End If
Else
'MsgBox "Þu anda en son güncel versiyonu kullanýyorsunuz", vbInformation + vbOKOnly, ProgramAdi
lbl_guncel_versiyon.ForeColor = RGB(0, 0, 0)
End If
End Sub
|