Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Delphi Prob

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
NoManchesPuto
I post too much
Reputation: 0

Joined: 24 Jan 2009
Posts: 2820

PostPosted: Sun Mar 15, 2009 1:22 pm    Post subject: Delphi Prob Reply with quote

Ok well i made a drop down menu for my trainer i plan on releasing for aqw, and when i run the program and click on the hack menu(what i made) i get this error....

What does that mean? Also i am the Admin of this pc.
Back to top
View user's profile Send private message
Tsabo
Cheater
Reputation: 0

Joined: 03 Feb 2009
Posts: 44
Location: Texas

PostPosted: Sun Mar 15, 2009 2:54 pm    Post subject: Reply with quote

Can you supply the code for your click event?
_________________
Universal Game Trainer / Variable Scanner
v1.0 Beta http://blog.delphiaddict.com/
Back to top
View user's profile Send private message
NoManchesPuto
I post too much
Reputation: 0

Joined: 24 Jan 2009
Posts: 2820

PostPosted: Sun Mar 15, 2009 4:56 pm    Post subject: Reply with quote

Sure i coded the Hack Menu button in the main with this....


Code:
Form1.visible:=not(Form1.visible);



Also i wanted to say i put the implementations in the units correctly, they are...


Code:
uses Unit2;
Back to top
View user's profile Send private message
Tsabo
Cheater
Reputation: 0

Joined: 03 Feb 2009
Posts: 44
Location: Texas

PostPosted: Sun Mar 15, 2009 5:15 pm    Post subject: Reply with quote

If that's the only code that is on the click event handler then i would guess that Form1 isn't assigned. Put a break point on it, press your button, then in the IDE hover your mouse over Form1 and see what the value is. If it's nil then chances are that you haven't created the form yet.

You could also do something like this:
Code:
if not Assigned(Form1) then
  Application.CreateForm(TForm1, Form1);
Form1.Visible := not Form1.Visible;


I'm not a fan of creating project wide forms, I actually delete that global variable for them after the IDE creates a new form. The only one I leave is for the main form. But that's my personal preference and coding style.

You should also look into an addon to help with exception handling. There are two that come to mind, madshi and EurekaLog. I favor madshi. Either one will help you.

Regards

_________________
Universal Game Trainer / Variable Scanner
v1.0 Beta http://blog.delphiaddict.com/
Back to top
View user's profile Send private message
NoManchesPuto
I post too much
Reputation: 0

Joined: 24 Jan 2009
Posts: 2820

PostPosted: Sun Mar 15, 2009 5:17 pm    Post subject: dfdf Reply with quote

OMFG OMFG OMFG UUUUUUUUUUUUUUUUUUUUUUUUUUUU FIXED MA PROB OMFG OMFG THX SSSSOOOOOOOOOOOOOOOOOOOOOOOOOOOOMUCH MAN I LUV U =)))))))) ME SO HAAAAAPPPPYYYYY WOOT WOOT

*POURS WINE* *GULP GULP GULPGULPGULP* WOOT WOOT OMFG IMA REP U LIKE HELL LOL SOUNDED GAY LOL



ooops, now i need some more help por favor Laughing Laughing ok well i got that to open properly but when i edit my form and save it and code the buttons it gives me the error below.... these r the codes i used to code the buttons


Code:
procedure THackMenu.Button1Click(Sender: TObject);
begin
var
packetData:String;
begin
packetData:='%xt%zm%loadShop%1%'Edit1.Text+'%';
send(StrToInt(SockDisp.Text),pd[1],Length(pd)+1,0);

end;

procedure THackMenu.Button3Click(Sender: TObject);
begin
var
packetData:String;
begin
packetData:= '%xt%zm%loadEnhShop%1%'+Edit2.Text+'%'
send(StrToInt(SockDisp.Text),pd[1],Length(pd)+1,0);

end;

procedure THackMenu.Button2Click(Sender: TObject);
begin
var
packetData:String;
begin
packetData:='%xt%zm%loadHairShop%1%'+Edit3.Text+'%'
send(StrToInt(SockDisp.Text),pd[1],Length(pd)+1,0);

end;

end.



also ive tried exiting and going back but that doeesnt seem to work very well.
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 472

Joined: 09 May 2003
Posts: 25867
Location: The netherlands

PostPosted: Mon Mar 16, 2009 5:09 pm    Post subject: Reply with quote

perhaps you're currently running the .exe so it can't be overwritten.
Also, try scrolling up the error window, perhaps a couple of errors are shown before the fatal error


as for the code itself, yeah, that's not going to compile at all
begin
var
packetData:String;
begin
packetData:='%xt%zm%loadShop%1%'Edit1.Text+'%';
send(StrToInt(SockDisp.Text),pd[1],Length(pd)+1,0);

end;

1: begin before var is just not done
2: I don't know where you get pd from, but it's not in the function, if you want to use a string in a function that requires a pchar, use pchar(packetData)

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites