473,395 Members | 1,856 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

IIS programmatic administration question

Hi,

In my recent posts, I asked something related with how to create web sites
programmatically. With aid of some people (especially Kristofer) I have
passed those steps.

However, I still have some problems. After creating the site, I need to
change some properties like host header, port etc. One of these properties
is LogExtFileFlags. The creation of the web sites has a pattern, so all
sites will have the same values for some properties. I intend to set these
properties exactly how they appear in the metabase entries of the previously
(and manually) created sites. Most of them work perfectly but I'm stuck with
LogExtFileFlags field. I set the value like this:

newSite.Properties["LogExtFileFlags"][0]="LogExtFileDate |
LogExtFileTime | LogExtFileClientIp | LogExtFileUserName |
LogExtFileMethod | LogExtFileUriStem | LogExtFileUriQuery |
LogExtFileHttpStatus | LogExtFileBytesSent | LogExtFileUserAgent |
LogExtFileReferer | LogExtFileProtocolVersion";

But at that very line of code I get an exception (I'm using C#). Is there a
trick setting the property? Or should I paste the error message here?

Thanks
Nov 16 '05 #1
1 1902
Hello,

As per the documentation, LogExtFileFlags[1] is expecting a DWORD[2], and
you are giving it a string. This will cause an exception.

[1]
http://msdn.microsoft.com/library/de...tfileflags.asp
[2] DWORD is a 32-bit unsigned integer,
http://msdn.microsoft.com/library/de...data_types.asp

--
Regards,
Kristofer Gafvert
http://www.ilopia.com
"Sıfırıncı Murat" <@> wrote in message
news:%2****************@TK2MSFTNGP14.phx.gbl...
Hi,

In my recent posts, I asked something related with how to create web sites
programmatically. With aid of some people (especially Kristofer) I have
passed those steps.

However, I still have some problems. After creating the site, I need to
change some properties like host header, port etc. One of these properties
is LogExtFileFlags. The creation of the web sites has a pattern, so all
sites will have the same values for some properties. I intend to set these
properties exactly how they appear in the metabase entries of the previously (and manually) created sites. Most of them work perfectly but I'm stuck with LogExtFileFlags field. I set the value like this:

newSite.Properties["LogExtFileFlags"][0]="LogExtFileDate |
LogExtFileTime | LogExtFileClientIp | LogExtFileUserName |
LogExtFileMethod | LogExtFileUriStem | LogExtFileUriQuery |
LogExtFileHttpStatus | LogExtFileBytesSent | LogExtFileUserAgent |
LogExtFileReferer | LogExtFileProtocolVersion";

But at that very line of code I get an exception (I'm using C#). Is there a trick setting the property? Or should I paste the error message here?

Thanks

Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: hamido | last post by:
Hi I am very-very new in Pyton langguage In my next project I will promote Python / Perl /Shell Programming I enjoy and intensively comparing python and Perl in term of networking and system...
2
by: RickatGoIn | last post by:
We are currently using the security features included with latest .NET 2.0 Framework (v2.0.50215), including the Web Site Administration Tool. The only problem we have encountered thus far is...
1
by: dave | last post by:
I am trying to use the Personal Web Site Starter Kit. I am planning on showing my class how easy it is to create a website in VS 2005. Only I am finding it not to be so easy. I am following the...
1
by: Fernando Ronci | last post by:
Hi, Does anybody know the object model of Windows 98 DUN (Dial-Up Networking) ? My goal is to write a short console C# program to bring up and hang up the modem connection. If such tool exists...
16
by: jblankenburg | last post by:
I am trying to deploy a simple web application to my client's production server, but it's not clear to me how MS planned on having the Security users managed without Studio. Certainly someone...
6
by: Blaine Manyluk | last post by:
I have a very unusual request. I need to be able to generate reports and save them as TIF files, with full programmatic control. The application will provide the filenames. Each page of the...
8
by: Kirk | last post by:
Hello, I am a somewhat experienced VS 2005 user who is trying to us the ASP.NET Web Site Administration Tool for the first time. I have experimented with it on my local IIS and it seems to be...
3
by: matias.cornejo | last post by:
I have a problem to startup de DB2 Admin. I read meny documentation in internet and nothing work, anybody know something??. I have DB2 UDB V8 fixpack 14 and AIX 5.2 x134 db2admin start SQL4409W...
0
by: Toralf Kirsten | last post by:
Hi all, we have installed DB2 V9.5 Trial on a Fedora 6 Linux box (32bit). Since the box is included in a NIS we have manually created db2 users db2inst, dasusr and db2fenc on this box (not in the...
9
by: Axxe | last post by:
I have searched high and low for cogent, well-explained coding to complete a project on which I have spent six months of work. I stumbled across something on this site that is close to what I...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.