Rapid-Q Documentation Project (RQDP) |
Release 01
FAQ - 002 |
Credits & Contributions: |
Issues: |
William Yu |
Original Documentation |
Stanescu Serban |
New documents, Project management |
Others: |
Rapid-Q Groups, Yahoo eGroups. |
Current Document/Author/Revision/Release |
faq002.html/Andreas Fink/Serban S./01 |
-------------------------------------------------------------
Hi all,
This is my complete RapidQ-List archive. It begins in late
June 2000. In late October 2000 I've decided to unsubscribe
because there wasn't much more than general complaints about
William's choice and discussion of alternatives to RapidQ.
Then I have February 2001 sice the 17th...
Please scan this for good Question & Answer pairs...
FastCow AKA Andreas Fink
-------------------------------------------------------------
________________________________________________________________________
Message: 21
Date: Thu, 22 Jun 2000 10:57:55 EDT
From: rpgconcep82113@aol.com
Subject: (no subject)
i bet this is probably a stupid question ever.. or what... can i use
DIRECTDRAW in RQ? :-)
________________________________________________________________________
Message: 22
Date: Thu, 22 Jun 2000 12:28:44 -0400
From: "Thomas Simers (\"Echecero\")"
Subject: Re: Colour chooser dialogs...
>b) we just attribute the problem to windows, call it unfixable, and
>instead use something like the RGB.bas to form the basis of a colour
>chooser? I would like option b). Of course credit where credit due...
I've been using this alteration of RGB.bas. There may be something
better out there, but I just set the ScrollBars to the last used values for
the color attribute the user is now setting, then call BGForm.Show
When BGok is pressed, the routine it goes to uses the BGForm.Caption to
determine which attribute (my most recent usage checks to see if
INSTR(BGForm.Caption, "FG")>0 to know its the Foreground Color and "BG" for
background, but it could be anything, of coure.
I didn't notice the Windows one on the knowledge base page, I'll have to
go look into that. Thomas.
FUNCTION ConvertRGB(R AS INTEGER, G AS INTEGER, B AS INTEGER) AS INTEGER
ConvertRGB = (B SHL 16) OR (G SHL 8) OR R
END FUNCTION
DIM BGForm AS QForm
DIM LabelRed AS QLabel
WITH LabelRed
.parent=BGForm
.Left = 10
.Top = 22
.Caption = "Red:"
END WITH
DIM LabelGreen AS QLabel
WITH LabelGreen
.parent=BGForm
.Left = 5
.Top = 52
.Caption = "Green:"
END WITH
DIM LabelBlue AS QLabel
WITH LabelBlue
.parent=BGForm
.Left = 10
.Top = 82
.Caption = "Blue:"
END WITH
DIM LabelNum1 AS QEdit
WITH LabelNum1
.parent=BGForm
.Left = 270
.Width=75
.Top = 22
.Text = "0"
.OnChange=LChange
END WITH
DIM LabelNum2 AS QEdit
WITH LabelNum2
.parent=BGForm
.Left = 270
.Width=75
.Top = 52
.Text = "0"
.OnChange=LChange
END WITH
DIM LabelNum3 AS QEdit
WITH LabelNum3
.parent=BGForm
.Left = 270
.Width=75
.Top = 82
.Text = "0"
.OnChange=LChange
END WITH
DIM ScrollRed AS QScrollBar
WITH ScrollRed
.parent=BGForm
.Left = 50
.Top = 20
.Width = 200
.Height = 20
.Min = 0
.Max = 255
.LargeChange=10
.ShowHint = True
.Hint = "Red Attribute"
.OnChange = ColorChange
END WITH
DIM ScrollGreen AS QScrollBar
WITH ScrollGreen
.parent=BGForm
.Left = 50
.Top = 50
.Width = 200
.Height = 20
.Min = 0
.Max = 255
.LargeChange=10
.ShowHint = True
.Hint = "Green Attribute"
.OnChange = ColorChange
END WITH
DIM ScrollBlue AS QScrollBar
WITH ScrollBlue
.parent=BGForm
.Left = 50
.Top = 80
.Width = 200
.Height = 20
.Min = 0
.Max = 255
.LargeChange=10
.ShowHint = True
.Hint = "Blue Attribute"
.OnChange = ColorChange
END WITH
DIM PaintBox AS QCanvas
WITH PaintBox
.parent=BGForm
.Left = 50
.Top = 110
.Height = 90
.Width = 200
.OnPaint = Paint
END WITH
DIM BGok AS QButton
WITH BGok
.parent=BGForm
.left=255
.width=90
.height=20
.top=180
.caption="OK"
.onClick=BGokClick
END WITH
WITH BGForm
.Caption = "Select FG Color"
.FormStyle=3
.BorderStyle=4
.Width=355
.Height=230
.Center
END WITH
SUB ColorChange
LabelNum1.OnChange=0
LabelNum2.OnChange=0
LabelNum3.OnChange=0
LabelNum1.Text = STR$(ScrollRed.Position)
LabelNum2.Text = STR$(ScrollGreen.Position)
LabelNum3.Text = STR$(ScrollBlue.Position)
Paint
LabelNum1.OnChange=LChange
LabelNum2.OnChange=LChange
LabelNum3.OnChange=LChange
END SUB
SUB Paint
PaintBox.Paint(0,0,ConvertRGB(ScrollRed.Position, ScrollGreen.Position,
ScrollBlue.Position), _
ConvertRGB(ScrollRed.Position, ScrollGreen.Position,
ScrollBlue.Position))
END SUB
SUB LChange
ScrollRed.OnChange=0
ScrollGreen.OnChange=0
ScrollBlue.OnChange=0
ScrollRed.Position=VAL(LabelNum1.Text)
ScrollGreen.Position=VAL(LabelNum2.Text)
ScrollBlue.Position=VAL(LabelNum3.Text)
Paint
ScrollRed.OnChange=ColorChange
ScrollGreen.OnChange=ColorChange
ScrollBlue.OnChange=ColorChange
END SUB
________________________________________________________________________
Message: 23
Date: Thu, 22 Jun 2000 13:28:46 -0600 (MDT)
From: William Yu
Subject: Re: Re: MAPI
On Thu, 22 Jun 2000, Wilbert Brants wrote:
> Thanks for your answer but with the file you are referring to I have to
> know the smtp server and if I would like to give someone else the
> opportunity to send me a generated message I don't know his smtp sever.
> The MAPI way I asked for is as far as I know no COM object. It uses
> three functions from the MAPI32.DLL library. I found an even better
> documented one on the basicguru site
> http://www.basicguru.com/dickinson/files/pb_map2.bas
It looks like it's possible then, just a lot of work in converting it...
> But it's in PB and if I try to convert the source I get errors. You see,
> I don't know that much of RQ and PB and passing information to a DLL is
> rather complex (for me).
There's a lot of conversion that needs to be done, changing all the ASCIIZ
datatypes to LONG in UDTs, changing ASCIIZ to STRING in the DLL
parameters, etc... if I can find the time I'll attempt to convert some of
them.
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)
________________________________________________________________________
Message: 24
Date: Thu, 22 Jun 2000 21:35:23 +0200
From: "Erlend Rovik"
Subject: Re: Colour chooser dialogs...
Are you using showmodal? I guess you are and this will freeze everything,
don't know why but try this instead:
CREATE form as qform
show ' instead of showmodal
END CREATE
DO
DoEvents
LOOP UNTIL form.Visible = 0
Works for me...
-----Original Message-----
From: Daniel Foote
To: rapidq@egroups.com
Date: 22. juni 2000 12:04
Subject: [rapidq] Colour chooser dialogs...
>Hello all!
>
>I need to implement a colour chooser dialog. I have tried the windows
>one, as demonstrated in the Knowledge base, however, this sorta mucks
>things up (freeze program after clicking "Ok"). Could:
>a) somebody explain why things don't work OR
>b) we just attribute the problem to windows, call it unfixable, and
>instead use something like the RGB.bas to form the basis of a colour
>chooser? I would like option b). Of course credit where credit due...
>
>One thing to note about the Windows colour dialog: the idea is that
>you have your main form, and then an options form is brought up. Then
>the dialog is evoked when the "Change colour" button is clicked.
>Immediately the options form vanishes, and after clicking "ok" on the
>dialog, you can not use anything. The only way to quit is to use
>ALT+CTRL+Delete and select "End task" (I hate doing this... it stops
>my MP3's from playing in the background whilst the ALT+CTRL+Delete
>diaog box is up).
>I hope somebody can help!
>Thankyou, Daniel Foote.
________________________________________________________________________
Message: 25
Date: Thu, 22 Jun 2000 13:31:30 -0600 (MDT)
From: William Yu
Subject: Re: WorkArea...
On Thu, 22 Jun 2000, Thomas Simers ("Echecero") wrote:
> ...I've been asking a lot of you William...I'm sorry, but I have one
> more question before I call it a night...
>
> < taskbar. To retrieve the size of the work area, call the
> SystemParametersInfo function with SPI_GETWORKAREA.>>
>
> I know that Screen.Width and Screen.Height give a good idea of the area
> available, but I think a Workarea.Height and Workarea.Width would be of more
> use, so that we can make windows to fill the available space, but not cover
> the taskbar(s)...?
I guess I could do that, let me know what kind of application you had in
mind that does that. It doesn't seem that useful, since you can just
maximize your app to fill the workarea.
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)
________________________________________________________________________
From - Fri Jun 23 14:44:38 2000
------------------------------------------------------------------------
There are 4 messages in this issue.
Topics in this digest:
1. Re: Colour chooser dialogs...
From: William Yu
2. Re: QTreeView - unable to xtract item().***
From: William Yu
3. Re: (no subject)
From: William Yu
4. Re: (no subject)
From: rpgconcep82113@aol.com
________________________________________________________________________
Message: 1
Date: Thu, 22 Jun 2000 13:48:06 -0600 (MDT)
From: William Yu
Subject: Re: Colour chooser dialogs...
On Thu, 22 Jun 2000, Daniel Foote wrote:
> I need to implement a colour chooser dialog. I have tried the windows
> one, as demonstrated in the Knowledge base, however, this sorta mucks
> things up (freeze program after clicking "Ok"). Could:
> a) somebody explain why things don't work OR
Do you have the latest libraries? I can't imagine what the problem is...
Maybe it's an older version... I recall updating it last week.
BTW, does ReadUDT work for you now? You mentioned something about the
array of UDT causing problems, and I couldn't reproduce it, is it still
acting up?
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)
________________________________________________________________________
Message: 2
Date: Thu, 22 Jun 2000 13:50:18 -0600 (MDT)
From: William Yu
Subject: Re: QTreeView - unable to xtract item().***
On Thu, 22 Jun 2000, d turland wrote:
> Cant seem to get anything out of QTreeView.item() ie
>
> Dim zzz as string
> zzz=tree.item(1).Text
> showmessage zzz
Oops, thanks for the bug report, I seem to have plugged in an extra line
which shouldn't be there. Sorry for the inconvenience, it will be fixed
in the next release.
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)
________________________________________________________________________
Message: 3
Date: Thu, 22 Jun 2000 13:55:14 -0600 (MDT)
From: William Yu
Subject: Re: (no subject)
On Thu, 22 Jun 2000 rpgconcep82113@aol.com wrote:
> i bet this is probably a stupid question ever.. or what... can i use
> DIRECTDRAW in RQ? :-)
Not directly, but it's implemented as QDXSCREEN.
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)
________________________________________________________________________
Message: 4
Date: Thu, 22 Jun 2000 18:23:43 EDT
From: rpgconcep82113@aol.com
Subject: Re: (no subject)
In a message dated 6/22/00 12:58:55 PM Pacific Daylight Time,
voxel@freenet.edmonton.ab.ca writes:
<< > I bet this is probably a stupid question ever.. or what... can i use
> DIRECTDRAW in RQ? :-)
Not directly, but it's implemented as QDXSCREEN.
>>
ODXSCREEN? what it has do? will you have some of feature with directdraw? :p
----------------------------------------------------------
We are the programmer, so is the God
________________________________________________________________________
From - Fri Jun 23 14:44:40 2000
------------------------------------------------------------------------
There are 8 messages in this issue.
Topics in this digest:
1. Re: Colour chooser dialogs...
From: "Daniel Foote"
2. Re: Re: Colour chooser dialogs...
From: William Yu
3. Re: (no subject)
From: William Yu
4. The Menu Editor?
From: chRis=A9
5. Numbers in scientific notation
From: "Achilles Mina"
6. Re: Numbers in scientific notation
From: William Yu
7. Re: Numbers in scientific notation
From: William Yu
8. Re: Numbers in scientific notation
From: "wasaywasay"
________________________________________________________________________
Message: 1
Date: Fri, 23 Jun 2000 00:21:02 -0000
From: "Daniel Foote"
Subject: Re: Colour chooser dialogs...
Hello all!
Well, yes, I do have the latest libraries (not the small libraries).
By the way, to show the colour dialog ShowModal is not used, but for
the options form it is. Weird. I think it would just be easier to use
something like RGB.bas - but I have only one problem. How do I decode
an integer into three hexidecimal values for colour, in the correct
RapidQ order?
As well as that, yes, the ReadUDT problem is fixed - it reads strings=20
perfectly now. Thankyou very much!!
Thankyou all, Daniel Foote
--- In rapidq@egroups.com, William Yu wrote:
> On Thu, 22 Jun 2000, Daniel Foote wrote:
>=20
> > I need to implement a colour chooser dialog. I have tried the=20
windows=20
> > one, as demonstrated in the Knowledge base, however, this sorta=20
mucks=20
> > things up (freeze program after clicking "Ok"). Could:
> > a) somebody explain why things don't work OR
>=20
> Do you have the latest libraries? I can't imagine what the problem=20
is...
> Maybe it's an older version... I recall updating it last week.
>=20
> BTW, does ReadUDT work for you now? You mentioned something about=20
the
> array of UDT causing problems, and I couldn't reproduce it, is it=20
still
> acting up?
> +--------------------------------+ __
> | E-mail: voxel@e... |___| \_____________________
> | http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
> +--------------------------------+ +_________________________)
________________________________________________________________________
Message: 2
Date: Thu, 22 Jun 2000 18:27:23 -0600 (MDT)
From: William Yu
Subject: Re: Re: Colour chooser dialogs...
On Fri, 23 Jun 2000, Daniel Foote wrote:
> Well, yes, I do have the latest libraries (not the small libraries).=20
> By the way, to show the colour dialog ShowModal is not used, but for=20
> the options form it is. Weird. I think it would just be easier to use=20
> something like RGB.bas - but I have only one problem. How do I decode=20
> an integer into three hexidecimal values for colour, in the correct=20
> RapidQ order?
Do you mean something like this:
Clr =3D 349579345
Blue =3D Clr AND &HFF0000
Green =3D Clr AND &HFF00
Red =3D Clr AND &HFF
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)
________________________________________________________________________
Message: 3
Date: Thu, 22 Jun 2000 18:30:27 -0600 (MDT)
From: William Yu
Subject: Re: (no subject)
On Thu, 22 Jun 2000 rpgconcep82113@aol.com wrote:
> In a message dated 6/22/00 12:58:55 PM Pacific Daylight Time,=20
> voxel@freenet.edmonton.ab.ca writes:
>=20
> << > i bet this is probably a stupid question ever.. or what... can i use=
=20
> > DIRECTDRAW in RQ? :-)
>=20=20
> Not directly, but it's implemented as QDXSCREEN.
> >>
>=20
>
> DXSCREEN? what it has do? will you have some of feature with directdraw?
> :p
QDXSCREEN encapsulates some of the features of directdraw, you can see how
this is done with some of the examples listed.
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)
________________________________________________________________________
Message: 4
Date: Thu, 22 Jun 2000 18:23:50 -0700
From: chRis=A9
Subject: The Menu Editor?
I know it's easy, but I'm screwing up somewhere on the menu editor. I m=
ake the menu, copy and paste the code. Is there something else I'm supposed=
to do? -chris
[This message contained attachments]
________________________________________________________________________
Message: 5
Date: Fri, 23 Jun 2000 07:30:04 -0000
From: "Achilles Mina"
Subject: Numbers in scientific notation
Hello all,
I would like to know if there's a way to force Rapid-Q's STR$ not to=20
prematurely convert an output to scientific notation. To illustrate:
defdbl b
a =3D 99999
b =3D 1/a
b$ =3D STR$(b)
print b ' 0.000010000
print
print b$ ' 1.00001E-5
do
loop until inkey$ <> ""
As it stands now, Rapid-Q will give 1.000010000, an incorrect output,
if you do val(b$).
Thanks in advance for your help. Achilles
________________________________________________________________________
Message: 6
Date: Fri, 23 Jun 2000 01:40:33 -0600 (MDT)
From: William Yu
Subject: Re: Numbers in scientific notation
On Fri, 23 Jun 2000, Achilles Mina wrote:
> I would like to know if there's a way to force Rapid-Q's STR$ not to=20
> prematurely convert an output to scientific notation. To illustrate:
>=20
> defdbl b
>=20
> a =3D 99999
> b =3D 1/a
> b$ =3D STR$(b)
>=20
> print b ' 0.000010000
> print
> print b$ ' 1.00001E-5
>=20
> do
> loop until inkey$ <> ""
>=20
> As it stands now, Rapid-Q will give 1.000010000, an incorrect output,=20
> if you do val(b$).
Actually, you've discovered a bug in the VAL function, it wasn't
recognizing 'E' it was only taking 'e' instead.
Problem will be fixed in the next release, for now you can try using STRF$
or FORMAT$ with more precision.
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)
________________________________________________________________________
Message: 7
Date: Fri, 23 Jun 2000 01:42:33 -0600 (MDT)
From: William Yu
Subject: Re: Numbers in scientific notation
On Fri, 23 Jun 2000, William Yu wrote:
> On Fri, 23 Jun 2000, Achilles Mina wrote:
>=20
> > I would like to know if there's a way to force Rapid-Q's STR$ not to=20
> > prematurely convert an output to scientific notation. To illustrate:
> >=20
> > defdbl b
> >=20
> > a =3D 99999
> > b =3D 1/a
> > b$ =3D STR$(b)
> >=20
> > print b ' 0.000010000
> > print
> > print b$ ' 1.00001E-5
> >=20
> > do
> > loop until inkey$ <> ""
> >=20
> > As it stands now, Rapid-Q will give 1.000010000, an incorrect output,=20
> > if you do val(b$).
>=20
> Actually, you've discovered a bug in the VAL function, it wasn't
> recognizing 'E' it was only taking 'e' instead.
> Problem will be fixed in the next release, for now you can try using STRF$
> or FORMAT$ with more precision.
Oh, just another suggestion: VAL(LCASE$(B$))
Works too...
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)
________________________________________________________________________
Message: 8
Date: Fri, 23 Jun 2000 16:02:18 +0800
From: "wasaywasay"
Subject: Re: Numbers in scientific notation
Righto. Thanks again William.
Achilles
----- Original Message -----
From: William Yu
To:
Sent: Friday, June 23, 2000 3:42 PM
Subject: Re: [rapidq] Numbers in scientific notation
> On Fri, 23 Jun 2000, William Yu wrote:
>
> > On Fri, 23 Jun 2000, Achilles Mina wrote:
> >
> > > I would like to know if there's a way to force Rapid-Q's STR$ not to
> > > prematurely convert an output to scientific notation. To illustrate:
> > >
> > > defdbl b
> > >
> > > a =3D 99999
> > > b =3D 1/a
> > > b$ =3D STR$(b)
> > >
> > > print b ' 0.000010000
> > > print
> > > print b$ ' 1.00001E-5
> > >
> > > do
> > > loop until inkey$ <> ""
> > >
> > > As it stands now, Rapid-Q will give 1.000010000, an incorrect output,
> > > if you do val(b$).
> >
> > Actually, you've discovered a bug in the VAL function, it wasn't
> > recognizing 'E' it was only taking 'e' instead.
> > Problem will be fixed in the next release, for now you can try using
STRF$
> > or FORMAT$ with more precision.
>
> Oh, just another suggestion: VAL(LCASE$(B$))
> Works too...
>
> +--------------------------------+ __
> | E-mail: voxel@edmc.net |___| \_____________________
> | http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
> +--------------------------------+ +_________________________)
________________________________________________________________________
From - Sat Jun 24 10:47:01 2000
------------------------------------------------------------------------
There are 25 messages in this issue.
Topics in this digest:
1. Re: Colour chooser dialogs...
From: "Daniel Foote"
2. Bug? QForm.ShowTitleBar
From: "Steven Edwards"
3. Re: Re: Colour chooser dialogs...
From: "Steven Edwards"
4. how to write....
From: rpgconcep82113@aol.com
5. Non-blocking call for QSocket
From: "Daitau Aaron"
6. Re: MAPI
From: "Wilbert Brants"
7. Re: Re: Colour chooser dialogs...
From: William Yu
8. Re: Bug? QForm.ShowTitleBar
From: William Yu
9. Re: how to write....
From: William Yu
10. Re: Non-blocking call for QSocket
From: William Yu
11. Font setting bug in IDE?
From: "Daitau Aaron"
12. Re: Re: MAPI
From: William Yu
13. Re: how to write....
From: rpgconcep82113@aol.com
14. Creating a Custom Component.Problem
From: brynm
15. Re: Creating a Custom Component.Problem
From: "Erlend Rovik"
16. Re: Creating a Custom Component.Problem
From: brynm
17. Re: Creating a Custom Component.Problem
From: "Erlend Rovik"
18. Re: Creating a Custom Component.Problem
From: brynm
19. Re: Creating a Custom Component.Problem
From: "Erlend Rovik"
20. Re: Creating a Custom Component.Problem
From: brynm
21. Re: Creating a Custom Component.Problem
From: brynm
22. Re: Creating a Custom Component.Problem
From: "Erlend Rovik"
23. Re: Creating a Custom Component.Problem
From: William Yu
24. Re: Creating a Custom Component.Problem
From: brynm
25. Re: Bug? QForm.ShowTitleBar
From: "Steven Edwards"
________________________________________________________________________
Message: 1
Date: Fri, 23 Jun 2000 12:19:20 -0000
From: "Daniel Foote"
Subject: Re: Colour chooser dialogs...
Hello all!
Ok, I'd like to know if I could include RGB.bas as part of my
program? Is this ok? Don't worry, credit will be given to William for
this portion of the program.
As well as that, I can now make a number into it's component colours,
but how do I do it the other way? The old RGB.bas had a function for
it, but the examples don't include the old RGB.bas anymore - just a
new version which does not include such a function.
Thankyou, Daniel.
--- In rapidq@egroups.com, William Yu wrote:
> On Fri, 23 Jun 2000, Daniel Foote wrote:
>
> Well, yes, I do have the latest libraries (not the small
>libraries).
> By the way, to show the colour dialog ShowModal is not used, but
>for the options form it is. Weird. I think it would just be easier to
>use something like RGB.bas - but I have only one problem. How do I
>decode an integer into three hexidecimal values for colour, in the
>correct RapidQ order?
>
> Do you mean something like this:
>
> Clr = 349579345
>
> Blue = Clr AND &HFF0000
> Green = Clr AND &HFF00
> Red = Clr AND &HFF
>
> +--------------------------------+ __
> | E-mail: voxel@e... |___| \_____________________
> | http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
> +--------------------------------+ +_________________________)
________________________________________________________________________
Message: 2
Date: Fri, 23 Jun 2000 11:18:51 -0500
From: "Steven Edwards"
Subject: Bug? QForm.ShowTitleBar
In working on the reference for the QForm component ( see, I told you I
would have more questions... ), I have come across what appears to be a bug.
Or is it another "feature"? :)
A QForm.HideTitleBar method call will remove the caption bar AND slide the
remaining client area up so that the top of the client area is now wehre the
top of the caption bar used to be. The client area is still the same size -
the bottom of the form is pulled upward also.
A following QForm.ShowTitleBar method call willl restore the caption bar,
BUT the outer border remains the same dimensions. The result is a loss of
about 38 pixels in the height of the client area in the form.
Each Show / Hide reduces the height by another 38 pixels.
I know a reset of the .ClientHeight and .ClientWidth values will restore the
proper dimensions, but this must then be followed by a repaint or the
controls are not redrawn properly.
Here is a code snippet to demonstrate the problem:
create form as qform
clientheight = 200
create button as qbutton
height = 180
end create
center
show
end create
wait = timer
do
loop until timer - wait > 5
form.hidetitlebar
print form.clientheight
wait = timer
do
loop until timer - wait > 5
form.showtitlebar
print form.clientheight
'form.clientheight = 200
'form.repaint
wait = timer
do
loop until timer - wait > 5
form.hidetitlebar
print form.clientheight
wait = timer
do
loop until timer - wait > 5
form.showtitlebar
print form.clientheight
'form.clientheight = 200
'form.repaint
wait = timer
do
loop until timer - wait > 5
________________________________________________________________________
Message: 3
Date: Fri, 23 Jun 2000 11:22:26 -0500
From: "Steven Edwards"
Subject: Re: Re: Colour chooser dialogs...
From: Daniel Foote
To:
> As well as that, I can now make a number into it's component colours,
> but how do I do it the other way? The old RGB.bas had a function for
> it, but the examples don't include the old RGB.bas anymore - just a
> new version which does not include such a function.
Here is the function from the old RGB.BAS file:
'' Here's something that will convert your standard RGB to Rapid-Q's BGR.
FUNCTION ConvertRGB(R AS INTEGER, G AS INTEGER, B AS INTEGER) AS INTEGER
ConvertRGB = (B SHL 16) OR (G SHL 8) OR R
END FUNCTION
________________________________________________________________________
Message: 4
Date: Fri, 23 Jun 2000 13:30:35 EDT
From: rpgconcep82113@aol.com
Subject: how to write....
how to write my own custom compnent and compile it? :-)
________________________________________________________________________
Message: 5
Date: Fri, 23 Jun 2000 18:12:43 GMT
From: "Daitau Aaron"
Subject: Non-blocking call for QSocket
Hi,
I noticed in the newer incarnation of the example http.bas there is a way
to make a non-blocking call to QSocket. However the code intertwines with
the UI element, namely a custom formProc needs to be created to intercept
the custom WM_SOCK message. I wonder if there is any cleaner way to do
that? (I am trying to write some functions so that I could say something
like
content$=getURL("http://www.yahoo.com:80")
and I would like the whole thing contained in the getURL function. Any
ideas?
Daitau Aaron
________________________________________________________________________
Message: 6
Date: Fri, 23 Jun 2000 18:12:34 -0000
From: "Wilbert Brants"
Subject: Re: MAPI
Dear William,
Thank you for at least considering converting the source. This is
what I have already done. But I keep getting Exception
EAccessViolation errors with the MAPILogon function. Don't know
what's causing that...
Kind Regards, Wilbert
-------
TYPE MAPIRECIP
iReserved As Long
iRecipClass As Long
lpszName As Long
lpszAddress As Long
iEIDSize As Long
lpEntryID As Long
END TYPE
TYPE MAPIFILEDESC
iReserved As Long
iFlags As Long
iPosition As Long
lpszPathName As Long
lpszFileName As Long
lpFileType As Long
END TYPE
TYPE MAPIMESSAGE
iReserved As Long
lpszSubject As Long
lpszNoteText As Long
lpszMessageType As Long
lpszDateReceived As Long
lpszConversationID As Long
iFlags As Long
lpOriginator As Long
iRecipCount As Long
lpRecips As Long
iFileCount As Long
lpFiles As Long
END TYPE
Declare Function MAPILogon Lib "MAPI32.DLL" Alias "MAPILogon" _
(iParam As Long, zName As String, zPW As String,
iFlags As Long, _
iReserved As Long, iSession As Long) As Long
Declare Function MAPILogoff Lib "MAPI32.DLL" Alias "MAPILogoff" _
(iSession As Long, iParam As Long, iFlags As Long, _
iReserved As Long) As Long
Declare Function MAPISendDocuments Lib "MAPI32.DLL"
Alias "MAPISendDocuments" _
(iParam As Long, zDelimChar As String, zFilePaths As
String, _
zFileNames As String, iReserved As Long) As Long
' MapiRtn=MAPISendDocuments (0, "", "c:\netlog.txt", "netlog.txt", 0)
' *** This one sends the c:\netlog.txt document as an attachment and
prompts
' the user for other information ***
Declare Function MAPISendMail Lib "MAPI32.DLL" Alias "MAPISendMail" _
(iSession As Long, iParam As Long, lpMapiMessage As
Long, _
iFlags As Long, iReserved As Long) As Long
Dim iSessionID As Long
Dim iMapiRtn As Long
Dim rMessage As MAPIMESSAGE
Dim gRecip As MAPIRECIP
iMapiRtn=MAPILogon(0, "", "", 1, 0, iSessionID) ' ***
MAPI Logon command ***
gRecip.iReserved = 0
gRecip.iRecipClass = 1
Name$="Wilbert Brants"
gRecip.lpszName = VarPtr(Name$)
Address$="wbrants@dds.nl"
gRecip.lpszAddress = VarPtr(Address$)
gRecip.iEIDSize = 0
gRecip.lpEntryID = 0
rMessage.iReserved = 0
Subject$="Test"
rMessage.lpszSubject = VarPtr(Subject$)
NoteText$="This is a test"
rMessage.lpszNoteText = VarPtr(NoteText$)
rMessage.lpszMessageType = 0
DateReceived$="Date$+" "+Time$
rMessage.lpszDateReceived = VarPtr(DateReceived$)
rMessage.lpszConversationID = 0
rMessage.iFlags = 0
rMessage.lpOriginator = 0
rMessage.iRecipCount = 1
rMessage.lpRecips = VarPtr(gRecip)
rMessage.iFileCount = 0
rMessage.lpFiles = 0
iMapiRtn=MAPISendMail (iSessionID, 0, VarPtr(rMessage), 1, 0)
' *** MAPI Send mail command ***
iMapiRtn=MAPILogoff (iSessionID, 0, 0, 0)
' *** MAPI Logoff command ***
________________________________________________________________________
Message: 7
Date: Fri, 23 Jun 2000 12:18:35 -0600 (MDT)
From: William Yu
Subject: Re: Re: Colour chooser dialogs...
On Fri, 23 Jun 2000, Daniel Foote wrote:
> Ok, I'd like to know if I could include RGB.bas as part of my
> program? Is this ok? Don't worry, credit will be given to William for
> this portion of the program.
I should probably mention this but, all the examples from me are public
domain, the ones without names on them are usually mine, I left them out
for that purpose, samething you'd see in the knowledge base, if no name is
on them, it's public domain. You can even sell the MSWEEP example if you
wanted ;-)
> As well as that, I can now make a number into it's component colours,
> but how do I do it the other way? The old RGB.bas had a function for
> it, but the examples don't include the old RGB.bas anymore - just a
> new version which does not include such a function.
Because it's redundant, the function was replaced by RGB. It should
actually be named BGR but $DEFINE BGR RGB solves that :)
+--------------------------------+ __
| E-mail: voxel@edmc.net |___| \_____________________
| http://www.basicguru.com/abc/ | | o o o o o o o o o |__\_
+--------------------------------+ +_________________________)