Aktív témák
-
Wasmacsó
csendes tag
ezt a témát azér hoztam létre, hogy vb-ről is menjen a duma. én is egy vb újonc vagyok, szeretnék tanulni! most TP után VB.net, a vb6.0-val már ismerkedtem, nagyon teccik. Hogy tudnám fejleszteni ezt a titkosító progit, amihez szereztem segítséget is...
Sub FileEncodeAndDecode(InputFile As String, OutputFile As String, PasswordKey As String)
Dim temp As Single
Dim Char As String * 1
Dim XORMask As Single
Dim temp1 As Integer
Open InputFile For Binary As #1
Open OutputFile For Binary As #2
For x = 1 To Len(PasswordKey)
temp = Asc(Mid$(PasswordKey, x, 1))
For y = 1 To temp
temp1 = Rnd
Next y
Randomize temp1
Next x
Counter = 0
For z = 1 To FileLen(InputFile)
XORMask = Int(Rnd * 256)
'Get the char & change it
Get 1, , Char
Char = Chr$((Asc(Char) Xor XORMask))
Put 2, , Char
Counter = Counter + 1
If Counter > Len(PasswordKey) Then Counter = 1
For x = 1 To (Asc(Mid$(PasswordKey, Counter, 1)) * 2 + 15 / 3 - 2 + 5 - 2 + 3 * 2 / 1 * 5 + 12 - 3)
temp = Rnd
Next x
Next z
Close #1
Close #2
End Sub
Private Sub Command5_Click()
MsgBox ''Please enter the real EXE(win32) file! And the password!''
Dim InputFile As String
Dim OutputFile As String
Dim PasswordKey As String
InputFile = InputBox(''Enter a filename to encode'')
OutputFile = InputBox(''Enter the new filename this will become '')
PasswordKey = InputBox(''Enter the password (key)'')
Call FileEncodeAndDecode(InputFile, OutputFile, PasswordKey)
MsgBox ''File written to '' + OutputFile
End
End Sub
Private Sub Form_Load()
MsgBox ''Please you're not put space char in Simple text textbox, because the program creates the error messages!''
End Sub
Public Function Encrypt(ByVal Plain As String)
For i = 1 To Len(Plain)
Letter = Mid(Plain, i, 1)
Mid(Plain, i, 1) = Chr(Asc(Letter) + 15 - 23 + 12 - 23 - 12 + 26 - 2 - 26 + 16 - 23 + Rnd(2))
Next
Encrypt = Plain
End Function
Public Function Decrypt(ByVal Encrypted As String)
For i = 1 To Len(Encrypted)
Letter = Mid(Encrypted, i, 1)
Mid(Encrypted, i, 1) = Chr(Asc(Letter) - 15 + 23 - 12 + 23 + 12 - 26 + 2 + 26 - 16 + 23 - Rnd(2))
Next
Decrypt = Encrypted
End Function
Private Sub Command1_Click()
Text1 = Encrypt(Text1)
End Sub
Private Sub Command2_Click()
Text1 = Decrypt(Text1)
End Sub
Private Sub Command3_Click()
frmAbout.Show
End Sub
Private Sub Command4_Click()
MsgBox ''Exit?:) What's is that exit?''
Unload Me
End Sub
nem suk matematikai függvényt ismerek vb-ben!
help pls!
Aktív témák
- Melyik tápegységet vegyem?
- Samsung Galaxy A54 - türelemjáték
- OLED TV topic
- Nvidia GPU-k jövője - amit tudni vélünk
- Folyószámla, bankszámla, bankváltás, külföldi kártyahasználat
- AMD Ryzen 9 / 7 / 5 9***(X) "Zen 5" (AM5)
- AMD vs. INTEL vs. NVIDIA
- Vezetékes FÜLhallgatók
- NVIDIA GeForce RTX 5080 / 5090 (GB203 / 202)
- Hogy is néznek ki a gépeink?
- További aktív témák...
- GYÖNYÖRŰ iPhone 13 128GB Blue -1 ÉV GARANCIA - Kártyafüggetlen, MS4681
- SK Hynix 16GB és 32GB DDR4 so dimm 3200MHz modulok számlával, 6 hó garanciával
- HIBÁTLAN iPhone 14 Plus 256GB Red-1 ÉV GARANCIA - Kártyafüggetlen, MS4561, 100% AKKSI
- BESZÁMÍTÁS! AsRock H510M i5 11400 16GB DDR4 512GB SSD RTX 2070 Super 8GB ZALMAN S2 TG Adata 600W
- HP Thunderbolt 4 kábel
Állásajánlatok
Cég: Laptopműhely Bt.
Város: Budapest
