Setting Dock for a Panel Causes "... Does Not Contain A Definition For 'Windows'

A

Abby Brown

Hi,

Whenever I set the dock style of a control I get "... does not contain a
definition for 'Windows" There are a lot of uses of
"System.Windows.Forms.xxx" but only those that set the dock style yield this
message. What is happening?

Thanks,
Gary
 
J

Jeff Johnson

Whenever I set the dock style of a control I get "... does not contain a
definition for 'Windows" There are a lot of uses of
"System.Windows.Forms.xxx" but only those that set the dock style yield
this message. What is happening?

You're failing to provide us with the full error message, that's what's
happening. I have a guess, but with a full error message I can probably do
much better.
 
A

Abby Brown

Jeff Johnson said:
You're failing to provide us with the full error message, that's what's
happening. I have a guess, but with a full error message I can probably do
much better.

The message

"PDP1.CRTSystem does not contain a definition for 'Windows"

is all I get. On further fiddling, setting .Dock for any control on that
form yields the message. This is an existing form that I'm modifying. None
of the other forms have this problem.

Gary
 
J

Jeff Johnson

The message

"PDP1.CRTSystem does not contain a definition for 'Windows"

is all I get. On further fiddling, setting .Dock for any control on that
form yields the message. This is an existing form that I'm modifying.
None of the other forms have this problem.

Hmmm, sounds like a form behaving badly.... Next question: Are you setting
the Dock property via the designer (the Properties window) or through code?
If code, could you post the line when you're doing this?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top