[EMAIL PROTECTED] wrote:
1]Which Identifier is unknown in your  uCrUtil-Unit
2]Is uCrUtil a DataModule?
3]The error will prpbably have to do with the declarations of your
procedures and not with the Code itself,
4]so better check that out.
5] The Declaration of  RemoveBkMaster looks as if it was an
Event-Proc, but the "ClassName." is missing.
6]Where comes the "Sender:tObject" parameter from?
[[R]]
1=Self
2= No  , udmMCr  is the  DataModule
3= yes, but do not understand it works in one unit and not in the unit
it is declared
4= like to do that but do not know how/ where 
5= yes 
procedure RemoveBkMaster(Sender: TObject);
tried to "fiddle"  with  class  but  it was just trial and error, due
to a lack of knowledge.
6= I copycat that from the many procedures i see declared in apps and
it worked.
[by the way:  the abundance of underscores is to help me identify the
placements of dots , as I can not see the dots very well on the screen]

[part of the unit where the proc is declared]
============================================
unit uCrUtil;    // unit without a form
interface
 uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms,
Dialogs,
  ADODB, Db;

type
TCrUtil_= class(TObject)
end;

  procedure RemoveBkMaster(Sender: TObject);
  procedure SetBkMaster(Sender: TObject);
  procedure MD_TrDate_TrNr(Sender: TObject);
  procedure MD_TrNr_BkNr(Sender: TObject);
  procedure A(Sender: TObject);

  var CrUtil_ : TCrUtil_;
implementation

uses udmMCr;

{[remove MD BkNr with TrNr ]}
procedure RemoveBkMaster(Sender: TObject);
begin
dmMCR_.tBK_.Active := False;
dmMCR_.tBK_.MasterSource := nil ;
dmMCR_.tBK_.MasterFields :=  '';
dmMCR_.tBK_.Active := True;
dmMCR_.tTRNR_.Active := False;
dmMCR_.tTRNR_.MasterSource := nil ;
dmMCR_.tTRNR_.MasterFields :=  '';
dmMCR_.tTRNR_.Active := True;
end;//* procedure RemoveBkMaster

procedure A(Sender: TObject);
begin
RemoveBkMaster(Self);
<some code>
end;

this gives the UI Self

part of another unit where the proc is used
===============================
unit ufMTr;   // unit with a form
Interface
uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms,
Dialogs,
  StdCtrls, ExtCtrls, Menus, Grids, DBGrids, DBCtrls, Mask,ADODB,Db,
  ComCtrls;

type
  TfMTr_ = class(TForm)
    MainMenu1: TMainMenu;
< components, proc and func delcarations>
end;
var
  fMTr_: TfMTr_;
implementation
uses udmMCr, uCrUtil, ufBookYear, ufUtilities, ufStrings;
{$R *.DFM}

procedure TfMTr_.DbtnRecordCountBk_Click(Sender: TObject);
var iRec : integer;
begin
RemoveBkMaster(self);
iRec := dmMCr_.tBK_.RecordCount;
DlblRecordCountBk_.Caption := 'Number of bookings: ' + IntToStr(iRec);
SetBkMaster(self) ;
end;

[in this unit the proc works]
===================
I have 3 tables [tTRDATE_ ; tTRNR_ ; tBK_ in a masterdetail relation
and have to remove this relation to be able to see  and manipulate all
the records in tBK_ 
I am thankfull Bob for your intrest to help me. 
Jan [nickname] Welmers;   
Aruba[A tiny country in the Caribbean that is under heavy attack from
some American media]








------------------------ Yahoo! Groups Sponsor --------------------~--> 
Most low income households are not online. Help bridge the digital divide today!
http://us.click.yahoo.com/I258zB/QnQLAA/TtwFAA/i7folB/TM
--------------------------------------------------------------------~-> 

-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED] 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/delphi-en/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to