15.07.2013 Views

Microsoft Visual Basic - Encyclopaedia Gentium Boni

Microsoft Visual Basic - Encyclopaedia Gentium Boni

Microsoft Visual Basic - Encyclopaedia Gentium Boni

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

frmLexiqueNT - 1<br />

Dim dico As Boolean<br />

Private Sub btnAjouter_Click()<br />

' au cas où<br />

Close<br />

Dim lexique$, lfile, Grec$, prononciation$, francais$, notes$<br />

lexique = App.Path & "\tools\lexiquegr.dic"<br />

lfile = FreeFile<br />

'définitions des variables<br />

Grec = txtHebreu.Text<br />

prononciation = txtPrononciation.Text<br />

francais = txtFrancais.Text<br />

notes = txtNotes.Text<br />

' attention VB ne gère pas les virgules & les guilleemnts<br />

francais = Replace(francais, ",", "~", 1, , vbTextCompare)<br />

notes = Replace(notes, ",", "~", 1, , vbTextCompare)<br />

notes = Replace(notes, Chr$(51), "'", 1)<br />

' ouverture du lexique pour écriture<br />

Open lexique For Append As #lfile<br />

rite #lfile, Grec & " " & francais & " 3/" & notes<br />

lose<br />

tnEffacer_Click<br />

nd Sub<br />

rivate Sub btnEffacer_Click()<br />

ico = True<br />

xtGrec.Text = ""<br />

xtFrancais.Text = ""<br />

xtNotes.Text = ""<br />

xtcode.Text = ""<br />

xtVientde.Text = ""<br />

xtAnalyse.Text = ""<br />

imer1.Enabled = False<br />

nd Sub<br />

rivate Sub btnFermer_Click()<br />

nload Me<br />

nd Sub<br />

rivate Sub btnGo_Click()<br />

im Grec$, prononciation$, francais$, notes$, recherche$, mot$, motdeflechi$<br />

rec = txtGrec.Text<br />

rancais = txtFrancais.Text<br />

otes = txtNotes.Text<br />

gestion erreurs<br />

f txtGrec.Text = "" And _<br />

txtFrancais.Text = "" Then<br />

lfile = MsgBox("Vous n'avez pas saisi votre recherche !", vbExclamation, "Rechercher un mot")<br />

Exit Sub<br />

nd If<br />

il faut DEFLECHIR le mot<br />

commençons par le NT<br />

If frmBible.cboVersion = "NA26+" Then<br />

mot = txtGrec.Text<br />

End If<br />

If Right(mot, 1) = "j" Then<br />

mot = Mid(mot, 1, Len(mot) - 1) & "s"<br />

mot = UCase(mot)<br />

Call LexiqueNT_Morph(mot)<br />

End If<br />

Par défaut la recherche est EXACTE<br />

détermination du mot-clé à chercher dans le lexique<br />

je cherche un mot GREC

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!