Boletim Pascal #38 - 31 DE JULHO DE 2002
ÍNDICE
1. ALGUMAS PALAVRAS DOS EDITORES
2. PROBLEMAS DE PERFORMANCE EM TCOLLECTION (DELPHI 3,4,5)
3. DESFAZER E REFAZER UTILIZANDO COMANDOS
4. RECUPERAR O NOME DO HOST A PARTIR DE UM ENDEREÇO IP
5. FÓRUMS
6. DELPHI NA REDE
- Sites em português
- Componentes, Bibliotecas e Utilidades
. Shareware/Comercial
. Freeware
- Artigos, Dicas e Truques
. Kylix
- Tutoriais
- Outros Links
________________________________________________________________________
1. ALGUMAS PALAVRAS DOS EDITORES
Editorial da Versão em Português
================================
Novamente eu aqui, pessoal, pedindo desculpas por mais um atraso. Parece
uma regra, não? Bem, dessa vez eu garanto que o número 39 ainda não
chegou m minhas mãos. De qualquer forma, agora as coisas estão voltando
a seus estado normal de temperatura e pressão e atrasos desse tipo não
devem mais acontecer. No último editorial, antecipei uma surpresa para
o número seguinte do boletim, mas mal sabia eu que a versão em inglês já
estava pronta e nada mais tinha a fazer. Bom, minha expectativa real é
ter algo de interessante para o número 40 do boletim. E chega de
promessas!
Agora chega de conversa. Divirtam-se com nosso boletim!
Demian Lessa
demian@knowhow-online.com.br
editor da versão em português
Editorial da Versão em Inglês
=============================
Gostaria de expressar meu agradecimento a William Egge por contribuir
com seu artigo "Desfazer e Refazer Utilizando Comandos" para esse número
e fico feliz de premiá-lo com o CD Delphi Information Library (DIL CD),
um grande recurso de informações com artigos, dicas, truques,
componentes, javascripts, imagens, update packs e muito mais, oferecido
pelo grupo de usuários da Borland, UK:
http://www.richplum.co.uk/dil/index.asp
Gostaria também de agradecer a Clever Components Support Team por sua
contribuição do artigo "PROBLEMAS DE PERFORMANCE EM TCOLLECTION (DELPHI
3,4,5)" também para esse número e fico feliz de premiá-los com uma
licença do AnyShape Transpack v2.0, componente para criação de janelas
transparentes em vários formatos com edição WYSIWYG, visualização em
tempo de desenvolvimento, arrasto automático e formulários stay-on-top
REAIS, entre outras funcionalidades, fornecido por MindBlast Software:
http://www.mindblastsoftware.com/?page=transpack&ref=PascalNL
Estive doente recentemente e por isso peço desculpas por não escrever
outra parte da série de artigos sobre assembler em Delphi.
Como muitos provavelmente já sabem, a Borland lançou o Kylix 3 na semana
passada com suporte para C++. Nesse passo, em 18 meses a versão do Kylix
será superior à do Delphi! :-) Você acha que a Borland está acertando ou
que estão lançando versões do Kylix muito próximas? Gostaríamos de ouvir
seus comentários a respeito.
Ernesto De Spirito
pascal-newsletter-owner@yahoogroups.com
________________________________________________________________________
JfControls Library. Multi-language. Multi-appearance. Skins. Privileges.
More than 40 integrated and customizable components. Impressive GUI.
Centralized resources administration. Multiple programming problems
solved. For Delphi 3-6 and C++ Builder 3-5. http://www.jfactivesoft.com/
________________________________________________________________________
2. PROBLEMAS DE PERFORMANCE EM TCOLLECTION(DELPHI 3,4,5)
Por Clever Components Support Team <info@CleverComponents.com>
Para maiores detalhes, veja o artigo original da Clever Components:
http://www.clevercomponents.com/articles/article008/collectionperf.asp
Se você está utilizando classes de TCollection nas suas aplicações
Delphi 3, 4 ou 5, então você achará esse artigo algo quanto
interessante.
Primeiramente vamos testar um trecho de código razoavelmente simples:
procedure TForm1.Button1Click(Sender: TObject);
var
old: TCollection;
i: integer;
begin
old := TCollection.Create(TCollectionItem);
for i := 0 to 100000 do
begin
old.Add;
end;
Windows.beep(900, 1000); // bipe de alta freqüência após a inclusão
// dos itens
old.Free;
Windows.beep(100, 1000); // bipe de baixa freqüência após a
// destruição dos itens
end;
Você pode imaginar que o bipe de baixa freqüência seguirá o de alta
freqüência imediatamente (afinal, o que pode ser mais rápido do que
destruir os itens de uma coleção?)- mas não segue!
De fato, há uma demora de 10-20 segundos para a destruição da coleção
contendo milhares de itens- e pior, sua CPU estará 100% ocupada. Nós
nos deparamos com esse problema quando um cliente reclamou que uma
aplicação "congelava o PC por alguns minutos".
Para entender porque isso acontece, você precisa dar uma olhada mais
detalhada nos métodos Destroy, SetCollection e RemoveItem de
TCollection, que se encontram em Classes.pas- o último é chave para
entender nosso problema.
Você pode também querer comparar a versão de seu TCollection.RemoveItem
com a versão do Delphi 6:
{ Classes.pas do Delphi 6 }
procedure TCollection.RemoveItem(Item: TCollectionItem);
begin
Notify(Item, cnExtracting);
if Item = FItems.Last then
FItems.Delete(FItems.Count-1) // corrige o problema original
else
FItems.Remove(Item);
Item.FCollection := nil;
NotifyDesigner(Self, Item, opRemove);
Changed;
end;
Agora você provavelmente irá querer corrigir o problema. Mas parece não
ser tão fácil pois TCollection.RemoveItem não é virtual tampouco
dinâmico.
Aqui vão duas soluções:
Você terá que alterar Classes.pas e trocar o TCollection.RemoveItem
pela versão do Delphi 6.
Copie a nova versão (corrigida) de Classes.pas no diretório de seu
projeto e coloque na primeira posição da cláusula uses de seu projeto:
program Project1;
uses
classes in 'classes.pas' // nova Classes.pas com
// RemoveItem corrigido
Forms,
Unit1 in 'Unit1.pas' {Form1};
{$R *.res}
begin
Application.Initialize;
Application.CreateForm(TForm1, Form1);
Application.Run;
end.
Agora seu projeto será compilado com a nova versão de TCollection.
Em algumas situações não é tão conveniente ou mesmo possível utilizar
uma versão alterada de Classes.pas. Nesse caso, temos um outro truque
para você.
type
{ TFixCollection - corrige TCollection.RemoveItem nos Delphi 3,4,5 }
TFixCollection = class(TCollection)
public
{ Infelizmente, Clear não é virtual nem dynamic portanto temos
que reintroduzi-lo }
procedure Clear;
destructor Destroy; override;
end;
procedure TFixCollection.Clear;
var
i: integer;
AList, OrgList: TList;
begin
AList := TList.Create;
try
OrgList := TList(PDWORD(DWORD(Self) + $4 +
SizeOf(TPersistent))^);
{ Guarde os ponteiros originais para os itens da coleção }
for i := 0 to OrgList.Count-1 do
AList.Add(OrgList[i]);
OrgList.Clear;
{ Destrua os itens da coleção }
for i := 0 to AList.Count-1 do
TCollectionItem(AList[i]).Free;
finally
AList.Free;
end;
inherited;
end;
destructor TFixCollection.Destroy;
begin
Clear;
inherited;
end;
{ Vamos tentar novamente! }
procedure TForm1.Button2Click(Sender: TObject);
var
old: TFixCollection;
i: integer;
begin
old := TFixCollection.Create(TCollectionItem);
for i := 0 to 100000 do
old.Add;
Windows.beep(900, 1000); // bipe de alta freqüência após a inclusão
// dos itens
old.Free;
Windows.beep(100, 1000); // bipe de baixa freqüência após a
// destruição dos itens
end;
Como você pode comprovar, agora funciona bem. Utilizamos um truque que
nos dá acesso aos membros protegidos de TCollection. Você pode utilizar
ambas as técnicas apresentadas em suas aplicações escritas nos Delphi 3,
4 e 5.
Para sua conveniência, o exemplo de performance de TCollection para os
Delphi 3, 4 e 5 está no arquivo anexado.
Clever Components Support Team
http://www.CleverComponents.com
info@clevercomponents.com
________________________________________________________________________
3. DESFAZER E REFAZER UTILIZANDO COMANDOS
Por William Egge egge@eggcentric.com
Visite Eggcentric em http://www.eggcentric.com
Existem duas formas de desfazer/refazer: uma baseia-se em estados e a
outra utiliza comandos. Esse artigo utiliza comandos e oferece o código
fonte da implementação de um gerenciador undo/redo TUndoRedoManager.
Esse artigo irá cobrir:
1. Comandos
2. Requisitos de um comando
3. Pilha de comandos
4. Gerenciador undo/redo
5. Agrupamento de comandos
6. Código fonte completo da solução
Um comando é simplesmente um objeto que implementa uma ação no sistema,
por exemplo, um programa de desenho pode implementar um comando de
linha, círculo, retângulo e assim por diante. Para implementar o
undo/redo com base em comandos é preciso projetar seu projeto para
utilizar os objetos de comando nas suas tarefas.
Já que queremos desfazer e refazer os efeitos dos vários comandos, os
próprios comandos deve ser capazes de desfazer e refazer suas ações
assim como realizar a ação inicial.
Os métodos principais de um comando são:
- Execute
- Undo
- Redo
Você pode imaginar o porquê da separação do Redo e o Execute. Isso se
deve ao fato de que a implementação do refazer pode ser distinta daquela
da ação inicial (Execute). Por exemplo, considerando o programa de
desenho, o Execute poderia selecionar o Brush e seguir algum algoritmo
de desenho para exibir um círculo transparente de forma gradual. O Redo
poderia simplesmente copiar o resultado do desenho original ao invés de
desenhar tudo novamente. Qualquer que seja o caso, se essa
funcionalidade não for necessária numa dada implementação, basta chamar
o Execute a partir de sua implementação.
OK, agora temos um comando. Precisamos lembrar a seqüência de comandos
de modo a permitir undo/redo em vários níveis. Essa funcionalidade é
implementada pela pilha de comandos.
Quando você desfaz, você remove o último comando da pilha e chama seu
método Undo. A próxima vez que você desfizer, você chama o método do
segundo comando a partir do tipo, e assim por diante. Quando você refaz,
você chama o método Redo do último comando sobre o qual você desfez.
Para simplificar, criamos duas listas, uma lista de comandos desfeitos e
outra de comandos que podem ser refeitos, e as encapsulamos no
gerenciador de comandos.
Para o gerenciador, definimos três métodos:
ExecuteCommand(Comando)
Undo
Redo
Internamente, o gerenciador manterá duas listas de comandos, Undo e
Redo.
Aqui está a seqüência completa:
1. Execute um comando passando-o para o método ExecuteCommand;
internamente o UndoRedoManager vai chamar o método Execute do comando
e então adicionar o comando ao topo da lista de undo.
2. Chamando undo, o gerenciador removerá o último comando da lista de
undo, chamará seu método undo e então removerá o comando da lista
undo, e o enviará para a lista de redo.
3. Chamando redo irá causar o oposto do último undo: o comando será
retirado da lista redo, terá seu método redo chamado e então será
enviado ao topo da lista undo novamente.
4. Agora, quando o próximo ExecuteCommand é chamado, nós temos que
ajustar a lista redo... excluir todos os comandos nela.
Algumas vezes, ou na maioria delas, ,você executará uma série de
comandos como um grupo único. Chamar undo e redo deverá desfazer e
refazer o grupo de ações e não os comandos individuais um por vez. Um
exemplo pode ser um tipo de assistente que realiza inúmeras tarefas e
que você gostaria que pudesse ter suas ações desfeitas e refeitas como
um grupo.
Dois métodos serão acrescentados ao UndoRedoManager:
BeginTransaction
EndTransaction
Todos os comandos executados entre as chamadas a BeginTransaction e
EndTransaction serão armazenados como um grupo. Você deve permitir
chamadas aninhadas a esses métodos.
Utilizando herança, isso é fácil de implementar. Fazemos uma classe
de grupo de comando que hera da classe comando; assim o gerenciador
irá agir como se estivesse trabalhando com um único comando.
Em anexo encontra-se o código completo do UndoRedoManager juntamente
com interfaces para IUndoRedoCommand e IUndoRedoCommandGroup.
Nota: Eu acho que muitos de nós pensamos nas interfaces Delphi como
relacionadas a ActiveX ou COM. Isso não é verdade: você pode criar
classes que implementam interfaces e que não tem qualquer implementação
COM ou ActiveX. Essas classes não exigem qualquer forma de registro
ou qualquer outra ação exigida de COM ou ActiveX. Você deve lembrar-se
que interfaces são contadas por referência e que são automaticamente
liberadas quando essa contagem atinge zero.
O código fonte está anexado no arquivo zip.
________________________________________________________________________
4. RECUPERAR O NOME DO HOST A PARTIR DE UM ENDEREÇO IP
Por Ernesto De Spirito <eds2008 @ latiumsoftware.com>
Se tivermos um endereço IP numa string (como '207.105.75.31') e
quisermos saber qual o nome do host associado, podemos utilizar a API
GetHostByAddr da biblioteca Windows Sockets ("Winsocks") 1.1 ou mais
nova. A função a seguir encapsula as chamada de API.
uses WinSock;
function GetHostByAddr(IP: string): string;
var
WSData: TWSAData;
SockAddrIn: TSockAddrIn;
HostEnt: PHostEnt;
begin
Result := '';
// Tente inicializar uma seçao winsock
if WSAStartup($101, WSData) = 0 then begin
// Converta a string IP em bytes, na ordem correta do endereço IP
SockAddrIn.sin_addr.S_addr := inet_addr(PChar(IP));
// Chame GetHostByAddr
HostEnt := WinSock.GetHostByAddr(@SockAddrIn.sin_addr.S_addr,
SizeOf(SockAddrIn.sin_addr.S_addr), AF_INET);
// Se bem sucedido...
if HostEnt <> nil then
// ...recupere o nome do host (valor de retorno)
Result := StrPas(Hostent^.h_name);
// Feche a seção winsock
WSACleanup;
end;
end;
Chamada de exemplo:
procedure TForm1.Button1Click(Sender: TObject);
begin
ShowMessage(GetHostByAddr('207.105.75.31'));
end;
________________________________________________________________________
5. FÓRUMS
Para juntar-se a qualquer um de nossos fóruns de discussão, a melhor
forma é assinar através da web, já que dessa forma você poderá acessar
todas as funcionalidades disponíveis no site (como alterar suas opções
de assinatura, visualizar mensagens passadas, baixar arquivos, etc.).
Um ID Yahoo! é necessário para isso e você pode adquirir o seu de forma
gratuita registrando-se como um usuário Yahoo! Mas se você não deseja
registrar-se ou se não tem acesso completo à Internet, você pode fazer
sua assinatura por e-mail (basta ter acesso a uma conta de e-mail).
Delphi (em Português)
=====================
Participe da lista de discussão do Grupo Delphi-BR e faça parte da mais
profissional lista Delphi do Brasil. Essa lista tem como objetivo a
troca de informações entre os diversos programadores Delphi em lingua
portuguesa. Aqui você encontrará grandes programadores brasileiros dando
suas contribuições para a comunidade e mantendo uma via de comunicação
entre todos os programadores Delphi brasileiros.
http://br.groups.yahoo.com/group/delphi-br/
Se você quer juntar-se ao grupo, a melhor forma é assinar a partir da
web, uma vez que pode acessar as funcionalidades especiais disponíveis
no site web (um ID Yahoo! é necessário; você pode obter um gratuitamente
registrando-se como um usuário Yahoo!) mas, se você não quer registrar-se
ou se não possui acesso Internet completo, você também pode assinar por
email:
http://br.groups.yahoo.com/group/delphi-br/join
delphi-br-subscribe@yahoogrupos.com.br
Delphi (em Inglês)
==================
Se você sabe bastante Delphi mas está longe de ser um guru, esse fórum
é para você. Esse é o único fórum para programadores Delphi em nível
intermediário na Web (experts Delphi também são bem-vindos :-)). O fórum
conta atualmente com mais de 700 membros e, em abril último, teve um
tráfego de pouco mais de 450 mensagens:
http://groups.yahoo.com/group/delphi-en
Se você quer juntar-se ao grupo, a melhor forma é assinar a partir da
web, uma vez que pode acessar as funcionalidades especiais disponíveis
no site web (um ID Yahoo! é necessário; você pode obter um gratuitamente
registrando-se como um usuário Yahoo!) mas, se você não quer registrar-se
ou se não possui acesso Internet completo, você também pode assinar por
email:
http://groups.yahoo.com/group/delphi-en/join
delphi-en-subscribe@yahoogroups.com
Kylix (em Inglês)
=================
Programação Kylix em geral.
http://groups.yahoo.com/group/KylixGroup/
Conto com sua participação no fórum para nos ajudar a crescer. Você
pode assinar pela web ou, mais facilmente, por e-mail:
http://groups.yahoo.com/group/KylixGroup/join
KylixGroup-subscribe@yahoogroups.com
Componentes (em Inglês)
=======================
Esse é um fórum para pesquisa/recomendação de componentes de software
(componetes VCL e CLX, objetos ActiveX, DLLs, SOs, etc.), assim como
utilitários, tutoriais, informações, etc. O fórum é novo e tem cerca de
160 membros e tráfego muito baixo:
http://tech.groups.yahoo.com/group/components/
Conto com sua participação no fórum para nos ajudar a crescer. Você
pode assinar pela web ou, mais facilmente, por e-mail:
http://tech.groups.yahoo.com/group/components/join
components-subscribe@yahoogroups.com
Desenvolvedores de Software (em Inglês)
=======================================
Esse é um fórum para discussões sobre o desenvolvimento de software e
para a troca de experiências de trabalho em ambientes profissionais e
comerciais. Esse não é um fórum sobre programação; os assuntos abordados
são mais gerais e independentes de linguagem de programação.
http://tech.groups.yahoo.com/group/software-developers/
Conto com sua participação no fórum para nos ajudar a crescer. Você
pode assinar pela web ou, mais facilmente, por e-mail:
http://tech.groups.yahoo.com/group/software-developers/join
software-developers-subscribe@yahoogroups.com
________________________________________________________________________
6. DELPHI NA REDE
Por Dave Murray <irongut @ vodafone.net>
Sites em português
==================
* Comunidade Delphi de Rio Preto
Portal com componentes, novidades, artigos, links e mais.
http://www.delphirp.com.br/
* Planet Delphi
Site brasileiro especializado em componentes para Delphi. Download
grátis.
http://www.fprass.hpg.ig.com.br/
* Delphi Company
Site do Fernando Gonçalves dedicado ao mundo Delphi
http://www.delphicompany.hpg.ig.com.br/
* IntereSite
Tudo sobre Delphi
http://www.ulbrajp.com.br/~tecnobyte/
* Advanced Developers
Delphi, productos, novidades, consultoria...
http://www.adev.com.br
* Fórum Delphi-BR
http://br.groups.yahoo.com/group/delphi-br/
* Fórum Delphi !!
http://www.qualyinf.com.br/forum/delphi/delphi.html
Componentes, Bibliotecas e Utilitários
======================================
Shareware/Comercial
-------------------
* SMImport v1.60 - by Scalabium Software
Native VCL suite for importing data into a dataset without external
libraries. Supports import from: MS Excel (without OLE/DDE), delimited
or fixed width text file, HTML, XML (without DOM), MS Access (using
DAO/MS Jet), Lotus 123, QuattroPro, Paradox, DBase and any TDataSet
descendant. Changes in v1.60: new fast spreadsheet engine, extended
date/time parsing, modified wizard, additional settings for support of
custom data formats (eg. currency string).
http://www.scalabium.com/
* The eBook & Box Cover Creator - By Laughingbird Software
Do-it-yourself eCover creation software. Create covers modifying
premade product boxes or ebooks (25 professionally designed covers to
choose from!), 3D product boxes, eBook covers, CD and Magazine covers!
For Macintosh and Windows.
http://www.thelogocreator.com/
Freeware
--------
* Indy 9 - by The Indy Pit Crew, FREEWARE with source
The long awaited Indy 9 has been released. Indy 9 now has 115
components (up from 69 in Indy 8) and many other improvements.
http://www.indyproject.org
* JVCL 1.32 for Delphi 5/6 - by Project JEDI, FREEWARE with source
The JEDI-VCL (JVCL) library is built from code donated by the JEDI
community. It consists of 300+ VCL components that can be instantly
reused in your Delphi (and potentially Kylix) projects.
http://jvcl.sourceforge.net/
* Direct SQL Components - by N Shanny + C Nicola, FREEWARE with source
Cross-platform (Windows+Linux) delphi native components for directly
accesing SQL servers without using any externall dll's. The first
release is for My-SQL but there are plans to extend it.
http://sourceforge.net/projects/directsql/
* SourceForge Setup 1.3 - by Delprhree, FREEWARE with source
Written in Delphi it can install SSH, completely set it up, and also
configure WinCVS for a given project. Designed to make SourceForge
easy to set up, it is split into stages which can be executed
independently. You can unpack SSH, set up SSH and set up WinCVS
individually or all together, depending on your needs.
http://sourceforge.net/projects/sfsetup/
* DelphiWebScript - by Matthias Ackermann + Hannes Hernler, OPEN SOURCE
Powerful script engine for your application or server side scripting.
The script language is a subset of Delphi pascal. Create user defined
functions, add function libraries or processes scripts embedded in
HTML pages. Create a DWS ISAPI, NSAPI or CGI module in 5 minutes!
http://sourceforge.net/projects/dws/
* ActiveX Scripting Components v1.07 - by A Wingrove, FREEWARE w. source
Collection of native VCL components designed to make adding scripting
in your programs easy. Requires Microsoft ActiveX Scripting Control.
http://www.torry.net/authorsmore.php?id=2027
* FreeReport PDF Export Filter v1.0 - by R C Ramirez, FREEWARE w. source
Export reports to PDF from FreeReport/FastReport. Features: identical
copies of your reports with no extra code, frames, Pictures, Lines,
Memo, Bar Code, compression (use Zlib units) and more.
http://www.torry.net/vcl/reports/reportdesigners/frexppdf.zip
* MD5 - by Dimka Maslov, FREEWARE with source
A translation of the RSA MD5 Message-Digest Algorithm described in RFC
1321. It contains functions to evaluate MD5 hashsum of a string, a
file, a stream or any memory buffer, to convert a hashsum evaluation
function result into a string of hexadecimal digits and to compare the
results of two evaluations. No other files or libraries are required.
http://endimus.com
* XPControls v2.10 - by Michael Frank, FREEWARE with source
WinXP Visual Styles supporting components: TXPAnimate, TXPCheckBox,
TXPCheckListBox, TXPGroupBox, TXPListView, TXPRadioButton,
TXPPageControl, TXPThemeAPI, TXPTrackBar.
http://www.torry.net/vcl/packs/interfacelite/xpcontrols.zip
* TAnalogGauge v1 - by Vyacheslav Shteg, FREEWARE with source
Simple meter / gauge component for float values, eg. voltmeter.
http://www.delphipages.com/uploads/Miscellaneous/AnalogGauge.zip
* Gradbar - by Stefan Badenhorst, FREEWARE with source
Derived from a TGraphic, it draws a gradient progress bar with a
default caption of the position. The scaling of the gradient colour
values and the caption can be changed.
http://www.delphipages.com/uploads/Gauges_Meters/gradbar.zip
* TMxOutLookBar v1.51 - by Lajos Farkas, FREEWARE with source
Supports: Office 97, Windows2000 and Windows XP styles; scrolling
headers; gradient, normal and tiled bitmap backgrounds, new bevels
introduced in Delphi 6; 100% native VCL code.
http://www.geocities.com/maxcomponents/
* TMSNPopUp v4.3 - by JWB Software, FREEWARE with source
Allows you to use popup windows like MSN Messenger, offers different
text styles, icon, text, title, customizable gradients, scrolling etc.
http://people.zeelandnet.nl/famboek/
* TXMLSerializer v1.0 - by JWB Software, FREEWARE with source (DELPHI6)
Pass an object as a parameter to the TXMLSerializer component to save
it to disk as XML; works with any object derived from TPersistent.
http://people.zeelandnet.nl/famboek/
Artigos, Dicas e Truques
========================
* About XML and Delphi - by Zarko Gajic
Everything you need to know about Delphi and the Extensible Markup
Language. Find out about creating and parsing XML documents, look for
parser components and more.
http://delphi.about.com/library/weekly/aa072500a.htm
* TOP 10 Delphi - by Zarko Gajic
Most popular Delphi Programming articles on Delphi About, July 2002.
http://delphi.about.com/library/weekly/bltop10.htm
* How to move the cursor to the currently focused control?
http://www.swissdelphicenter.ch/en/showcode.php?id=1300
* How to access protected properties?
http://www.swissdelphicenter.ch/en/showcode.php?id=1307
* How to extract the audio stream from an AVI file?
http://www.swissdelphicenter.ch/en/showcode.php?id=1309
* How to calculate a simple checksum?
http://www.swissdelphicenter.ch/en/showcode.php?id=1311
* How to get names of installed Mail-Clients?
http://www.swissdelphicenter.ch/en/showcode.php?id=1319
* How to obtain the path to your program at runtime?
http://www.swissdelphicenter.ch/en/showcode.php?id=1321
* How to manage, control NT-Services?
http://www.swissdelphicenter.ch/en/showcode.php?id=1322
* How to play sound through a sound card?
http://www.swissdelphicenter.ch/en/showcode.php?id=1324
* How to play a wave file backwards?
http://www.swissdelphicenter.ch/en/showcode.php?id=1325
* How to obtain DLL-specific version information?
http://www.swissdelphicenter.ch/en/showcode.php?id=1327
* How to print an Excel file?
http://www.swissdelphicenter.ch/en/showcode.php?id=1328
* How to backup a branch of the registry?
http://www.swissdelphicenter.ch/en/showcode.php?id=1330
* How to use Subscript or Superscript in a TRichEdit?
http://www.swissdelphicenter.ch/en/showcode.php?id=1331
* How to insert a image into a TRxRichEdit?
http://www.swissdelphicenter.ch/en/showcode.php?id=1332
* How to bring up a printer's properties dialog?
http://www.swissdelphicenter.ch/en/showcode.php?id=1334
* How to access Listbox items with API?
http://www.swissdelphicenter.ch/en/showcode.php?id=1335
* How to scroll a Treeview when Drag/Drop?
http://www.swissdelphicenter.ch/en/showcode.php?id=1347
* How to use a Webbrowser's OnDocumentComplete with frames?
http://www.swissdelphicenter.ch/en/showcode.php?id=1355
* How to change the TDBNavigator images?
http://www.swissdelphicenter.ch/en/showcode.php?id=1358
* How to validate credit cards?
http://www.swissdelphicenter.ch/en/showcode.php?id=1365
* How to change size of the Windows Start Button?
http://www.swissdelphicenter.ch/en/showcode.php?id=1369
* Something missing about packages - by Pablo Reyes
Packages are a great feature of Delphi, you can put not only
components into packages but also anything you want. This way you can
build modular, customizable applications.
http://www.delphi3000.com/articles/article_3328.asp
* Debugging Shell Extensions using Delphi - by Alex Tischenko
Details of Shell extensions debugging under Windows 9x/W2K/XP.
http://www.delphi3000.com/articles/article_3331.asp
* Quickly Convert JPEG 2 Bitmap - by Howard Barlow
http://www.delphi3000.com/articles/article_3334.asp
* Delphi Add-On : What's New and Hot in Delphi - by Zarko Gajic
Developing a simple Open Tools API menu expert with Delphi. With this
add-on you can get Delphi About's new and hot listing without even
leaving the Delphi IDE!
http://delphi.about.com/library/weekly/aa070902a.htm
* How to fix "dsgnintf.pas not found" - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=8&categories=General
* How to create a hint window with a thin black border - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=8&categories=General
* How to add autocomplete to a TComboBox - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=8&categories=General
* How to refresh file icons - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=15&categories=Graphics
* How to empty a TImage - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=15&categories=Graphics
* How to read progress with TWebBrowser - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=12&categories=Internet/LAN
* Determining Kylix (Linux) Application & Library dependancies - m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=16&categories=Kylix
* How to read file version information - by Mike Pijl
This function returns the full file version structure.
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=9&categories=System
* About Calling conventions
http://www.swissdelphicenter.ch/en/showcode.php?id=1233
* How to determine the version of Internet Explorer?
http://www.swissdelphicenter.ch/en/showcode.php?id=1252
* How to trap own hotkeys in my application?
http://www.swissdelphicenter.ch/en/showcode.php?id=1261
* How to get the primary domain controller (PDC)?
http://www.swissdelphicenter.ch/en/showcode.php?id=1272
* How to change the value of Constants?
http://www.swissdelphicenter.ch/en/showcode.php?id=1284
* How to quickly create a Paradox table using SQL?
http://www.swissdelphicenter.ch/en/showcode.php?id=1286
* How to enable the drop shadow effect on a window (XP)?
http://www.swissdelphicenter.ch/en/showcode.php?id=1296
* How to access the controls of a TRadioGroup?
http://www.swissdelphicenter.ch/en/showcode.php?id=1297
* How to create transparent menus (2000/XP)?
http://www.swissdelphicenter.ch/en/showcode.php?id=1298
* How to prevent a control from Redrawing (Refreshing)?
http://www.swissdelphicenter.ch/en/showcode.php?id=1301
* How to analyze PE file headers?
http://www.swissdelphicenter.ch/en/showcode.php?id=1302
* How to create a icon in the system tray?
http://www.swissdelphicenter.ch/en/showcode.php?id=1303
* How to replace text in a word document?
http://www.swissdelphicenter.ch/en/showcode.php?id=1304
* Using XML in Delphi applications: Part I - by Sergey Kucherov
Understanding XML, developing your own XML Object Model, writing your
own XML parser, using XML in Delphi applications and using XML as a
local database.
http://www.delphi3000.com/articles/article_3314.asp
* Dataset Row Checksum - by Andreas Schmidt
http://www.delphi3000.com/articles/article_3315.asp
* Using MDI while TMDIForm is not your mainform - Uros Gaber
You want to use TMDIForm that you open/create somewhere during runtime
and is not the mainform of your application but Delphi doesn't allow
you to create a TMDIChild if the TMDIForm is not your mainform.
http://www.delphi3000.com/articles/article_3317.asp
* Variable number of arguments - by Sigurdur Hannesson
How to create functions that can accept n number of arguements.
http://www.delphi3000.com/articles/article_3318.asp
* Rudimentary Menu Plug In Mechanism - by Alex Wijoyo
How to define menu plugins using a text file & create them at runtime.
http://www.delphi3000.com/articles/article_3319.asp
* Using IStrings and TStringsAdapter - Siva Rama Sundar Devasubramaniam
A Simple, Straight forward way of using 'IStrings' interface to pass
Multiple Strings from a COM Object.
http://www.delphi3000.com/articles/article_3320.asp
* Precise timer thread using messages - by Brian Pedersen
When programming realtime interfaces and computergames, you need a
precise timing signal. The engine must run at the same rate no matter
what your framerate is. This example shows a game timer implementation
using a thread and messaging.
http://www.delphi3000.com/articles/article_3321.asp
* Changing Interbase Error Messages in runtime - by Ernesto Cullen
Shows a technique used to tackle Interbase errors on the client side,
using IBX. Using this technique, you can turn ugly error messages into
more user friendly ones, or translate them into your own language.
http://www.delphi3000.com/articles/article_3322.asp
* How to get an Unique Identifier for a File or Folder - Gerald Koeder
Everyone who creates a File/folder copy or move-function must check if
a sourcefile/folder exists at the destination. But how can we prove
that two files don't point to the same physical place? Win2k and XP
allow you to mount any volume under a folder and so it's possible that
the files at 'c:\data\*.*' are the same as under 'd:\*.*' for example.
http://www.delphi3000.com/articles/article_3323.asp
* How to create a Combobox in a Stringgrid - by Boris B. Wittfoth
How to dynamically create a Combobox within a Cell of a StringGrid.
http://www.delphi3000.com/articles/article_3324.asp
* Sending data from database by portions - by Vladimir Orlenko
Some times we need send a huge quantity of data from a MiddleWare
Server to a client application. If we do it in one portion then the
user must wait a long time, but we can send this data in portions,
when the user needs it.
http://www.delphi3000.com/articles/article_3325.asp
* How to get the BDE DLL path - by Mike Pijl
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=13&categories=Databases
* How to get a list of open files in the IDE - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=14&categories=Delphi/Kylix+ID
* Access TListbox, TCombobox, TRadioGroup using types - by Mike Pijl
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=8&categories=General
* How to center controls at runtime by code - by Mike Pijl
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=8&categories=General
* How to read image pixels fast - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=15&categories=Graphics
* How to invert a bitmap - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=15&categories=Graphics
* How to get a file's date and time - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=9&categories=System
* How to create a temporary filename - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=9&categories=System
* How to launch the Windows Find dialog - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=9&categories=System
* How to read the mouse cursor position - by m3Rlin
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=9&categories=System
* Accessing DataBase via 3rd server - by Vladimir Orlenko
Writing n-tier Application for accessing client's app to DataBase
without installing Client of Database via 3rd server using Indy.
http://www.delphi3000.com/articles/article_3310.asp
* Understanding VisualCLX - Max Kleiner (KYLIX)
Beginning with Kylix requires learning about signals and slots, the
way Linux/Qt deals with events and the Qt-library.
http://www.delphi3000.com/articles/article_3311.asp
* Top Modeling/CASE Tools - by Zarko Gajic
What are the best UML tools on the market? There are a lot, providing
an interesting array of features. Here's a list of suggested tools to
make your Delphi developer days easier.
http://delphi.about.com/library/toppicks/aatpmodelcase.htm
* Simple HTML page scraping with Delphi - by Zarko Gajic
Shows the techniques nedded to download an HTML page from the net,
do some page scraping (using regular expressions for pattern matching)
and present the information in more *situation-friendly* manner.
http://delphi.about.com/od/networking/a/html_scraping.htm
* Making Delphi Interoperate with other languages - by Zarko Gajic
How to make Delphi and Delphi apps interoperate with apps written in
different programming languages. How to convert the code from other
languages to Delphi Pascal.
http://delphi.about.com/cs/delphiandothers/index.htm
* Creating ASP Objects with Delphi - by Zarko Gajic
If you use the MS IIS web server you will have noted its support for
ASP. Having created COM objects with Delphi you can easily call your
components from ASP scripts.
http://delphi.about.com/cs/aspwithdelphi/
* New IDE Building Blocks - by Zarko Gajic
Exploring ways to extend the Delpih IDE. Including portability issues,
IDE Packages, Desktop Windows and learn to write Design Windows.
http://delphi.about.com/library/weekly/aa033099.htm
* Using ADO.NET datasets in Delphi - by Zarko Gajic
If you've experimented with Web Services you might have seen some .NET
based services which return data in the default XML format from
ADO.NET. So you end up with XML but with no clue what to do with it!
http://delphi.about.com/cs/websnap/index.htm
* Data Exchange using XML and Delphi - by Zarko Gajic
You have a client-server application with data access via ADO or BDE.
It works great on a desktop or on a corporate intranet but Now your
clients want to access data remotely across a WAN, or the Internet...
http://delphi.about.com/library/weekly/aa072500a.htm
* Interview with Chad Z. Hower - by SwissDelphiCenter
Interview with Chad Hower ("Kudzu") the original author and project
coordinator for Indy, 110+ components included with Delphi 6 & Kylix.
http://www.swissdelphicenter.ch/en/chadhower.php
* How to find all classes registered by a form class?
http://www.swissdelphicenter.ch/en/showcode.php?id=1218
* How to Removing the todays date display from a TDateTimePicker?
http://www.swissdelphicenter.ch/en/showcode.php?id=1219
* How to make some Days bold in the TMonthCalendar?
http://www.swissdelphicenter.ch/en/showcode.php?id=1220
* How to use Base64 encoding and decoding?
http://www.swissdelphicenter.ch/en/showcode.php?id=1223
* How to saving several controls to one single file?
http://www.swissdelphicenter.ch/en/showcode.php?id=1224
* How to show my own help dialog when user clicks biHelp border icon?
http://www.swissdelphicenter.ch/en/showcode.php?id=1225
* How to tile a non-MDIframe window with a backgrund bitmap?
http://www.swissdelphicenter.ch/en/showcode.php?id=1226
* How to set a date of a TDateTimePicker to blank?
http://www.swissdelphicenter.ch/en/showcode.php?id=1227
* How to get a list of a printer's capabilities?
http://www.swissdelphicenter.ch/en/showcode.php?id=1228
* How to hide properties in the IDE?
http://www.swissdelphicenter.ch/en/showcode.php?id=1229
* How to show in-place Tooltips in a TListBox?
http://www.swissdelphicenter.ch/en/showcode.php?id=1230
* How to check or uncheck a Checkbox in another window?
http://www.swissdelphicenter.ch/en/showcode.php?id=1231
* How to Create a DBExpress-Connection at Runtime?
http://www.swissdelphicenter.ch/en/showcode.php?id=1234
* How to Set/Get Accessibility Time-out Periods?
http://www.swissdelphicenter.ch/en/showcode.php?id=1235
* How to draw a bounding box with the mouse?
http://www.swissdelphicenter.ch/en/showcode.php?id=1236
* How to retrieve information about the current keyboard?
http://www.swissdelphicenter.ch/en/showcode.php?id=1237
* How to draw a highlight box around the control under the mouse?
http://www.swissdelphicenter.ch/en/showcode.php?id=1238
* How to retrieve the handle to the Windows Shell window?
http://www.swissdelphicenter.ch/en/showcode.php?id=1239
* How to get handle to the window that ownes the taskbar buttons (NT)?
http://www.swissdelphicenter.ch/en/showcode.php?id=1240
* How to change the Button Captions in MessageDlg?
http://www.swissdelphicenter.ch/en/showcode.php?id=1241
* How to transfer strings, images (streams) between processes?
http://www.swissdelphicenter.ch/en/showcode.php?id=1242
* How to Encrypt/ Decrypt a String?
http://www.swissdelphicenter.ch/en/showcode.php?id=1243
* How to extract numbers from a string?
http://www.swissdelphicenter.ch/en/showcode.php?id=1244
* How to use MAPI to send an EMail with Attachements?
http://www.swissdelphicenter.ch/en/showcode.php?id=1246
* How to show a miniature view of a Webpage in TWebbrowser?
http://www.swissdelphicenter.ch/en/showcode.php?id=1247
* How to tell if a folder is shared?
http://www.swissdelphicenter.ch/en/showcode.php?id=1248
* How to check if a page in TWebbrowser is secure (SSL)?
http://www.swissdelphicenter.ch/en/showcode.php?id=1250
* How to check if a page in TWebbrowser is on a local drive?
http://www.swissdelphicenter.ch/en/showcode.php?id=1251
* How to set/get the background color of a page in TWebbrowser?
http://www.swissdelphicenter.ch/en/showcode.php?id=1254
* How to change the scrollbar colors of TWebBrowser?
http://www.swissdelphicenter.ch/en/showcode.php?id=1255
* How to obtain the text of a specified window's title bar?
http://www.swissdelphicenter.ch/en/showcode.php?id=1257
* How to change the default cell selection color in a TStringGrid?
http://www.swissdelphicenter.ch/en/showcode.php?id=1258
* How to link a TFilterComboBox with a TShellListView?
http://www.swissdelphicenter.ch/en/showcode.php?id=1259
* How to save a font to the registry/a stream?
http://www.swissdelphicenter.ch/en/showcode.php?id=1260
* How to Calculate Easter Day for a specified year?
http://www.swissdelphicenter.ch/en/showcode.php?id=1262
* How to capture a column resize event in a TListView?
http://www.swissdelphicenter.ch/en/showcode.php?id=1264
* Determine if your program/Service is running under the System account
http://www.swissdelphicenter.ch/en/showcode.php?id=1265
* How to save many streams in a (compressed, encrypted) file?
http://www.swissdelphicenter.ch/en/showcode.php?id=1266
* How to encrypt a image?
http://www.swissdelphicenter.ch/en/showcode.php?id=1268
* How to use a Syntax Highlighter?
http://www.swissdelphicenter.ch/en/showcode.php?id=1270
* How to save a file to a TBlobStream and read it back?
http://www.swissdelphicenter.ch/en/showcode.php?id=1271
* How to check if a service is running?
http://www.swissdelphicenter.ch/en/showcode.php?id=1275
* How to implement AfterShow, AfterCreate events?
http://www.swissdelphicenter.ch/en/showcode.php?id=1276
* How to get infos about aliases?
http://www.swissdelphicenter.ch/en/showcode.php?id=1277
* How to automatically insert a GUID into the code editor?
http://www.swissdelphicenter.ch/en/showcode.php?id=1280
* How to register or unregister an OCX/ActiveX?
http://www.swissdelphicenter.ch/en/showcode.php?id=1281
* How to check for prime numbers
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=10&categories=Math
* How to get the battery life
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=11&categories=Hardware
* How to resolve a host name
http://www.delphifaq.net/modules.php?op=modload&name=FAQ&file=index
&myfaq=yes&id_cat=12&categories=Internet/LAN
Tutoriais
=========
* Create an effective Data Model for your Database
The three phases of the data modeling process will help you create an
effective business database that transcends applications and won't
need reworking when new data is introduced. Learn about these three
phases and get more data modeling resources.
http://builder.com.com/article.jhtml?id=u00320020605dol01.htm
* Use SQL Subselects to consolidate queries - by Shelley Doll
Are normalized data structures giving you problems? Learn how to use
the SQL subselect statement and handle your database like a pro!
http://articles.techrepublic.com.com/5100-10878_11-1045787.html
* Creating Custom Delphi Components: Inside and Out - Alistair Keys
This tutorial explains component writing which should result in more
code reuse. It goes over properties, events and methods, and also how
to install components. The final part is about Object-Oriented design.
http://delphi.about.com/library/bluc/text/uc061102a.htm
* Remedial XML: Learning to play SAX - by Lamont Adam
Using DOM to parse XML documents you will notice that performance
suffers when dealing with large documents. This is endemic to DOM's
tree-based structure so where performance is problematic you can use
the Simple API for XML (SAX). This part of the Remedial XML series
introduces the SAX API and provides some links to implementations.
http://builder.com.com/article.jhtml?id=u00220020527adm01.htm
* Remedial XML: For Further Reading - by Lamont Adams
Wraps up this six-part remedial XML series with a list of suggested
Web resources to further your studies.
http://articles.techrepublic.com.com/5100-10878_11-1044662.html
Outros Links
============
* Press Release: Borland Breaks New Ground with C++Technology for Linux(r)
Kylix 3 delivers the first C/C++ and Borland Delphi integrated rapid
application development solution for creating database, GUI, Web, and
Web Services applications for the Linux(r) operating system.
http://community.borland.com/article/0,1410,28896,00.html
* Vote in Linux Journal's 2002 Readers' Choice awards
Vote for your favorite Linux related products.
http://community.borland.com/article/0,1410,28921,00.html
* Web Services: Messiah or Mirage? - by David Braue
Software vendors keep telling us that Web services are the answer but
noone knows the question. Explore the state of Web services today.
http://builder.com.com/article.jhtml?id=u00420020626gcn01.htm
* Programming within your comfort zone - by Shelley Doll
It's nice to be the expert but as time passes & technologies advance,
your area of expertise shrinks noticeably. If you never stop to look
outside your comfort zone you could be using obsolete techniques and
spending time programming solutions that have already been solved.
http://builder.com.com/article.jhtml?id=u00420020620dol01.htm
________________________________________________________________________
VOCÊ PODE NOS AJUDAR
Nós precisamos de sua ajuda para manter esse boletim ativo e cada vez
maior. Você pode ajudar indicando o boletim a seus amigos e colegas:
http://www.latiumsoftware.com/br/pascal/index.php
Você também pode votar para nós em um ou todos esses rankings para dar
maior visibilidade a nosso site e assim aumentar o número de assinantes
do boletim:
http://www.programmingpages.com/?r=latiumsoftwarecomenpascal
http://top100borland.com/in.php?who=20
São alguns segundos para você que REALMENTE significam muito para nós.
Não esqueça que também precisamos de artigos para os boletins e que
existe um prêmio para um dos autores em cada número (em inglês).
Todos os artigos serão considerados mas nós estamos particularmente
interessados em artigos sobre Kylix já que existe pouco material
disponível online.
* Envie seu artigo em inglês para
pascal-newsletter-owner@yahoogroups.com
* Envie seu artigo em português para
boletim-pascal-owner@yahoogrupos.com.br
________________________________________________________________________
Se você não recebeu o código fonte completo dos exemplos neste número,
você pode obtê-los em http://www.latiumsoftware.com/br/pascal/p0038.zip
________________________________________________________________________
Esse boletim é fornecido "COMO ESTÁ" sem garantias de qualquer tipo. Seu
uso implica na aceitação dos termos de licença e isenção de garantia que
podem ser lidos em http://www.latiumsoftware.com/br/pascal/index.php
Os artigos são propriedade e copyright de seus respectivos autores e
foram reproduzidos aqui com sua permissão. Você pode redistribuir esse
boletim desde que na sua íntegra (incluindo notas de propriedade e
copyright), sem alterações e de forma gratuita.
________________________________________________________________________
Página do grupo:.....: http://br.groups.yahoo.com/group/boletim-pascal/
Assinar..............: boletim-pascal-subscribe@yahoogrupos.com.br
Cancelar assinatura..: boletim-pascal-unsubscribe@yahoogrupos.com.br
Assinar/cancelar.....: http://groups.yahoo.com/group/boletim-pascal/join
Problemas com sua assinatura? boletim-pascal-owner@yahoogrupos.com.br
________________________________________________________________________
Boletim Pascal http://www.latiumsoftware.com/br/pascal/index.php
Copyright (c) 2002 por Ernesto De Spirito. Todos os direitos reservados.
________________________________________________________________________
|