Sign in to follow this  
Followers 0
layer

LOC please help

7 posts in this topic

:D:idiot: ok heres my code, im in a hurry so

#include <GUIConstants.au3>
GUICreate ("File LOC", 400, 300)
GUISetBkColor (0x102021)
GUISetState (@SW_SHOW)
DirCreate (@AppDataDir & "\LOC\")
$lab= GUICtrlCreateLabel ("Welcome to FileLoc... FileLoc let's you Lock your files for safe keeping", 1, 1)
GUICtrlSetColor(-1, 0x4A49FF)
$inp= GUICtrlCreateInput ("", 50, 50,"" ,"" , 0x0020)
GUICtrlSetLimit ($inp, 12, 4)
$lab2= GUICtrlCreateLabel ("Enter the password for the file you want to lock:", -1, 25)
GUICtrlSetColor(-1,0xff0000)
$lab3= GUICtrlCreateLabel ("NOTE: 12 characters is the max for passwords and 4 is the minimum.", -1, 80)
GUICtrlSetColor(-1,0xff0000)
$inp2= GUICtrlCreateInput ("", 50, 150)
$lab4= GUICtrlCreateLabel ("Enter the path including the file in it (EX: C:\doc.txt\)", -1, 125)
GUICtrlSetColor(-1,0x00ff00)
$but= GUICtrlCreateButton ("Lock file now!", 50, 200)
$lab5= GUICtrlCreateLabel ("Make sure to copy down your password!", -1, 250)
GUICtrlSetColor (-1, 0xffffff)
$but2= GUICtrlCreateButton ("Help", -1, 275)
$but3= GUICtrlCreateButton ("About", 100, 275)
$but4= GUICtrlCreateButton ("Uses", 150, 275)
$but5= GUICtrlCreateButton ("Agreement", 200, 275)
$inp3= GUICtrlCreateInput ("", 175, 200, 200, 22)
$lab6= GUICtrlCreateLabel ("Enter a name to keep things organized:", 175, 175)
GUICtrlSetColor (-1,  0xFF8242)
$lab7= GUICtrlCreateLabel ("LOC is capeable of only locking one file!!", 200, 300)
$but6= GUICtrlCreateButton ("PLEASE NOTE", 275, 275)
Func LOC ()
   $readpass= GUIRead ($inp)
   $readdir= GUIRead ($inp2)
   $readname= GUIRead ($inp3)
   InIWrite (@AppDataDir & "\LOC\DirPassName.ini\", "Password", "Password", $readpass)
   IniWrite (@AppDataDir & "\LOC\DirPassName.ini\", "Directory", "Directory", $readdir)
   IniWrite (@AppDataDir & "\LOC\DirPassName.ini\", "Name", "Name", $readname)
   MsgBox (0, "Password is:", "Your password is:" & @LF & $readpass)
   $readinipass= IniRead (@AppDataDir & "\LOC\DirPassName.ini", "Password", "Password", "Info not found.")
   $readinidir= IniRead (@AppDataDir & "\LOC\DirPassName.ini\", "Directory", "Directory", "Info not found.")   
EndFunc
   
   
While 1
   $get= GUIGetMsg ()
   Select
  Case $get= $GUI_EVENT_CLOSE
      exitloop
   Case $get= $but
      LOC ()
   Case $get= $but2
      MsgBox (0, "Help", "Please send your EXACT problem(s) to me at rpm91m@aol.com")
   Case $get= $but3
      MsgBox (0, "About", "LOC was created by Ryan. The program language I used was AutoIt which can be found at http://www.autoitscript.com/autoit3/ which was created by Jonathan Bennett.")
   Case $get= $but4
      MsgBox (0, "Uses", "LOC was meant for making a file have a password. For example, if I make a file, I would go into LOC and type the password I want, type the file location, and a name for organizing. Now, when I go to that file and double click on it, a box will pop up and ask you for the password you entered.")
   Case $get= $but5
      MsgBox (0, "Agreement", "I here by claim myself responsible for anything, that may occur, while running this program and anything that may occur after running this program. I am not responsible for anything that this program does to your machine or anything else. Although LOC wasn't meant to do anything bad to your computer.")     
   Case $get= $but6
      MsgBox (0, "PLEASE NOTE", "PLEASE NOTE: LOC so far is only meant to lock one file!! Locking another file WILL cause the file you previously locked to be unlocked!! ALSO, THE PASSWORD YOU USE TO LOCK THE FILE UP IS THE PASSWORD THAT YOU WILL NEED TO OPEN THIS PROGRAM AGAIN!!!!")
      EndSelect
      WEnd

ok works fine, but how would i go about making it so that when the selected file was selected to be "LOC'ed", that when you double clicked on it, a Auti-It function would happen, like a validate passoword message box...

ill explain more when i get back, but in the mean time any ideas??!?! THNASK!! :lol:


FootbaG

Share this post


Link to post
Share on other sites



ok... im back... let me explain a little more...:

im making a program called LOC... and is what its going to do is open up the main gui, ask for a password, file, and basically like something like a username i guess you could call it that?... anyways.. it takes the file, and the password given, so now, doubling clicking that file that you have selected or running it will bring up an input box, the input box will ask for the password you supplied before.. if it's wrong, it will ask again until you close it, and if it's right, it opens the file! and the password you supply for the file will be the password to open up the actual program itself...! except!

My Problems

1. How can I make it so that when the file you have chosen to be locked, when it is ran, the input box will come up and ask for that passowrd you specified? Paremeters? New .LOC filetype?

2. How can I allow the option to lock more then one file?

3. How can I make it so that when LOC is ran once, the next time you go to run it, it will ask for a password?

Maybe some other problems in the future, but this is all for now, thanks!

P.S. if you choose to hel, could you help in 1. answer here 2. answer2 here 3. answer3here etc.... thank you so much! =DD


FootbaG

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

sorry, i don't want my post to get sunken down to the bottom, so *bump* and i waited a day to post this bump... any suggestions? need more detail?

edit:how do you change that thing next to your avatar like mass spammer? how do you change the text from mass spammer to something else? i tried looking in my controls but i didnt see it .... thanks

Edited by layer

FootbaG

Share this post


Link to post
Share on other sites

...

edit:how do you change that thing next to your avatar like mass spammer? how do you change the text from mass spammer to something else? i tried looking in my controls but i didnt see it .... thanks

<{POST_SNAPBACK}>

My Controls -> Edit profile info -> Custom member title :idiot:

Share this post


Link to post
Share on other sites

awww, how did i miss it!? lol, thanks josbe! i think i have an idea for my new LOC program!!!! im so excited, im gonna code my idea right now, ill post the results

thanks


FootbaG

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

hmmm... i tried doing the accept files for the input control... it lets u put files in, but they dissapear and stay on your desktop.. here i was just messing around:

#include <GUIConstants.au3>
GUICreate ("Accept Test", 400, 300)
GUISetState (@SW_SHOW)
$inp= GUICtrlCreateInput ("", 50, 50,"100" ,"100" , 0x0020, 0x00000018)
GUICtrlSetState (-1 ,$GUI_ACCEPTFILES)
While 1
   $get= GUIGetMsg ()
   if $get= $GUI_EVENT_CLOSE Then
      ExitLoop
   EndIf
   WEnd

thats just messing around, i want the input to accept files drag and drop style, so i drag an icon into it and it stays on the desktop and doesnt go into the input? any tips on how to actually use the Drag and Drop file feature???

EDIT: updated code, but it stilld ont work, i checked help file but i dont wanna copy there way... any help?

Edited by layer

FootbaG

Share this post


Link to post
Share on other sites

ok, now i found out it's not what i wanted it to be... what i need is a GUI that has open white space where if you dragged a file into it, it would take that file out of it's original spot and store it into the white place in the GUI... think this is possible? so i could go from there by writing some registry values to make a .LOC file and make a function for that, that relates to the first gui... i know confusing, but i gotta figure something... maybe a dll call that could make that white space?


FootbaG

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0