Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.

Program za rad isporuke i kartovanja u posti

[es] :: Pascal / Delphi / Kylix :: Program za rad isporuke i kartovanja u posti

[ Pregleda: 2720 | Odgovora: 10 ] > FB > Twit

Postavi temu Odgovori

Autor

Pretraga teme: Traži
Markiranje Štampanje RSS

popmilan76

Član broj: 295089
Poruke: 1337
*.dynamic.sbb.rs.



+5 Profil

icon Program za rad isporuke i kartovanja u posti11.12.2011. u 08:44 - pre 149 meseci
Napravio sam jedan program za rad u posti,mozete ga uzeti slobodno i doraditi....a treba jos dosta toga
 
Odgovor na temu

popmilan76

Član broj: 295089
Poruke: 1337
*.dynamic.sbb.rs.



+5 Profil

icon Re: Program za rad isporuke i kartovanja u posti11.12.2011. u 08:48 - pre 149 meseci
program je radjen u delphiju,sa paradox tabelama,jel ima neko zainteresovan,neka kaze...i drustvo iskusnih programera neka daju neke sugestije.pozdrav
Prikačeni fajlovi
 
Odgovor na temu

segment
Vesna Lazareska Arsik
Skopje, Makedonija

Član broj: 280596
Poruke: 30
79.125.245.*



Profil

icon Re: Program za rad isporuke i kartovanja u posti12.12.2011. u 11:19 - pre 149 meseci
Na prv pogled
1. Zasto vo eden DataModule ne gi smestis site TTable i DataSource (mislam deka ke ti bide polesno)
2. Zasto vo formata DOSTAVAUNOS na ComboBox1Change moras da ispituvas sto e vrednost na comboto pa da go prenesuvas kako parametar
mozes PISMADOSTAVA.Query1.Params[0].ASSTRING := ComboBox1.text;

Kazi ja prikaznata za delovite sto ne uspevas da se snajdes (kolku mozam ke ti dadam sugestii i ke ti pomognam),
Se nadevam deka me razbiras zasto pisuvam na makedonski
 
Odgovor na temu

popmilan76

Član broj: 295089
Poruke: 1337
*.dynamic.sbb.rs.



+5 Profil

icon Re: Program za rad isporuke i kartovanja u posti12.12.2011. u 15:21 - pre 149 meseci
treba mi mala pomoc oko ovog programa,kako da mi sifra kojom se prijavljujem na kompu,tj na windows,da mi ta sifra izlazi na glavnoj formi(navigatoru),negtde dole pored vremena,ili na panelu....kako to...
 
Odgovor na temu

rambo
Dejan Petković
Beograd

Član broj: 6095
Poruke: 190
*.dynamic.sbb.rs.



+6 Profil

icon Re: Program za rad isporuke i kartovanja u posti12.12.2011. u 16:17 - pre 149 meseci
Verovatno misliš na Username a ne na šifru, jer se šifra nikada i nigde ne treba prikazivati. Jedan od načina da dobiješ ime trenutno prijavljenog Windows korisnika je pomoću funkcije GetUserName:

Code (delphi):
function GetLocalUserName: string;
var
  Count: DWORD;
begin
  Count := 256 + 1; // UNLEN + 1
  // set buffer size to 256 + 2 characters
  SetLength(Result, Count);
  if GetUserName(PChar(Result), Count) then
    SetLength(Result, Count)
  else
    Result := '';
end;

Ovu funkciju jednostavno koristiš ovako:
Code (delphi):
Label1.Caption := GetLocalUserName

Drugi jednostavniji način je da uzmeš JVCL i upotrebiš komponentu TJvComputerInfoEx. Dobićeš veliki broj informacija, a ono što tebe zanima je property Identification.LocalUserName. Da bi na primer popunio labelu svojim korisničkim imenom, napiši:
Code (delphi):
Label1.Caption := JvComputerInfoEx1.Identification.LocalUserName;


[Ovu poruku je menjao rambo dana 12.12.2011. u 19:52 GMT+1]
"There is a theory which states that if ever anybody discovers exactly what the
Universe is for and why it is here, it will instantly disappear and be replaced by
something even more bizarre and inexplicable. There is another theory which states
that this has already happened."
-- Douglas Adams
 
Odgovor na temu

popmilan76

Član broj: 295089
Poruke: 1337
*.dynamic.sbb.rs.



+5 Profil

icon Re: Program za rad isporuke i kartovanja u posti12.12.2011. u 17:11 - pre 149 meseci
meni treba ovako nesto,ali negde gresim...ne treba mi ime kompjutera,nego username pod kojim sam prijavljen

Code:

FUNCTION:     GetCurrentUserAndDomain - This function looks up
//                the user name and domain name for the user account
//                associated with the calling thread.
//
//  PARAMETERS:   szUser - a buffer that receives the user name
//                pcchUser - the size, in characters, of szUser
//                szDomain - a buffer that receives the domain name
//                pcchDomain - the size, in characters, of szDomain
// 
//  RETURN VALUE: TRUE if the function succeeds. Otherwise, FALSE and
//                GetLastError() will return the failure reason.
// 
//                If either of the supplied buffers are too small, 
//                GetLastError() will return ERROR_INSUFFICIENT_BUFFER
//                and pcchUser and pcchDomain will be adjusted to
//                reflect the required buffer sizes.
//
//**********************************************************************

function GetCurrentUserAndDomain(szUser : PChar;   pcchUser : DWORD;
       szDomain : PChar;  pcchDomain: DWORD) : boolean;

var
   fSuccess : boolean;
   hToken   : THandle;
   ptiUser  : PSIDAndAttributes;
   cbti     : DWORD;
   snu      : SID_NAME_USE;

begin
   ptiUser := nil;
   Result := false;

   try
      // Get the calling thread's access token.
      if (not OpenThreadToken(GetCurrentThread(), TOKEN_QUERY, TRUE,
            hToken)) then

       begin
         if (GetLastError() <> ERROR_NO_TOKEN) then
            exit;

         // Retry against process token if no thread token exists.
         if (not OpenProcessToken(GetCurrentProcess(), TOKEN_QUERY,
               hToken)) then
            exit;
       end;

      // Obtain the size of the user information in the token.
      if (GetTokenInformation(hToken, TokenUser, nil, 0, cbti)) then

         // Call should have failed due to zero-length buffer.
         Exit

       else

         // Call should have failed due to zero-length buffer.
         if (GetLastError() <> ERROR_INSUFFICIENT_BUFFER) then
            Exit;


      // Allocate buffer for user information in the token.
      ptiUser :=  HeapAlloc(GetProcessHeap(), 0, cbti);
      if (ptiUser= nil) then
         Exit;

      // Retrieve the user information from the token.
      if ( not GetTokenInformation(hToken, TokenUser, ptiUser, cbti, cbti)) then
         Exit;

      // Retrieve user name and domain name based on user's SID.
      if ( not LookupAccountSid(nil, ptiUser.Sid, szUser, pcchUser,
            szDomain, pcchDomain, snu)) then
         Exit;

      fSuccess := TRUE;

   finally

      // Free resources.
      if (hToken > 0) then
         CloseHandle(hToken);

      if (ptiUser <> nil) then
         HeapFree(GetProcessHeap(), 0, ptiUser);
   end;

   Result :=  fSuccess;
end;



[Ovu poruku je menjao savkic dana 12.12.2011. u 18:55 GMT+1]
 
Odgovor na temu

rambo
Dejan Petković
Beograd

Član broj: 6095
Poruke: 190
*.dynamic.sbb.rs.



+6 Profil

icon Re: Program za rad isporuke i kartovanja u posti12.12.2011. u 18:49 - pre 149 meseci
Da li si uopšte probao ono što sam ja napisao? Funkcija GetUserName upravo vraća ime trenutno ulogovanog korisnika, a postoji i GetUserNameEx kojoj možeš da zadaš format u kome želiš da ti vrati informacije. Međutim, to i mnogo više već radi TJvComputerInfoEx komponenta. Ako nisi probao, prvo proveri šta dobijaš onime što sam ti incijalno dao.
"There is a theory which states that if ever anybody discovers exactly what the
Universe is for and why it is here, it will instantly disappear and be replaced by
something even more bizarre and inexplicable. There is another theory which states
that this has already happened."
-- Douglas Adams
 
Odgovor na temu

popmilan76

Član broj: 295089
Poruke: 1337
*.dynamic.sbb.rs.



+5 Profil

icon Re: Program za rad isporuke i kartovanja u posti12.12.2011. u 18:57 - pre 149 meseci
tu komponentu nemam,koristim u ovom slucaju delphi 4,a nisam video ni u 7,,,,,mozes da mi kopiras ceo unit...
 
Odgovor na temu

reiser

Član broj: 7895
Poruke: 2314



+102 Profil

icon Re: Program za rad isporuke i kartovanja u posti12.12.2011. u 19:40 - pre 149 meseci
Oduvek mi je bilo fascinantno sto ljudi koriste ultra stare alate za razvoj ? Delphi 4 je star, pa sigurno, 15+ godina.. Predji na Delphi 7 barem, ako neces na XE.
 
Odgovor na temu

rambo
Dejan Petković
Beograd

Član broj: 6095
Poruke: 190
*.dynamic.sbb.rs.



+6 Profil

icon Re: Program za rad isporuke i kartovanja u posti12.12.2011. u 20:29 - pre 149 meseci
TJvComputerInfoEx je komponenta u okviru JVCL paketa. JVCL možeš skinuti odavde.

I da, svakako pređi bar na Delphi 7.

I još nešto. Batali Paradox. Pređi bar na Firebird RDBMS.
"There is a theory which states that if ever anybody discovers exactly what the
Universe is for and why it is here, it will instantly disappear and be replaced by
something even more bizarre and inexplicable. There is another theory which states
that this has already happened."
-- Douglas Adams
 
Odgovor na temu

popmilan76

Član broj: 295089
Poruke: 1337
*.dynamic.sbb.rs.



+5 Profil

icon Re: Program za rad isporuke i kartovanja u posti13.12.2011. u 10:00 - pre 149 meseci
hvala braco,reseno...koristim tu 4 jer je program koji se koristi na poslu u tom....pa zbog toga....hvala jos jednom
 
Odgovor na temu

[es] :: Pascal / Delphi / Kylix :: Program za rad isporuke i kartovanja u posti

[ Pregleda: 2720 | Odgovora: 10 ] > FB > Twit

Postavi temu Odgovori

Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.