thats because name is not a property, but an attribute. look in the
controlds attribute collection, and you will find it. note sure why you wnat
to play with though, .net needs it to, so it can identify the control the
postback data goes with (i believe with the file control, it will override
the name anyway with the munged id).
if you are tryimg to set the filename, that would be the value attribute,
but its read only because the browser will ignore it (security).
-- bruce (sqlwork.com)
"JackO" <Ja***@discussions.microsoft.com> wrote in message
news:AB**********************************@microsof t.com...
I am still having no luck getting past the error. The html for the object
is:
<INPUT id="File1" style="Z-INDEX: 127; LEFT: 384px; WIDTH: 474px;
POSITION:
absolute; TOP: 552px; HEIGHT: 22px"
type="file" size="59" name="myfile" runat="server">
"Mr Newbie" wrote:
right click, and choose runat server
"JackO" <Ja***@discussions.microsoft.com> wrote in message
news:7B**********************************@microsof t.com... >I have tried to use the file field HTML object in my code buy I cannot
>get
> the code to recognize the name property ("myfile") of the object. It
> says:
> Name 'myfile' not declared. I have set the property Name to 'myfile'
> but
> I
> am still getting the error in my code.