Click here to Skip to main content
15,915,611 members
Home / Discussions / C#
   

C#

 
AnswerRe: Pattern matching Hashtable keys? Pin
Lars Niedziolka2-Aug-05 13:20
Lars Niedziolka2-Aug-05 13:20 
GeneralRegular expression help - end of text Pin
Luis Alonso Ramos2-Aug-05 9:05
Luis Alonso Ramos2-Aug-05 9:05 
GeneralRe: Regular expression help - end of text Pin
Guffa2-Aug-05 9:15
Guffa2-Aug-05 9:15 
GeneralRe: Regular expression help - end of text Pin
Luis Alonso Ramos2-Aug-05 9:21
Luis Alonso Ramos2-Aug-05 9:21 
GeneralRe: Regular expression help - end of text Pin
Luis Alonso Ramos2-Aug-05 9:24
Luis Alonso Ramos2-Aug-05 9:24 
GeneralRe: Regular expression help - end of text Pin
Guffa2-Aug-05 9:49
Guffa2-Aug-05 9:49 
GeneralRe: Regular expression help - end of text Pin
Luis Alonso Ramos2-Aug-05 10:00
Luis Alonso Ramos2-Aug-05 10:00 
Questionstatic class for database access? Pin
theStorminMormon2-Aug-05 8:58
theStorminMormon2-Aug-05 8:58 
This is a quick question. Is it possible to do ADO.NET access from a static class? I'm guessing that it's not, because if I were to create a static class (say DBController) and then attempt to use it to access my database (eg with the method DBController.getNewClients) then the method (getNewClients) would have to create non-static instances of objects (ie the connection object).

From Java I know that if you try to reference non-static methods from static methods you get an error. Does this hold true for C# as well? Or would I be able to create a static DBController class that I could then use on any of my forms to access my database?

If that's not possible, then is it possible to pass a reference to my DBController to every form that's going to need access to it? How would I do that?

These may be dumb questions, but I'm the only tech guy in my company and my degree is in mathematics. Any help would be EXTREMELY appreciated.

It's lonely, oh so lonely, being the only tech guy in my company.
AnswerRe: static class for database access? Pin
Guffa2-Aug-05 9:11
Guffa2-Aug-05 9:11 
GeneralRe: static class for database access? Pin
theStorminMormon2-Aug-05 9:14
theStorminMormon2-Aug-05 9:14 
GeneralRe: static class for database access? Pin
Luis Alonso Ramos2-Aug-05 9:32
Luis Alonso Ramos2-Aug-05 9:32 
GeneralRe: static class for database access? Pin
Guffa2-Aug-05 9:36
Guffa2-Aug-05 9:36 
AnswerRe: static class for database access? Pin
Luis Alonso Ramos2-Aug-05 9:13
Luis Alonso Ramos2-Aug-05 9:13 
GeneralRe: static class for database access? Pin
theStorminMormon2-Aug-05 9:16
theStorminMormon2-Aug-05 9:16 
GeneralRe: static class for database access? Pin
Luis Alonso Ramos2-Aug-05 9:26
Luis Alonso Ramos2-Aug-05 9:26 
GeneralEmulate a twain interface Pin
Oliver Lange2-Aug-05 8:25
Oliver Lange2-Aug-05 8:25 
GeneralSupressing Security Error Dialog Pin
RB@Emphasys2-Aug-05 7:53
RB@Emphasys2-Aug-05 7:53 
GeneralRe: Supressing Security Error Dialog Pin
mav.northwind2-Aug-05 20:06
mav.northwind2-Aug-05 20:06 
GeneralRe: Supressing Security Error Dialog Pin
RB@Emphasys3-Aug-05 3:57
RB@Emphasys3-Aug-05 3:57 
GeneralRe: Supressing Security Error Dialog Pin
mav.northwind3-Aug-05 7:42
mav.northwind3-Aug-05 7:42 
GeneralCapturing The Build Date Into Code Pin
bneacetp2-Aug-05 7:22
bneacetp2-Aug-05 7:22 
GeneralRe: Capturing The Build Date Into Code Pin
hamster12-Aug-05 11:22
hamster12-Aug-05 11:22 
GeneralRe: Capturing The Build Date Into Code Pin
bneacetp2-Aug-05 14:13
bneacetp2-Aug-05 14:13 
GeneralRe: Capturing The Build Date Into Code Pin
hamster13-Aug-05 8:21
hamster13-Aug-05 8:21 
GeneralReordering DOCKED controls Pin
Radgar2-Aug-05 7:16
Radgar2-Aug-05 7:16 

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.