- Katılım
- 9 Aralık 2018
- Mesajlar
- 363
- Excel Vers. ve Dili
- Excel 2019 - 32 bit TR
DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
Altın Üyelik Hakkında Bilgi
If ThisWorkbook.Sheets("Kimlik").Range("B9").Value <> "" Then
Me.LBBclc.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B9").Value)
End If
Referanslar içerisinde bulunan MİSSİNG ile başlayan referansın tikini kaldırın deneyin.
Hikaye userfrmunun en altına aşağıdaki kodu deneyin.
Kod:If ThisWorkbook.Sheets("Kimlik").Range("B9").Value <> "" Then Me.LBBclc.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B9").Value) End If
Private Sub cmbTX1_Change()
Sheets("Kimlik").Range("B19") = cmbTX1.Value
End Sub
Private Sub cmbTX2_Change()
Sheets("Kimlik").Range("B20") = cmbTX2.Value
End Sub
Private Sub cmbTX3_Change()
Sheets("Kimlik").Range("B21") = cmbTX3.Value
End Sub
Private Sub cmbTX4_Change()
Sheets("Kimlik").Range("B22") = cmbTX4.Value
End Sub
Private Sub cmbTX5_Change()
Sheets("Kimlik").Range("B23") = cmbTX5.Value
End Sub
Private Sub cmbTX6_Change()
Sheets("Kimlik").Range("B28") = cmbTX6.Value
End Sub
Private Sub cmbTX7_Change()
Sheets("Kimlik").Range("B29") = cmbTX7.Value
End Sub
Private Sub cmbTX8_Change()
Sheets("Kimlik").Range("B30") = cmbTX8.Value
End Sub
Private Sub cmbTX9_Change()
Sheets("Kimlik").Range("B31") = cmbTX9.Value
End Sub
Private Sub cmbTX10_Change()
Sheets("Kimlik").Range("B32") = cmbTX10.Value
End Sub
Private Sub Kapat_Click()
Application.ScreenUpdating = True
Worksheets("Formlar").Select
Hide
End Sub
Private Sub LB4_Change()
'Etiyoloji girişi için gerekmektedir
Sheets("Kimlik").Range("I11") = LB4.Value
End Sub
Private Sub MultiPage1_Change()
End Sub
Private Sub tbHikaye_Change()
Sheets("Kimlik").Range("oyku") = tbHikaye.Value
End Sub
Private Sub tbPatoloji_Change()
Sheets("Kimlik").Range("Patoloji") = tbPatoloji.Value
End Sub
Private Sub tbTED1_Change()
Sheets("Kimlik").Range("D19") = tbTED1.Value
End Sub
Private Sub tbTED2_Change()
Sheets("Kimlik").Range("D20") = tbTED2.Value
End Sub
Private Sub tbTED3_Change()
Sheets("Kimlik").Range("D21") = tbTED3.Value
End Sub
Private Sub tbTED4_Change()
Sheets("Kimlik").Range("D22") = tbTED4.Value
End Sub
Private Sub tbTED5_Change()
Sheets("Kimlik").Range("D23") = tbTED5.Value
End Sub
Private Sub tbTED6_Change()
Sheets("Kimlik").Range("D28") = tbTED6.Value
End Sub
Private Sub tbTED7_Change()
Sheets("Kimlik").Range("D29") = tbTED7.Value
End Sub
Private Sub tbTED8_Change()
Sheets("Kimlik").Range("D30") = tbTED8.Value
End Sub
Private Sub tbTED9_Change()
Sheets("Kimlik").Range("D31") = tbTED9.Value
End Sub
Private Sub tbTED10_Change()
Sheets("Kimlik").Range("D32") = tbTED10.Value
End Sub
'BCLC için kodu ekledim
Private Sub LBBCLC_Change()
Sheets("Kimlik").Range("B9") = LBBclc.Value
End Sub
'Diğer değişkenler için burayı planladım
Private Sub tbBINR_Change()
Select Case tbBINR
Case "<1,7"
X = 1
Case "1,7 - 2,2"
X = 2
Case ">2,2"
X = 3
End Select
Sheets("Kimlik").Range("D7") = X
End Sub
Private Sub tbBAlb_Change()
'web.tr'nin eklediği değiştirme kodu
Select Case tbBAlb
Case ">3,5 g/dl"
X = 1
Case "2,8 - 3,5 g/dl"
X = 2
Case "<2,8 g/dl"
X = 3
End Select
Sheets("Kimlik").Range("F7") = X
End Sub
Private Sub tbBAssit_Change()
Select Case tbBassit
Case "YOK"
X = 1
Case "Hafifçe VAR"
X = 2
Case "Belirgin ASSİT VAR"
X = 3
End Select
Sheets("Kimlik").Range("H7") = X
End Sub
Private Sub tbBHE_Change()
Select Case tbBHE
Case "YOK"
X = 1
Case "Hafifçe VAR"
X = 2
Case "Belirgin H.E VAR"
X = 3
End Select
Sheets("Kimlik").Range("F9") = X
End Sub
Private Sub tbBBil_Change()
Select Case tbBbil
Case "<2 mg/dl"
X = 1
Case "2-3 mg/dl"
X = 2
Case ">3 mg/dl"
X = 3
End Select
Sheets("Kimlik").Range("D9") = X
End Sub
'diğer değişkenler için buradan tanımladım
Private Sub tbECOG_Change()
Sheets("Kimlik").Range("J9") = tbECOG.Value
End Sub
Private Sub tbPVT_Change()
Sheets("Kimlik").Range("J7") = tbPVT.Value
End Sub
Private Sub tbTDL_Change()
Sheets("Kimlik").Range("H9") = tbTDL.Value
End Sub
Private Sub tbEHY_Change()
Sheets("Kimlik").Range("F11") = tbEHY.Value
End Sub
Private Sub Temizle5_Click()
Me.tbCPS.Text = CStr(Sayfa1.Range("B7").Value)
End Sub
Private Sub UserForm_Initialize()
Application.ScreenUpdating = True
Worksheets("Kimlik").Select
If ThisWorkbook.Sheets("Kimlik").Range("B9").Value <> "" Then
Me.LBBclc.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B9").Value)
End If
Me.tbPatoloji.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("Patoloji").Value)
Me.tbHikaye.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("oyku").Value)
Me.cmbTX1.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B19").Value)
Me.cmbTX2.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B20").Value)
Me.cmbTX3.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B21").Value)
Me.cmbTX4.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B22").Value)
Me.cmbTX5.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B23").Value)
Me.cmbTX6.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B28").Value)
Me.cmbTX7.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B29").Value)
Me.cmbTX8.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B30").Value)
Me.cmbTX9.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B31").Value)
Me.cmbTX10.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("B32").Value)
Me.tbTED1.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D19").Value)
Me.tbTED2.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D20").Value)
Me.tbTED3.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D21").Value)
Me.tbTED4.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D22").Value)
Me.tbTED5.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D23").Value)
Me.tbTED6.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D28").Value)
Me.tbTED7.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D29").Value)
Me.tbTED8.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D30").Value)
Me.tbTED9.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D31").Value)
Me.tbTED10.Text = CStr(ThisWorkbook.Sheets("Kimlik").Range("D32").Value)
'eski tedavi seçeneklerini buraya ekleyeceğim
Dim eskitedavi(), i As Byte
eskitedavi = Array("Cerrahi rezeksiyon", "Transplantasyon", "TAKE", "Radyofrekans Ablasyon", "Sorafenib", "Adjuvan Kemoterapi", "Adjuvan Radyoterapi")
For i = 1 To 10
For ii = 0 To 6
Me.Controls("cmbTX" & i).AddItem eskitedavi(ii)
Next
Next
'buraya childpugh ile ilgili eklediklerimi yazacağım
With Me.LBBclc
.AddItem "BCLC - A"
.AddItem "BCLC - B"
.AddItem "BCLC - C"
.AddItem "BCLC - D"
End With
With Me.tbBbil
.AddItem "<2 mg/dl"
.AddItem "2-3 mg/dl"
.AddItem ">3 mg/dl"
End With
With Me.tbBAlb
.AddItem ">3,5 g/dl"
.AddItem "2,8 - 3,5 g/dl"
.AddItem "<2,8 g/dl"
End With
With Me.tbBINR
.AddItem "<1,7"
.AddItem "1,7 - 2,2"
.AddItem ">2,2"
End With
With Me.tbBassit
.AddItem "YOK"
.AddItem "Hafifçe VAR"
.AddItem "Belirgin ASSİT VAR"
End With
With Me.tbBHE
.AddItem "YOK"
.AddItem "Hafifçe VAR"
.AddItem "Belirgin H.E VAR"
End With
With Me.tbECOG
.AddItem "0"
.AddItem "1"
.AddItem "2"
.AddItem "3"
.AddItem "4"
End With
With Me.tbPVT
.AddItem "Açık"
.AddItem "Tromboze"
End With
With Me.tbTDL
.AddItem "Unilobar"
.AddItem "Bilobar"
End With
With Me.tbEHY
.AddItem "Yok"
.AddItem "EH Var"
End With
With Me.LB4
.AddItem "Hepatit_B"
.AddItem "Hepatit_C"
.AddItem "Primer_biliyer_siroz"
.AddItem "Alkolik_siroz"
.AddItem "Otoimmun_hepatit"
.AddItem "Non_alkolik_yağlı karaciğerH"
.AddItem "Hemokromatozis"
.AddItem "Diğer"
End With
End Sub
Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
Application.ScreenUpdating = True
Worksheets("Formlar").Select
End Sub
bu kodu koşullu hale getirince düzeldi, lakin anlamadım şimdi tüm hepsini bu hale mi getirmem gerekiyor??
Kodun en başına on error resume next eklerseniz hatayı görmez. Boş karakteri string ifadeye çevirmeye çalıştığı için hata veriyor.