Click here to Skip to main content
15,913,233 members

The Weird and The Wonderful

   

The Weird and The Wonderful forum is a place to post Coding Horrors, Worst Practices, and the occasional flash of brilliance.

We all come across code that simply boggles the mind. Lazy kludges, embarrassing mistakes, horrid workarounds and developers just not quite getting it. And then somedays we come across - or write - the truly sublime.

Post your Best, your worst, and your most interesting. But please - no programming questions . This forum is purely for amusement and discussions on code snippets. All actual programming questions will be removed.

 
GeneralRe: Aaaarg....use the namespace Pin
BillW3315-Jun-12 4:19
professionalBillW3315-Jun-12 4:19 
GeneralRe: Aaaarg....use the namespace Pin
Eddy Vluggen15-Jun-12 5:17
professionalEddy Vluggen15-Jun-12 5:17 
GeneralRe: Aaaarg....use the namespace Pin
PIEBALDconsult12-Jun-12 4:49
mvePIEBALDconsult12-Jun-12 4:49 
GeneralRe: Aaaarg....use the namespace Pin
Eddy Vluggen12-Jun-12 9:00
professionalEddy Vluggen12-Jun-12 9:00 
GeneralRe: Aaaarg....use the namespace Pin
PIEBALDconsult12-Jun-12 9:45
mvePIEBALDconsult12-Jun-12 9:45 
GeneralRe: Aaaarg....use the namespace Pin
Eddy Vluggen12-Jun-12 9:59
professionalEddy Vluggen12-Jun-12 9:59 
GeneralRe: Aaaarg....use the namespace Pin
Nagy Vilmos12-Jun-12 23:10
professionalNagy Vilmos12-Jun-12 23:10 
QuestionRe: Aaaarg....use the namespace [modified] Pin
Eddy Vluggen13-Jun-12 1:30
professionalEddy Vluggen13-Jun-12 1:30 
Copy/paste is often an invitation not to check what you just pasted. Your example might be a nice example on why we introduced the DRY principle, but being this abstract, one can't be sure.

But no, I'd not be bloating my code for the sake of "easy copies". If it's that re-usable, I'll take the time to make it a snippet.

--edit;
Nagy Vilmos wrote:
No, you prefix the member if a class with this to prevent any ambiguity

..the same kind of ambiguity that you have if you don't use the full name against a type, including it's namespace. Do you have global variables that clash with the names of the property/method that you're calling from the current object that you need to specify explicitly that you need the property/method from "this" object?
Bastard Programmer from Hell Suspicious | :suss:


modified 15-Jun-12 11:22am.

GeneralRe: Aaaarg....use the namespace Pin
PIEBALDconsult14-Jun-12 4:20
mvePIEBALDconsult14-Jun-12 4:20 
GeneralRe: Aaaarg....use the namespace Pin
PIEBALDconsult12-Jun-12 3:51
mvePIEBALDconsult12-Jun-12 3:51 
GeneralRe: Aaaarg....use the namespace Pin
Sentenryu12-Jun-12 4:41
Sentenryu12-Jun-12 4:41 
GeneralRe: Aaaarg....use the namespace Pin
PIEBALDconsult12-Jun-12 4:50
mvePIEBALDconsult12-Jun-12 4:50 
GeneralRe: Aaaarg....use the namespace Pin
Sentenryu12-Jun-12 5:12
Sentenryu12-Jun-12 5:12 
GeneralRe: Aaaarg....use the namespace Pin
PIEBALDconsult12-Jun-12 8:23
mvePIEBALDconsult12-Jun-12 8:23 
GeneralRe: Aaaarg....use the namespace Pin
Sentenryu12-Jun-12 8:55
Sentenryu12-Jun-12 8:55 
GeneralRe: Aaaarg....use the namespace Pin
thatraja14-Jun-12 23:00
professionalthatraja14-Jun-12 23:00 
GeneralRe: Aaaarg....use the namespace Pin
Sander Rossel15-Jun-12 13:04
professionalSander Rossel15-Jun-12 13:04 
GeneralRe: Aaaarg....use the namespace Pin
Edward Giles22-Jul-12 12:39
Edward Giles22-Jul-12 12:39 
GeneralRe: Aaaarg....use the namespace Pin
Sander Rossel22-Jul-12 20:10
professionalSander Rossel22-Jul-12 20:10 
GeneralWhat can you do when you have different timetable Pin
Mohibur Rashid10-Jun-12 20:52
professionalMohibur Rashid10-Jun-12 20:52 
GeneralRe: What can you do when you have different timetable Pin
RobCroll11-Jun-12 13:38
RobCroll11-Jun-12 13:38 
GeneralRe: What can you do when you have different timetable Pin
Ingo11-Jun-12 21:37
Ingo11-Jun-12 21:37 
GeneralRe: What can you do when you have different timetable Pin
Mohibur Rashid11-Jun-12 22:59
professionalMohibur Rashid11-Jun-12 22:59 
GeneralRe: What can you do when you have different timetable Pin
Ingo12-Jun-12 3:25
Ingo12-Jun-12 3:25 
GeneralBridging ObjectDataSource to Entity Framework with a Generic BusinessObject Pin
Woppelmann P9-Jun-12 2:32
Woppelmann P9-Jun-12 2:32 

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.