serialize a property of a collection
Hi,
I have a collection, which is a property of a class:
public class PostcodeCollection : CollectionBase
{
// ...collection specific properties
[XmlAttribute("Total")]
public int Total
{
get { return List.Count; }
set {}
}
}
The main class is:
[XmlRoot("PostCodes" )]
public class PostcodeReport
{
// ..other properties
[XmlArray("Updated")]
[XmlArrayItem(typeof(PostCodeLine), ElementName="PostCode")]
public PostcodeCollection Updated
{
get { return this.updated; }
}
}
I want to add the "Total" property as an attribute to "Updated" node.
Using "XmlAttribute" on the property, doesn't do the trick.
This is how the xml must look like:
<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type='text/xsl' href='PostcodeUpdates.xslt'?>
<PostCodes Generated="03-05-2007, 17:50">
<Added />
<Updated Total="23" >
<PostCode District="2031"... />
</Updated>
</PostCodes>
How can i do this?
Many thanks,
Daniel Tag: HatchBrush in WPF Tag: 129563
Framework, ProtocolType.Icmp and VISTA
Hi all,
I did not find any other suitable newsgroup for my question, so I took this
one here.
I have a little project which has some kind of a network scanning wizard, to
find local area computers and access them using the Eventlog or simple
pinging them.
1-2 years ago I wrote some code to manually handle pinging of other
machines, which worked very fine - till Vista ;)
My application is running with highest privileges, but I am not able to get
any ping responses from other machines expect my own local machine. Are there
any new security methods which prevent an .net application to use ICMP?
--
www.adiscon.com Tag: HatchBrush in WPF Tag: 129562
MSBuild Zip taks
Hi All,
I am new to VSTS and MS Build.
I want to do a Zip (As in NANT) in MSBUILD proj file.
Can anyone please help me in this.
Also i want to create labels in Team Foundation Server (for all build
files) before building it.
Thanks.
Regards,
Shikhar Tag: HatchBrush in WPF Tag: 129561
2.0: "Debugging failed because integrated Windows authentication in not enabled"
Hello,
I am writing my first ASP.NET application (I use .NET 2.0, Visual Web
Developer 2005 Express Edition and SQL Server 2005 Express Edition).
The application builds successfully but when I try to start debugging from
Visual Web Developer I receive message box:
Unable to start debugging on the web server. Debugging failed because
integrated Windows authentication in not enabled.
What should I do to solve the problem?
Please help.
Thank you
/RAM/ Tag: HatchBrush in WPF Tag: 129560
Setting required framework version
Hello everyone,
I'm experimenting running side by side fw versions on a test box. One thing
i do not understand is how it is determined the version to use when running
an app. I wrote a very small proggy that just displays the version of the
framework it is run by. If i use vs2003 (with fw1.1) it displays 1.1.4322
which is correct, but HOW does it determine the version to use? Is there a
way to force the version used? How?
Thanx in advance
Paolo Tag: HatchBrush in WPF Tag: 129559
Problem : 2 different ASP .Net running in one IIS
Hi all,
I am having a problem with different version of website.
One website written in Dot Net I and another one usig Dot Net II.
The 1st website using Dot Net I had successfully run for few years.
Until, I am configuring another website in same IIS whcih using Dot Net II.
Once I start the service, the 1st website (dot Net I) which previous well
run suddently unAvailable.
Kindly, please help me. Anything i can configure with my IIs 6.0 or my
server 2003 ?
Need help
--
masita Tag: HatchBrush in WPF Tag: 129557
laptop
hi, Nigel
The laptop that I want to have, has Windows Media Center. I was reading on
net that the main differance between
Win XP Pro and WMC is that WMC has 'joining a domain capability disabled'.
.---------------
Here is an excerpt:
Media Center is essentially just an application that's
installed on top of the XP Pro operating system.
Other than two specific networking features that are
disabled (domain joining after installation, and
cached credentials), MCE 2005 _IS_ XP Pro.
---------------
Questions to IT:
1. What does 'joining a domain capability disabled' mean, does it mean that
i cant be on the office network.
2. Ideally i need XP pro installed where do they get their machines from.
regards,
irfan Tag: HatchBrush in WPF Tag: 129555
What is the significance of link.exe.config and cl.exe.config files in VS2003
Hi,
What is the usage of the files link.exe.config and cl.exe.config when
compiling the code with cl.exe. ?
Does it affect only .NET code?
Does if have any effect on unmanaged C++ code ?
Thanks,
WN Tag: HatchBrush in WPF Tag: 129552
How to find the Parent Thread
Is there a way to find the Parent Thread that spawned a certain Thread?
For example:
Thread a
Spawns Thread b
From inside Thread b's process, can I get to Thread a's TLS
(Thread Local Storage)? Tag: HatchBrush in WPF Tag: 129546
How to get a mini dump?
On some client's computer the XmlDocument.Save() fails with some weird
internal error such as:
==============
Exception : System.IO.IOException
Message : Unknown error "-1".
Source : mscorlib
Help :
Stack :
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess
access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize,
FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean
bFromProxy)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess
access, FileShare share)
at System.Xml.XmlDocument.Save(String filename)
===============
I have reported such a problem to microsoft and they just told me they need
more information such as a mini dump.
how do I do one? Tag: HatchBrush in WPF Tag: 129545
Execution of managed code upon Ctrl-C or some other "signal" to die?
Is there a way to execute any vb.net code when some type of signal to
die is given?
I found this reference, which may work
http://groups.google.com/group/microsoft.public.dotnet.framework/browse_thread/thread/a85b02458bde3bdb/6941695b36d28b8c?lnk=st&q=Ctrl%2BC+VB.NET&rnum=7#6941695b36d28b8c
But I was looking for a more general solution.
Thanks.
Jay Cox Tag: HatchBrush in WPF Tag: 129543
Circular References in the .NET Framework
Today I stumbled over the following: There are cirular references in the .NET Framework. For example, System.Xml references System.Configuration and System.Configuration references System.Xml. See the following: http://www.stephan-brenner.com/blog/wp-content/uploads/2007/05/circularreferences.png
There are a lot of that artifacts in the framework and I'm wondering why? And how does Microsoft manage to build this? Tag: HatchBrush in WPF Tag: 129542
Are they the same day?
Hello, friends,
What is the best way to test if two date values are the same day (same hour)
or not in c#.net?
As you know, in VB6, we have a fuction DateDiff("d", date1, date2). Do we
have a similar one in .net?
Thanks. Tag: HatchBrush in WPF Tag: 129538
VB 2005 Serial Port Close() Method
Hey all,
I am having problems with the close method of the serial port class in
vb 2005. I have a button on a form that calls the Close() method, but
every now and then the program freezes. I have go into task manager to
end the process to get it to stop.
Just before I call the close() method, I discard the TX/RX buffers and
RemoveHandler my handles to DataReceived and ErrorReceived.
Any insight? Thanks,
Steve P Tag: HatchBrush in WPF Tag: 129535
DataTable.Merge()
I'm a little confused about DataTable.Merge(). I have two DataTable
objects with the same structure - dtOrig and dtCurrent. The end result
I'm trying to achieve is to get all the rows in dtCurrent that are in
some way different from the corresponding rows in dtOrig so those new/
modified/deleted rows can be processed. My idea was to use
dtOrig.Merge(dtCurrent), and then call dtOrig.GetChanges(). But what I
found is that when the preserveChanges Merge() parameter is
'false' (or not supplied) the values in dtOrig do get updated, but the
RowState stays 'Unchanged'. When preserveChanges is 'true' then the
RowState for all rows becomes 'Modified' but the values in dtOrig are
NOT actually updated! What am I missing here? Is there a better way to
go about this? Thanks. Tag: HatchBrush in WPF Tag: 129530
SslStream caching and Vista:
Hi.
When my client program runs under XP and calls a server (solaris in
this case) via an SslStream all is well. The client may make multiple
calls and multiple authentication calls and be fine.
Running the client under Vista, when the second authentication call
is
made it returns the following SSPI error:
"A call to the SSPI failed, see inner exception"
which reads
"the Local Security Authority cannot be contacted"
Well that was pretty mystifying so I looked at what was going on with
ethereal. Apparently, on the second authentication go-round the
client
asks the server to re-use a session Id. The client responds and then
Vista rejects a re-used session Id (even though it asked to do that).
What I have found out is that the .net framework seems to cache
SslStream sessions automatically, I have not found any way to turn
this off for Vista - any ideas on how to do this?
Thanks
_Randal Tag: HatchBrush in WPF Tag: 129529
Getting 3.0 Facts Straight
Ok.
If anybody has a url , that'd be great.
My IT Department is asking for the exact lowdown on 3.0, from a machine/OS
perspective.
3.0 projects can be
developed on
a. XP SP2
b. Vista
c. ( I guess 2003Server, but how uses that as their personal OS)
and deployed on
2003Server
(some future version of Vista)
Oh man. I know I screwed that up somehow.
I found a few blogs, but would like group help with the concrete facts with
this one. Tag: HatchBrush in WPF Tag: 129528
case values in switch statement?
Hi, guys,
I have a switch statement like the follows in a KeyPress event:
switch (e.KeyChar)
{
case '0' - '9':
case 'A' - 'Z':
break;
default:
break;
}
Of course, this did not work. But, how can I do such kind of case values
which are in a range without writing each case value one by one? Thanks a lot. Tag: HatchBrush in WPF Tag: 129521
win32 error
i've created a console application whcih reads different file formats and
scans for some for words....
the application builds fine and executes finely..but sometimes, the exe
automatically becomes 0kb and gives me this error
<Application.exe> is not a valid win32 application..
can anyone help me out in fixing this issue... Tag: HatchBrush in WPF Tag: 129516
win32 error
i've created a console application whcih reads different file formats and
scans for some for words....
the application builds fine and executes finely..but sometimes, the exe
automatically becomes 0kb and gives me this error
<Application.exe> is not a valid win32 application..
can anyone help me out in fixing this issue... Tag: HatchBrush in WPF Tag: 129515
Advanced WPF text
How to creat text on path? Can I creat non regtagular text box? How to
control text tracking, kerning and leading? Thanks.
Jim Tag: HatchBrush in WPF Tag: 129514
checkboxlist query
I've used a checkboxlist control on my form..
i'm populating values dynamically at runtime to this list..
but when i do it, the checkboxes so added are remaining unchecked...
but I want a newly added item to be checked by default...
how do i do it? any good samples... Tag: HatchBrush in WPF Tag: 129513
Overriding "OnXXX" versus adding event handler
Okay, this has come up in the past but I haven't seen anything that I
would call a good, solid general rule.
The question applies more generally, but I'm going to ask in the context
of a Control. How does one decide whether to write an "override" method
to an event and when to simply add an event handler for that event?
For example, you can either write a new OnPaint override, or you can
register a delegate that the Control's base OnPaint method will execute.
My current thought is that when you are not inheriting from the base
class, you register a delegate (duh, since you obviously have no way to
override the method in that case), and when you are inheriting from the
base class, you override the method (the main reason here being that if
you're inheriting from the base class, you want your new functionality to
always work, rather than relying on your delegate remaining in the event
handler list).
In other words, override when you can, add an event handler if you can't.
Is it really as simple as that? Or are there other factors I should be
considering?
Many thanks in advance for the wisdom of those who have gone down this
road before me. :)
Pete Tag: HatchBrush in WPF Tag: 129495
convert an object to string and back (in a culture independent fashion)
to store user preference in our application we have an 'hand written' XML
file. (as opposed to XmlSerializer written one, which crash sometimes, on
some user's computer, for some unknown reason.. but I'm digressing)
In this XML file I store object value, which I convert to string (when
writting) and from string (when reading) with a couple of simple function
which (should) do a reversible conversion (using TypeConverter) (functions
below).
Unfortunately, for some Enum, (namely System.Windows.Forms.Keys) I got a
culture dependent string, even though I specify CultureInfo.InvariantCulture
as an argument in my ConvertXXX method with the TypeConverter. Even using
'new CultureInfo("en")' do not fix this behavior.
Any tip on how to fix these function (below) so they provide a truly culture
independent reversible object=>string=>object mechanism?
===================================================
public static bool TryGetStringValue<T>(object val, out string ret)
{
if (val is string)
{
ret = (string)val;
return true;
}
TypeConverter tc = TypeDescriptor.GetConverter(typeof(T));
if (tc == null)
{
ret = val.ToString();
return false;
}
try
{
ret = tc.ConvertToString(null, CultureInfo.InvariantCulture, val);
return true;
}
catch (ArgumentException) { }
catch (NotSupportedException) { }
ret = val.ToString();
return false;
}
public static bool TryGetTValue<T>(object val, out T tval)
{
if (val is T)
{
tval = (T)val;
return true;
}
TypeConverter tc = TypeDescriptor.GetConverter(typeof(T));
if (tc == null)
{
tval = default(T);
return false;
}
if (!tc.IsValid(val))
{
tval = default(T);
return false;
}
try
{
tval = (T)tc.ConvertFrom(null, CultureInfo.InvariantCulture, val);
return true;
}
catch (ArgumentException) { }
catch (NotSupportedException) { }
tval = default(T);
return false;
}
=================================================== Tag: HatchBrush in WPF Tag: 129493
Windows Workflow - What basic tutorials? What's going on here?
I thought I was an experienced programmer but I'm looking at the beginning
WWF tutorial (Simple Expense Report) and I'm baffled. I feel like I don't
know how to even begin reading this. I thought this was supposed to be
interactive coding. Since when do we cut and paste into a project file? Is
this just a temporary Beta thing? Why this constant use of command prompts?
Also I have downloaded other samples onto my machine and none of them seem
to work correctly. In the OrderingStateMachine demo, I get the error
message: "The project file <C:\data\Visual Studio
2005\OrderingStateMachine\VB\OrderWorkFlows\OrderWorkFlows.vbproj cannot be
opened. The project type is not supported by this installation." ??????
Could someone direct me to a more user-friendly, comprehensible tutorial? Tag: HatchBrush in WPF Tag: 129485
Truly cross platform?
The thread bellow titled 'Determining if two paths are the same' brings to
mind some of the first 'things' I had heard way back when DotNet started. It
was going to be the panacea of cross platform development.
I am asking the question here of the group to find out if everyone (anyone)
thinks this has come (or is coming) to fruition.
I think that perhaps it has gone a long way towards making it simpler to
communicate between platforms but I am not sure if the framework itself has
actually made it to the cross platform development hall of fame just yet.
What do you folks think is the possibility of truly doing that? Looking at
the mono project and actually trying to use it in some productive manner has
showed me that this is far off. Just trying to get it working along with GDK
and Mono-develop on a fedora Core 6 system was an exercise in futility.
While I can understand what drives the open source community I honestly can't
understand what keeps it going when stuff is that hard. I can install VS.NET
2005 and be developing in an hour. Hello world in Mono-develop never came to
life. But, I digress and that is another rant for another message area.
So, what are your thoughts and ideas? Tag: HatchBrush in WPF Tag: 129483
Locking Desktop and Threading Issue
Hi, I have an application that displays forms on the users desktop,
what I am doing with it is having a SystemEvents
SessionSwitchEventHandler to capture the lock of the desktop, I would
like to kill the forms when this event is captured, that piece is
fine, but I would like to sleep the app until the
SessionSwitchReason.SessionUnlock happens then I can wake it again and
go the correct part of the code? Can I wake a sleeping thread, or
should I not sleep the thread at all, is there another way to get the
thread to sleep or hibernate and then wake up?
Thanks
Eamonn Tag: HatchBrush in WPF Tag: 129478
.Net Windows Service ...data access problem
Hi,
I am writing a .NET windows Service that will access the database every 10
minutes. When the service calls the function in the business services layer
which in turn calls the correponding function in data access layer, this DAL
function fails. The reason 'apparently' being that the it can not read the
connection string information and hence can not create the database
connection.
Please note that that I am using enterprise library. All the projects
representing business service layer, DAL, Model, Web UI and also the the
windows service project are all in the same solution.
Can anyone tell me what should I do to get around this problem.
Thanks
-Sam Tag: HatchBrush in WPF Tag: 129470
Installation problem - MSDN Libs for VS2005
I'm trying to jury-rig an installation of MSDN for VS2005 from ISO disks.
The company I'm working for has an 'install drive' so I'm not sure of the
pedigree of these directories. Essentially, since I don't have a CD burner
at my disposal, I'm trying to run the installation directly from the ISO
images using Microsoft's Virtual CD-ROM Control Panel v2.0.1.1.
The problem is as follows: It doesn't matter if I run the setup on the
first MSDN disk or call MSDN installation directly from VS2005's setup
screen. Either way I get an error message saying: "Error 1311. Source file
not found. U:\_17693_RTL_x86_enu_NET_Framework_SDK_HxS.cab. Verify that the
file exists and that you can access it."
I should note that given the current mounting scheme, the 3 ISO images are
disks T, U, and V and presumably software on the T drive should be running.
So how could it know about the U drive in the first place and why didn't it
issue a standard Insert Disk prompt? (The file definitely exists and I can
even copy it.) Tag: HatchBrush in WPF Tag: 129468
Questions about clickOnce
hi,
I have couple of questions about clickonce again,
I am publishing a Winform appplication using ClickOnce. In the 'Publishing
Location' text box I input the directory name
(C:\CLICKONCE\Test2\). In the 'Installation URL' what shall i input. Why do
i need to input a URL when it is
simple Winform Application.
Question2:
When I publish a new version, The client should be prompted about the new
version and it should run that instead of old one.
It doesnt do it in my case, even though 'Application Should check for
updates' is ON.
Thanks in Advance
irfan Tag: HatchBrush in WPF Tag: 129464
search results dialog box
when i open search from the start menu, i get a listing in the task bar, but
the box cannot be seen. when i click on the task bar block it appears to fly
off the screen to the upper right Tag: HatchBrush in WPF Tag: 129455
The Interlocked on the Edge of Forever
I've got a quick question that's been bugging me for a long, long time:
Let's say I've got a member variable (in a heavily threaded app):
private int _firstTime = 0;
To make changes to this is easy enough:
InterlockedExchange(ref _firstTime, 1);
... or I can use the InterlockedCompareExchange:
int oldValue = InterlockedCompareExchange(ref _firstTime, 1, 0);
No problems here.
... but, if I just want to read the value, I CANNOT do:
int myValue = _firstTime;
or
if (_fistTime==0)
Doing these requires a memory barrier of some type (volatile variable,
monitor, etc) to have any degree of reliability.
Now, reading the value out using InterlockedCompareExchange always seemed a
bit silly to me. I don't want to always write:
int myValue = InterlockedCompareExchange(ref _firstTime, Int32.MinValue,
Int32.MinValue);
I've never found (although not for lack of looking):
int myValue = InterlockedRead(ref _firstTime);
Of the code that I write, reading the value, and branching based on it's
value, is much more common than writing to the value.
I have, in the past, used volitile variables for this - but I've stopped due
to the various issues regarding volatiles (non atomic reads & writes).
Is there a concensus on the best way to do this? It seems like all the
solutions are.... incomplete.
Essentially I'm looking for a volitile varaiable that is atomically read and
written. Unfortuantly, these don't exist in any language I've yet used.
--
Chris Mullins, MCSD.NET, MCPD:Enterprise, Microsoft C# MVP
http://www.coversant.com/blogs/cmullins Tag: HatchBrush in WPF Tag: 129446
tcpclient connect security exception - unauthorized
Hi all,
I have a tcpclient and server setup client and server both different
machines. The client when run under administrator credentials connects fine,
but when run under normal user, the tcpclient connect is refused with
unauthorised. All of this is on same netword/domain. The client is running
localy not a network share and connects to specific IP Adress on specific
port. The ony difference between connecting and not is the credentials......
Is this .NET Casol as the socket is accessed, if so how do I resolve it, or
are we looking at windows user permissions?
Any help greatly appreciated...
Pete Tag: HatchBrush in WPF Tag: 129445
How to tell which window becomes the foregroud window right away?
Hello,
I followed the MS instructions to subclass Windows using C#.net
(http://support.microsoft.com/kb/815775) as the follows. I then opened
several Excel files, and selected anyone of them as foreground window. I was
expecting to see windows message, saying WM_ACTIVATE, or something like that,
however, to my surprise, I saw NO windows message when I randomly selected
those Excel windows, (although I could see other window messages, e.g.,
WM_GETTEXT).
It was said that this was because "Subclassing this way only works for
windows in its own process, not in other applications." Then, is there a way
to make it work on other processes? Will automation will make the "other
application" in the same process of our application?
My goad is: Tell which (e.g. Excel) window becomes the active one AS SOON AS
a (e.g. Excel) window becomes active.
Thanks a lot.
--------------------
Add a new Class module that is named SubclassHWND.cs to the Visual C# .NET
or Visual C# 2005 application. To do this, click Add Class on the Project
menu.
2. In the Name text box, type SubclassHWND.cs, and then click Open.
3. Replace the SubclassHWND class code with the following code:public class
SubclassHWND : NativeWindow
{
protected override void WndProc(ref Message m)
{
// Perform whatever custom processing you must have for this message
System.Diagnostics.Debug.WriteLine(m.ToString());
// forward message to base WndProc
base.WndProc(ref m);
}
}
4. To demonstrate its use, add the following code to the Load event of
Form1:SubclassHWND s = new SubclassHWND();
s.AssignHandle(this.Handle);
//Now s should be listening to the messages of the form. Tag: HatchBrush in WPF Tag: 129443
some config error happens periodically only
Hi
we have a number of web applications
once in a while they produce an error like below
if you restart IIS - they disappear
it happens on two servers
any ideas?
Thamks
GSL
++++++++++++++++++++++++++++++++++++++++++++++++
Configuration Error
Description: An error occurred during the processing of a configuration file
required to service this request. Please review the specific error details
below and modify your configuration file appropriately.
Parser Error Message: Unable to load file 'portallibrary'.
Source Error:
Line 196: <add assembly="System.EnterpriseServices, Version=1.0.5000.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
Line 197: <add assembly="System.Web.Mobile, Version=1.0.5000.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
Line 198: <add assembly="*"/>
Line 199: </assemblies>
Line 200: </compilation>
Source File:
c:\winnt\microsoft.net\framework\v1.1.4322\Config\machine.config Line:
198
Assembly Load Trace: The following information can be helpful to determine
why the assembly 'portallibrary' could not be loaded.
=== Pre-bind state information ===
LOG: DisplayName = portallibrary
(Partial)
LOG: Appbase = file:///D:/inetpub/Informins_Root/csrportal
LOG: Initial PrivatePath = bin
Calling assembly : (Unknown).
===
LOG: Policy not being applied to reference at this time (private, custom,
partial, or location-based assembly bind).
LOG: Post-policy reference: portallibrary
LOG: Attempting download of new URL
file:///C:/WINNT/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET
Files/csrportal/4b3f8fd5/6c4a072e/portallibrary.DLL.
LOG: Attempting download of new URL
file:///C:/WINNT/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET
Files/csrportal/4b3f8fd5/6c4a072e/portallibrary/portallibrary.DLL.
LOG: Attempting download of new URL
file:///D:/inetpub/Informins_Root/csrportal/bin/portallibrary.DLL.
LOG: Policy not being applied to reference at this time (private, custom,
partial, or location-based assembly bind).
LOG: Post-policy reference: portallibrary, Version=1.0.2158.24839,
Culture=neutral, PublicKeyToken=null
----------------------------------------------------------------------------
----
Version Information: Microsoft .NET Framework Version:1.1.4322.2032; ASP.NET
Version:1.1.4322.2032 Tag: HatchBrush in WPF Tag: 129442
Determining if two paths are the same
Hi there,
Given two file names in relative or absolute format, I need to determine if
they point to the same file. While I can simply pass each to
"Path.GetFullPath()" and compare the results, what is the rule regarding
case. That is, how do you determine whether the local file system is
case-sensitive or not. I don't want to assume that Windows is the target OS
even though realistically it will be. Thanks. Tag: HatchBrush in WPF Tag: 129438
Windows Forms Data Binding problem
Hi,
I builded my very first windows forms application and I used VS.NET 05
wizards to manage a simple Access table, but by now I have a problem:
data aren't updated (without errors) I checked several thinkgs, rows
are showed, but if I do some change and then I click on
databindingnavigator save
button, and then I exit and restart program the data are ...
unmodified...
where I'm wrong?
Thanks!
.:M:. Tag: HatchBrush in WPF Tag: 129436
Directory Sizes and Performance
Hi all,
I need to regularly traverse a large networked file system and return
a list of directories and their respective sizes. The file system is
large enough that performance is a serious concern.
As well as the recursive [File/Directory]Info solution, I've seen
reference to using the FileSystemObject or calls to FindFirstFile/
FindNextFile via COM interop.
Does anybody know the fastest way of doing this in .Net?
-- Bob Tag: HatchBrush in WPF Tag: 129434
.net 3.5 framework.
I cannot install any of the new Orcas Express CTP (Beta 1) editions because
they all fail and quit when attempting to install the .net 3.5 framework. I
have the .net frameworks 1.1, 1.1 Hotfix (KB886903), 2.0 and 3.0 installed
on my machine and am running XP SP2. Tag: HatchBrush in WPF Tag: 129431
.net 3.5 framework.
I cannot install any of the new Orcas Express CTP (Beta 1) editions because
they all fail and quit when attempting to install the .net 3.5 framework. I
have the .net frameworks 1.1, 1.1 Hotfix (KB886903), 2.0 and 3.0 installed
on my machine and am running XP SP2. Tag: HatchBrush in WPF Tag: 129430
.net framwork 3.5
I recently attempted to install VWD and VD editions of Orcas Express CTP.
They both failed during the installation of the .net framework 3.5 with no
other error message other than stating that they had, in fact, failed
because of .net 3.5.
I have installed on my machine .net frameworks, 1.1, 1.1 Hotfix (KB886903),
2.0 and 3.0. If one or more of these needs to be uninstalled, there was no
instructions to such effect on the Orcas Express CTP installation pages. I
am also running XP SP2.
Any insite on this? Tag: HatchBrush in WPF Tag: 129429
.net 3.5 framework.
I cannot install any of the new Orcas Express CTP (Beta 1) editions because
they all fail and quit when attempting to install the .net 3.5 framework. I
have the .net frameworks 1.1, 1.1 Hotfix (KB886903), 2.0 and 3.0 installed
on my machine and am running XP SP2. Tag: HatchBrush in WPF Tag: 129428
Interface & Event
I have an interface ITest that includes an event TestStatusChange.
There is also a class Test that implements ITest. In one of the
functions of Test I want to call the event (see code at the end) but
get the following error:
"The event 'eventTest.Test.TestStatusChanged' can only appear on the
left hand side of += or -=.
All samples I saw seem to do the same I am doing. What am I missing?
Thanks
using System;
using System.Collections.Generic;
using System.Text;
namespace eventTest
{
public delegate void TestStatus(String status);
interface ITest
{
event TestStatus TestStatusChanged;
}
class Test : ITest
{
public event TestStatus TestStatusChanged
{
add { TestStatusChanged += value; }
remove { TestStatusChanged -= value; }
}
public void Check()
{
TestStatusChanged("ok"); //!!!!!!!!! COMPILE
ERROR !!!!!!!!!!!!!
}
}
class Program
{
static void Main(string[] args)
{
}
}
} Tag: HatchBrush in WPF Tag: 129417
System.Speech
How do I add a reference to System.Speech in Visual Studio?
--
Arne Garvander
(I program VB.Net for fun and C# to get paid.) Tag: HatchBrush in WPF Tag: 129410
Any groups created for WPF / WCF ?
Hello,
is there any specific newsgroups created for WCF or WPF ?
I tried searching but could not find.. it would be a good idea if Microsoft
can create such newsgroups, will help people developing early applications
on these new technologies. Newsgroup on LINQ would also be a good idea.. !
:)
Regards,
Jigar Mehta Tag: HatchBrush in WPF Tag: 129406
DataSet fields not updating, no errors being generated
I am using a web service to update some database fields. I used the
dataset designer to define my datatable and tableadapter. I had it
automatically create the insert, update, and delete statements.
When I run the update method, all of the fields are updated except for
four datetime fields. Another attribute these fields have in common is
that they allow nulls. When the method runs, the values in the fields
are not overwritten, they are simply not changed.
Here is the code used for the updating:
PurchaseOrderTableAdapter dAdapter = new PurchaseOrderTableAdapter();
PoDataSet.PurchaseOrderDataTable ds =
dAdapter.GetDataByPoID(poID);
foreach (PoDataSet.PurchaseOrderRow dataRow1 in ds)
{
dataRow1["PONumber"] = poNumber;
dataRow1["ConfirmingTo"] = confirmingTo;
dataRow1["poDate"] = poDate;
dataRow1["ReqDate"] = reqDate;
dataRow1["CancelDate"] = cancelDate;
dataRow1["AllowBackOrder"] = allowBackOrder;
dataRow1["ShipTo"] = shipTo;
dataRow1["BillTo"] = billTo;
dataRow1["ShipVia"] = shipVia;
dataRow1["FOBPoint"] = fobPoint;
dataRow1["Terms"] = terms;
dataRow1["IsPlaced"] = isPlaced;
dataRow1["placeDate"] = datePlaced;
}
try
{
dAdapter.Update(ds);
}
catch (Exception e)
{
return 1 + e.Message;
}
return "0";
I am new to C# and .net in general. Any ideas as to why this method is
not updating the "placeDate", "poDate", "ReqDate", and "CancelDate"
fields? The variables used are defined as DateTime types. As I said,
there are no errors flagged during the process.
Your advice is greatly appreciated.
-- Alex Tag: HatchBrush in WPF Tag: 129403
Service running Infinitely
Hi,
I'm developing a service that should run infinitely and should not be
stoppable. The
user (any user even admin) should not be able to stop/terminate the
service.
Is there any way? or should I go for a normal other than service?
Any recommendations are appreciated.
thanks Tag: HatchBrush in WPF Tag: 129400
Converting source code to another language?
Is it possible to convert source code from one language into another
using the codedom ICodeParser interface?
Has anyone ever tried it? Tag: HatchBrush in WPF Tag: 129398
Need help on CAB
I'm a new bie to cab...need some info on displaying a new child window using
CAB...
My requirement is to show a new form if I click on teh File menu option on the
Main Windows form..
So,I've created a shell with File -> New menu option...but and registered
a click event with the New menu button oiption..but the problem is like I'm
unable to dsiplay the new form in child window....currently my new form
appears in the
parent window only....How do I display data in a child window using CAB
framework..
can anyone help me out Tag: HatchBrush in WPF Tag: 129397
Hi,
is it possible to fill a shape, for instance a Rectangle, with a
HatchBrush ? Is it possible to do this in XAML ?
On May 3, 5:17 pm, joris.spr...@gmail.com wrote:
> Hi,
>
> is it possible to fill a shape, for instance a Rectangle, with a
> HatchBrush ? Is it possible to do this in XAML ?
>
> Thanks,
>
> Joris Spriet