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

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

fctLireCodeMorphAdjectif - 1<br />

Public Function LireCodeMorphAdjectif(code)<br />

ttype = "adjectif (a)"<br />

'les codes morpho de WH présentent une absence de ttype2<br />

'contrairement, apparemment, à ceux de NA27<br />

If Len(code) > 5 Then<br />

ttype2 = Mid(code, 2, 1)<br />

cas = Mid(code, 3, 1)<br />

genre = Mid(code, 4, 1)<br />

nombre = Mid(code, 5, 1)<br />

degre = Mid(code, 6, 1)<br />

ElseIf Len(code) = 5 Then<br />

cas = Mid(code, 2, 1)<br />

genre = Mid(code, 3, 1)<br />

nombre = Mid(code, 4, 1)<br />

degre = Mid(code, 5, 1)<br />

'il y a peut être d'autres cas...<br />

End If<br />

' TTYPE2 = TYPE D'ADJECTIF<br />

If ttype2 = "n" Then ttype2 = "normal (n)"<br />

If ttype2 = "s" Then ttype2 = "possessif (s)"<br />

If ttype2 = "d" Then ttype2 = "démonstratif (d)"<br />

If ttype2 = "q" Then ttype2 = "interrogatif (q)"<br />

If ttype2 = "i" Then ttype2 = "indéfini (i)"<br />

If ttype2 = "t" Then ttype2 = "intensif (t)"<br />

If ttype2 = "c" Then ttype2 = "cardinal (c)"<br />

If ttype2 = "o" Then ttype2 = "ordinal (o)"<br />

If ttype2 = "m" Then ttype2 = "nombre (m)"<br />

' CAS<br />

If cas = "n" Then cas = "nominatif (n)"<br />

If cas = "g" Then cas = "génitif (g)"<br />

If cas = "a" Then cas = "accusatif (a)"<br />

If cas = "d" Then cas = "datif (d)"<br />

If cas = "v" Then cas = "vocatif (v)"<br />

' GENRE<br />

If genre = "f" Then genre = "féminin (f)"<br />

If genre = "m" Then genre = "masculin (m)"<br />

If genre = "n" Then genre = "neutre (n)"<br />

'NOMBRE<br />

If nombre = "s" Then nombre = "singulier (s)"<br />

If nombre = "p" Then nombre = "pluriel (p)"<br />

'DEGRE<br />

If degre = "n" Then degre = "aucun (n)"<br />

If degre = "c" Then degre = "comparatif (c)"<br />

If degre = "s" Then degre = "superlatif (s)"<br />

' AFFECTATIONS<br />

'1) je renseigne la petite fenêtre Analyse Morphologique<br />

If ttype2 = "" Then ttype2 = " "<br />

frmAnalyseMorphologique.lblanalyse.Caption = Mid(ttype, 1, Len(ttype) - 3) & Mid(ttype2, 1, Len(tty<br />

pe2) - 3) & Mid(cas, 1, Len(cas) - 3) & Mid(genre, 1, Len(genre) - 3) & Mid(nombre, 1, Len(nombre)<br />

- 3) & Mid(degre, 1, Len(degre) - 3)<br />

'2) je renseigne les ComboBox de l'Assistant de recherche morphologique<br />

Load frmAssistant<br />

frmAssistant.cbo1.Text = ttype<br />

frmAssistant.cbo2.Text = ttype2<br />

frmAssistant.cbo3.Text = cas<br />

frmAssistant.cbo4.Text = genre<br />

frmAssistant.cbo5.Text = nombre<br />

If degre = "aucun (n)" Then degre = ""<br />

frmAssistant.cbo6.Text = degre<br />

End Function

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

Saved successfully!

Ooh no, something went wrong!