[Lazarus] Embedding a standard dialogue

Mark Morgan Lloyd markMLl.lazarus at telemetry.co.uk
Wed Apr 18 11:44:03 CEST 2012


reinierolislagers at gmail.com wrote:
> Sorry, on cell, so formatting limited here too.
> 
> Sample login form for mssql and sybase, i.e. 2 dbs at
> bug 21619... committed as sample program in trunk.
> I think the sample form could easily extended to support more dbs... Actually want to do that some day and get it into lazarus...
> 
> Ludo brands came up with the original code at the forum... Sorry, cannot find link here.
> 
> Regards,
> Reinier
> On 18-04-12 09:42 Mark Morgan Lloyd wrote:
> Apologies for my lousy threading here, a message got chopped by our 
> firewall.
> 
>  > > Is it possible to embed a standard dialogue in a custom form? For
>  > > example, if I wanted to filter text input through a user-specified
>  > > regular expression, can I set up a form containing a file-open
>  > > dialog plus an edit box for the regex, or do I have to implement
>  > > it from scratch?
>  >
>  > No, you must create your own dialog from scratch.
>  >
>  > Juha
> 
> OK, If I can lead on from this. The cause of bug 21792 that I raised 
> yesterday is, I'm told, that I'd set the main form visible but 
> minimised. The reason I'd done this is that before the form was 
> displayed I wanted the user to provide database login credentials, I 
> couldn't rely on a standard dialogue for that since I also needed to 
> have him select what kind of database- PostgreSQL or Firefox- as well as 
> the server and possibly port.
> 
> What is the correct thing to do in this sort of situation? I've seen a 
> description of a hack for Delphi which relied on creating the main form 
> manually, should something like that be attempted for Lazarus?
> 
> Or should I simply redo the app so that the login is the main form?

Thanks, I'll investigate. I notice that the form I set up allowed the 
server type, name/address, port, SSL usage, user name and password to be 
set up.

-- 
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]




More information about the Lazarus mailing list