Dynamic properties..

wyrd

Senior Contributor
Joined
Aug 23, 2002
Messages
1,405
Location
California
I was going to start toying around with dynamic properties in my application but came across some funkyness...

- There was no Program.exe.config file in my program directory, and I saw no option to create one, so I went ahead and create an xml file and called it Program.exe.config.
- System.Configuration exists, but System.ConfigurationSettings does not.

Despite these oddities, I went ahead and tried to run my app anyway, and got this error:

C:\Documents and Settings\Administrator\My Documents\vp\Inventory\Inventory.cs(39): The type or namespace name 'ConfigurationSettings' does not exist in the class or namespace 'System' (are you missing an assembly reference?)

I got a REALLY weird error the first time I tried to run the app, saying a control I was referencing was in use or something *shrug*

Anyway, so I went to References/Add Reference and scrolled down to find System.ConfigurationSettings.dll. Nothing there, the only thing I found was System.Configuration.Install.dll.

What am I doing wrong?
 
System.Configuration.ConfigurationSettings is the full path of the class, it's in System.dll.
 
Heh, I came back to post that I just found that out myself. In anycase, now I'm getting a new error:
The ConnectionString property has not been initialized.

EDIT (deleted old info below this point):
I got it working, nevermind. :) It was in the wrong folder. I assumed (silly me) that it would automatically copy/paste the .config file to the correct bin folder when it compiled.
 
Last edited:
Back
Top