Forum Discussion
RobboCop2001
Sep 05, 2022Copper Contributor
Can VBA be used to circumvent large number limits? VBA Procedure calls to Microsoft Calculator App?
I am trying to use Excel/VBA to replicate RSA encryption math as a learning/educational tool. The problem is that the math of RSA encryption takes a number to a large power then uses the MOD math function to get it back to a reasonably sized number. For example I would like to take the number 790 and raise it to the power of 333, then take the Mod 901 of that number which would give me a final result of 26. Excel can not do the math of 790^333, the result is too big of a number which results in an error. But the microsoft scientific calculator can do that math. Is there a way to use Excel VBA to do a procedure call to the microsoft scientific calculator to do the math and then return the final value of 26, which can then be entered into the spreadsheet? Or is there any other procedure, function call, api that Excel VBA can use to do this math-> ((790^333) Mod 901 = 26) while not hitting the numeric limitations of Excel variables?
No RepliesBe the first to reply