Page 1 of 1
class Outlook 2003
Posted: Fri Jan 04, 2008 1:53 am
by Silvio
Dear Antonio,
I saw your outlook 2003 class and I want ask you if is possible to insert a splitter here :
because I saw another VB class with splitter
Posted: Fri Jan 04, 2008 8:30 am
by Antonio Linares
Silvio,
We may simulate it, because if we use a real splitter control then we may need two controls: one for the top side and another for the bottom side.
Posted: Fri Jan 04, 2008 12:51 pm
by Silvio
Antonio,
the top control must be link to the bottom control if i click a menu must open the components of this option.
it is difficult add a splitter into your control?
why you not try to see vb and dElphi oulook controls to see how run it?
Posted: Fri Jan 04, 2008 2:32 pm
by Antonio Linares
Silvio,
We don't need a real splitter there. We need a "simulated" one, same as we resize a browse columns.
Posted: Fri Jan 04, 2008 11:26 pm
by Silvio
ok, but I not Know how make it ...
Posted: Fri Jan 04, 2008 11:47 pm
by Antonio Linares
Silvio,
Please review source\classes\wbrowse.prg and see how columns are resized
Posted: Mon Jan 07, 2008 1:00 pm
by Silvio
Antonio
i saw you can insert dialog on outlook2003
but i want insert on the right a Xbrowse with a tab (on bottom)
it'is possible to create it ?
Posted: Mon Jan 07, 2008 1:14 pm
by Antonio Linares
Silvio,
Yes, or course.
Is it a MDI or SDI environment ?
Posted: Tue Jan 08, 2008 12:20 am
by Silvio
I wanted make a Mdi
Posted: Tue Jan 08, 2008 12:42 am
by Silvio
i try but it make error
Code: Select all
Error description: Error BASE/1004 Message not found: TXBROWSE:AWND
Called from: tobject.prg => TXBROWSE:ERROR(172)
Called from: tobject.prg => TXBROWSE:MSGNOTFOUND(205)
Called from: tobject.prg => TXBROWSE:AWND(0)
Called from: WINDOW.PRG => TMDIFRAME:SYSCOMMAND(0)
Called from: => TMDIFRAME:HANDLEEVENT(0)
Called from: WINDOW.PRG => _FWH(0)
Called from: test2003.prg => NOGPF(0)
Called from: test2003.prg => WINRUN(167)
Called from: WINDOW.PRG => TMDIFRAME:ACTIVATE(0)
Called from: test2003.prg => MAIN(126)
Code: Select all
// FWH Class TOutLook2003
#include "FiveWin.ch"
#include "Splitter.ch"
#include "xbrowse.ch"
static lExit := .F.
//----------------------------------------------------------------------------//
function Main()
local oWnd, oOutLook2003, oStatusBar, oSplit, cCombo, oRad, nValue := 1
local oFont
local nFor, oBrw
REQUEST DBFCDX
rddsetdefault( "DBFCDX" )
DEFINE WINDOW oWnd TITLE "FWH new Class TOutLook2003 with Xbrowse" MDI // ;
// MENU BuildMenu()
DEFINE OUTLOOK2003 oOutLook2003 OF oWnd ;
PROMPTS "Mail", "Calendar", "Contacts", "" ;
BITMAPS "..\bitmaps\mail.bmp", "..\bitmaps\calendar.bmp", "..\bitmaps\notes.bmp"
oWnd:oLeft = nil // Because the splitter is going to control the resize
@ 1, 2 BUTTON "New" OF oOutLook2003:aDialogs[ 1 ] SIZE 80, 22 ACTION BuildDlg()
@ 3, 2 BUTTON "Edit" OF oOutLook2003:aDialogs[ 1 ] SIZE 80, 22 ACTION MsgInfo( "Edit" )
@ 5, 2 BUTTON "Search" OF oOutLook2003:aDialogs[ 1 ] SIZE 80, 22 ACTION MsgInfo( "Search" )
@ 1, 1 COMBOBOX cCombo ITEMS { "January", "February", "March", "April", "May" } ;
OF oOutLook2003:aDialogs[ 2 ] SIZE 170, 100
DEFINE FONT oFont NAME "Arial" SIZE 0, -10
@ 12, 10 SAY Date() OF oOutLook2003:aDialogs[ 2 ] SIZE 80, 20 FONT oFont
@ 3, 1 RADIO oRad VAR nValue OF oOutLook2003:aDialogs[ 2 ] ;
ITEMS "&Day", "&Week", "&Month" SIZE 100, 20
oRad:SetFont( oFont )
#ifndef __CLIPPER__
DEFINE STATUSBAR oStatusBar PROMPT " FWH Class TOutLook2003" OF oWnd
#else
DEFINE MESSAGE oStatusBar PROMPT " FWH Class TOutLook2003" OF oWnd
#endif
SetParent( oOutLook2003:hWnd, oWnd:hWnd )
oWnd:oClient = nil
/*
##############################################################################
# TXBrowse Demo #
##############################################################################
*/
USE CUSTOMER NEW
INDEX ON field->first to "name"
SET INDEX TO "name"
ORDSETFOCUS( "name" )
GO TOP
oBrw := TXBrowse():New( oWnd:oWndClient )
oBrw:nMarqueeStyle := MARQSTYLE_HIGHLCELL
oBrw:nColDividerStyle := LINESTYLE_BLACK
oBrw:nRowDividerStyle := LINESTYLE_BLACK
oBrw:lColDividerComplete := .t.
oBrw:nHeaderLines := 2
oBrw:nFooterLines := 1
oBrw:nDataLines := 2
oBrw:lFooter := .t.
oBrw:SetRDD()
for nFor := 1 to Fcount()
oBrw:aCols[ nFor ]:cHeader := "Field: " + ltrim( str( nFor ) ) + CRLF + FieldName( nFor )
oBrw:aCols[ nFor ]:cFooter := FieldName( nFor )
oBrw:aCols[ nFor ]:bRClickHeader := {|r,c,f,o| Msginfo("Right click on column header " + o:cHeader, "TXBrowse power") }
oBrw:aCols[ nFor ]:bLClickFooter := {|r,c,f,o| Msginfo("Left click on column footer " + o:cHeader, "TXBrowse power") }
oBrw:aCols[ nFor ]:bRClickFooter := {|r,c,f,o| Msginfo("Right click on column footer " + o:cHeader, "TXBrowse power") }
oBrw:aCols[ nFor ]:blDClickData := {|r,c,f,o| Msginfo("Left double click on column data " + o:cHeader, "TXBrowse power") }
oBrw:aCols[ nFor ]:bRClickData := {|r,c,f,o| Msginfo("Right click on column data " + o:cHeader, "TXBrowse power") }
next
oBrw:CreateFromCode()
oWnd:oWndClient := oBrw
//splitter
@ 0, 191 SPLITTER oSplit ;
VERTICAL _3DLOOK ;
PREVIOUS CONTROLS oOutLook2003 ;
HINDS CONTROLS oWnd:oWndClient ;
SIZE 4, oWnd:nHeight - 70 PIXEL ;
OF oWnd
SetParent( oSplit:hWnd, oWnd:hWnd )
ACTIVATE WINDOW oWnd ;
ON RESIZE oSplit:Adjust() ;
VALID lExit := .T.
return nil
there ie something not run ok
Posted: Tue Jan 08, 2008 6:55 am
by Antonio Linares
Silvio,
If you are going to use a MDI environment, it has no sense to place a browse on top of the main screen. Instead you should use a MDICHILD window.
Please review samples\Test2003.prg
Posted: Tue Jan 08, 2008 9:12 am
by Silvio
I not understand
Posted: Tue Jan 08, 2008 11:45 am
by Antonio Linares
Silvio,
Where are you going to place the OutLook control ?
On the main window or on a MdiChild window ?
Posted: Tue Jan 08, 2008 12:11 pm
by Silvio
sorry I saw...