Click here to Skip to main content
15,887,436 members
Home / Discussions / C#
   

C#

 
AnswerRe: serial port CreateFile in c# Pin
OriginalGriff29-Dec-14 2:28
mveOriginalGriff29-Dec-14 2:28 
GeneralRe: serial port CreateFile in c# Pin
Member 1114321929-Dec-14 2:45
Member 1114321929-Dec-14 2:45 
GeneralRe: serial port CreateFile in c# Pin
Member 1114321929-Dec-14 2:55
Member 1114321929-Dec-14 2:55 
GeneralRe: serial port CreateFile in c# Pin
OriginalGriff29-Dec-14 3:42
mveOriginalGriff29-Dec-14 3:42 
Questionusing SqlConncetion Pin
Jassim Rahma29-Dec-14 1:16
Jassim Rahma29-Dec-14 1:16 
AnswerRe: using SqlConncetion Pin
OriginalGriff29-Dec-14 2:02
mveOriginalGriff29-Dec-14 2:02 
AnswerRe: using SqlConncetion Pin
Dominic Burford30-Dec-14 5:52
professionalDominic Burford30-Dec-14 5:52 
QuestionObj.Orientation structure newbie/intermediate question Pin
BlindNavigator29-Dec-14 0:04
BlindNavigator29-Dec-14 0:04 
Im Making a very simple vehicle renting program as learning task.
This is probably a simple question even if the text is a bit long.

I have made theese simple classes.
Vehicle, VehicleManager, VehicleForm with (Add/Remove buttons)
Customer, CustomerManager, CustomerForm(Add/Remove buttons)

Agreement, AgreementManager, AgreementForm(with Add/Remove buttons
one ComboBox with Customers and
one ComboBox with vehicles
(and 2 datepickers))
In AgreementManager I have 'private List<agreement> _Agreements'

A very simple structure but....
I was planning to remove a customer in CustomerForm.
The problem comes up when I want to remove a customer that has an agreement.
This must be inhibited(Show error/informative message and all that) if the customer is found as a customer in the agreementlist witch resides in the AgreementManager class.

How can I look in this list from 'inside' the Customer form.
I cant just make another agreementamng. object, because making a new one will not have the agreements in it.
How should/can I access methods in AgreementManager from CustomerForm?

Alternatively I could have a boolean _HasAgreement in the Customer objekt, to prevent delete. But that seems like a rather primitive solution now that i am learning to use obejct orientation and ObjectLists and working with managers.

thanks
BlindNavigator
AnswerRe: Obj.Orientation structure newbie/intermediate question Pin
Pete O'Hanlon29-Dec-14 4:45
mvePete O'Hanlon29-Dec-14 4:45 
GeneralRe: Obj.Orientation structure newbie/intermediate question Pin
BlindNavigator29-Dec-14 5:37
BlindNavigator29-Dec-14 5:37 
AnswerRe: Obj.Orientation structure newbie/intermediate question Pin
BillWoodruff29-Dec-14 5:17
professionalBillWoodruff29-Dec-14 5:17 
QuestionWorkFlow Pin
Zeyad Jalil28-Dec-14 20:58
professionalZeyad Jalil28-Dec-14 20:58 
AnswerRe: WorkFlow Pin
Pete O'Hanlon28-Dec-14 21:21
mvePete O'Hanlon28-Dec-14 21:21 
QuestionCreate diagonal in the DevExpress XtraReport Pin
nhanlaptrinh28-Dec-14 1:42
nhanlaptrinh28-Dec-14 1:42 
AnswerRe: Create diagonal in the DevExpress XtraReport Pin
Richard Andrew x6428-Dec-14 10:41
professionalRichard Andrew x6428-Dec-14 10:41 
GeneralRe: Create diagonal in the DevExpress XtraReport Pin
nhanlaptrinh29-Dec-14 3:59
nhanlaptrinh29-Dec-14 3:59 
GeneralRe: Create diagonal in the DevExpress XtraReport Pin
Pete O'Hanlon29-Dec-14 4:38
mvePete O'Hanlon29-Dec-14 4:38 
GeneralRe: Create diagonal in the DevExpress XtraReport Pin
nhanlaptrinh29-Dec-14 17:33
nhanlaptrinh29-Dec-14 17:33 
Questionwindows service to execute ms sql qurey Pin
Member 1129047526-Dec-14 19:25
Member 1129047526-Dec-14 19:25 
AnswerRe: windows service to execute ms sql qurey Pin
Garth J Lancaster26-Dec-14 19:39
professionalGarth J Lancaster26-Dec-14 19:39 
QuestionCan anyone give me advice on nested loops? Pin
Member 1133710826-Dec-14 16:29
Member 1133710826-Dec-14 16:29 
GeneralRe: Can anyone give me advice on nested loops? Pin
PIEBALDconsult26-Dec-14 17:18
mvePIEBALDconsult26-Dec-14 17:18 
AnswerRe: Can anyone give me advice on nested loops? Pin
tarun199126-Dec-14 19:08
professionaltarun199126-Dec-14 19:08 
AnswerRe: Can anyone give me advice on nested loops? Pin
BillWoodruff26-Dec-14 20:51
professionalBillWoodruff26-Dec-14 20:51 
GeneralRe: Can anyone give me advice on nested loops? Pin
Member 1133710826-Dec-14 21:14
Member 1133710826-Dec-14 21:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.