Mostrando postagens com marcador delphi. Mostrar todas as postagens
Mostrando postagens com marcador delphi. Mostrar todas as postagens

domingo, 2 de fevereiro de 2014

Delphi como Logar no Facebook e no Youtube ?


Nessa vídeo aula você aprenderá a criar um programa em Delphi que faz login na sua conta do Facebook e YouTube.

                                                     Como Baixar Arquivos no Site 4Shared:

  Download do Exemplo:

quarta-feira, 23 de janeiro de 2013

Calculadora em Delphi com Porcentagem


Variaveis Globais
  valor1, valor2, porcentagem:real;
  tipoconta:string;


botões numericos (aonde está o # você substitui pelo numero correspondente !)
 
    edit1.text:=edit1.text+'#';

-------- botão , --------

    edit1.text:=edit1.text+',';

-------- botão + --------

    tipoconta:='adição';
    valor1:=strtofloat(edit1.text);
    Edit1.Text:='';
    Label1.Caption:='+';

-------- botão - --------

    tipoconta:='subtração';
    valor1:=strtofloat(edit1.text);
    Edit1.Text:='';
    Label1.Caption:='-';

-------- botão x --------

    tipoconta:='multiplicação';
    valor1:=strtofloat(edit1.text);
    Edit1.Text:='';
    Label1.Caption:='X';

-------- botão / --------

    tipoconta:='divisão';
    valor1:=strtofloat(edit1.text);
    Edit1.Text:='';
    Label1.Caption:='/';

-------- botão = --------

    if tipoconta = 'adição' then
    begin
      valor2:=strtofloat(edit1.text);
      edit1.text:=floattostr(valor1+valor2);
   
    end;

    if tipoconta = 'subtração' then
    begin
      valor2:=strtofloat(edit1.text);
      edit1.text:=floattostr(valor1-valor2);
   
    end;

    if tipoconta = 'divisão' then
    begin
      valor2:=strtofloat(edit1.text);
      edit1.text:=floattostr(valor1/valor2);
   
    end;

    if tipoconta = 'multiplicação' then
    begin
      valor2:=strtofloat(edit1.text);
      valor1:= valor1*valor2;
      edit1.text:=floattostr(valor1);
   
    end;

-------- botão % --------

  if tipoconta = 'adição' then
   begin
      porcentagem:=strtofloat(edit1.text);
      porcentagem:=porcentagem/100;
      porcentagem:=porcentagem*valor1;
      edit1.text:=floattostr(valor1+porcentagem);
   end;

   if tipoconta = 'subtração' then
   begin
      porcentagem:=strtofloat(edit1.text);
      porcentagem:=porcentagem/100;
      porcentagem:=porcentagem*valor1;
      edit1.text:=floattostr(valor1-porcentagem);
   end;

-------- botão C --------

  edit1.text:='';
  valor1:=0;
  valor2:=0;
  tipoconta:='';
  Label1.Caption:='';

quinta-feira, 29 de novembro de 2012