g trouvé l'algo je l'ai mi ds les math et algorithmes. MERCI.
-------------------------------
Réponse au message :
-------------------------------
> Non mais avec un peu de chance tu doit pouvoir en trouver pour convertir de l'hexa en base 10.
> Il te sufirat alors de le modifier un peu
>
> function puissance(a, b)
> puissance = 1
> if b > 0 then
> for = 1 to b
> puissance = puissance * a
> next
> end if
> end function
>
> function convertion(a)
> if isnumeric(a) then convertion = cint(a)
> if a = "a" then convertion = 10
> if a = "b" then convertion = 11
> if a = "c" then convertion = 12
> if a = "d" then convertion = 13
> if a = "e" then convertion = 14
> if a = "f" then convertion = 15
> if a = "g" then convertion = 16
> if a = "h" then convertion = 17
> if a = "i" then convertion = 18
> if a = "j" then convertion = 19
> if a = "k" then convertion = 20
> if a = "l" then convertion = 21
> if a = "m" then convertion = 22
> if a = "n" then convertion = 23
> if a = "o" then convertion = 24
> if a = "p" then convertion = 25
> if a = "q" then convertion = 26
> if a = "r" then convertion = 27
> if a = "s" then convertion = 28
> if a = "t" then convertion = 29
> if a = "u" then convertion = 30
> if a = "v" then convertion = 31
> if a = "w" then convertion = 32
> if a = "x" then convertion = 33
> if a = "y" then convertion = 34
> if a = "z" then convertion = 35
> end function
>
> function base10(base36)
> dim matable
> redim matable len(base36)
> for i = 1 to len(base36) step 1
> matable(i) = mid(base36,i,1)
> next
>
> redim matable2(ubound(matable))
> j = ubound(matable)
> for i = 1 to ubound(matable2)
> matable2(i) = matable(j)
> j = j - 1
> next
>
> for i = 1 to ubound(matable2)
> base10 = base10 +puissance(convertion(matable(i)), i - 1)
> next
>
> end function
>
> essaie ca mais c tapper a l'arache
> -------------------------------
> Réponse au message :
> -------------------------------
>
> >
> > T'es super c'est ça la formule. MERCI. Je vais commencer à faire l'algo mais si tu l'as déjà tout près c bien aussi. MERCI.
> >
> >
> > -------------------------------
> > Réponse au message :
> > -------------------------------
> >
> > > c'est quoi la base 36??
> > > je connais la base 2, 8, 10, 16 mais la je suis sotcher
> > > si j'ai tout compris 0 en base 36 vaut 0 et z vaut 36
> > > donc la c'est pas compliquer tu applique la formule de conversion par puissance
> > >
> > > AX3 (base 36) = 10 * 36^2 + 24*36^1 + 3*36^0
> > > AX3 (base 36) = 12960 + 864 + 3
> > > AX3 (base 36) = 13827 (base 10)
> > >
> > > ci c'est le cas dit le moi je psu faire un algo
> > >
> > >
> > >
> > >
> > > -------------------------------
> > > Réponse au message :
> > > -------------------------------
> > >
> > > > Salut,
> > > > dans ma base SQL j'ai un identifiant salarié qui est en base 36.
> > > > ex : 17C, 17 D ect...
> > > > et il faut que je le passe en base 10.
> > > > Es ce que qq1 aurait la formule en asp? SVP.
> > > > MERCI
> > > >
> > > >

> > >
> >
>