|
Hi
can any one send me the links of some samples on System.Drawing or on Pens, brushes, colors and fonts?
ravi vellanki
|
|
|
|
|
Microsoft have so much money, they can afford to run websites with documentation and so on. There's also a site called code project, it has tons of articles, you may have heard of it.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
how to import excel sheet datas into sql server2005 using asp.net
|
|
|
|
|
Google is working properly!!!
"Don't worry if it doesn't work right. If everything did, you'd be out of a job." (Mosher's Law of Software Engineering)
|
|
|
|
|
Hi,
I want to create one Window service Framework which actually needs act like space where we can run more than one service dynamically. I need to start and stop control for every control that need to be triggered from Service Framework. Every service has to run in their own space.
If any one has thoughts please put it on my way....
Thanks
|
|
|
|
|
Nike.....
Just do it.
The best way to accelerate a Macintosh is at 9.8m/sec² - Marcus Dolengo
|
|
|
|
|
Kind of a Service manager application? Hmmm...
I wonder why you would need such flexibility.
On my last job I had the Services configured in a database. I had a number of Services running on various servers and the ServiceInstaller on each server queried the database to find out which Services to run on that server. Once installed, I had an application that could show the status and start and stop the Services on the various servers. All the Services on a server run as one process and share a log file.
If I wanted to add or remove a Service from a server, I had to uninstall and reinstall the ServiceInstaller, which was fine because I didn't have to do that very often.
Each Service also updates the database with event times (start, stop, etc.) so other processes can monitor the health of the Services. The Services get their cyclic rates from the database, so that can be changed on-the-fly (now I might use a custom action for that).
Are you thinking of a more flexible version of that, where services can also be installed and uninstalled on a server without affecting the others?
|
|
|
|
|
Well, What my point is, basically i want to run only one Windows Service from that i should be able to other services (let's say another DLL which has some functionality) every service need to run on its own space means threading.
Any thoughts ?
|
|
|
|
|
Ok, that's basically what I do.
I have a DLL for each service and one process that loads them dynamically.
I populate an array with the loaded services and call ServiceBase.Run Method (ServiceBase[])[^]
Each service becomes a thread of the process, but that's built into the framework, I didn't have to do anything to make that happen.
|
|
|
|
|
string input = "- plum-pear- tyu";
string pattern = "(-)|( )";
string[] substrings = Regex.Split(input, pattern); // Split on hyphens
foreach (string match in substrings)
{
Console.WriteLine("'{0}'", match);
}
the above code gives out some null tokens.... how to cleanse it.. pls help
the quieter u become more u hear
|
|
|
|
|
lawrenceinba wrote: "- plum-pear- tyu";
Do you see the whitespace in the input string (in between - and p & - and t)? You may want to remove it.
string input = "-plum-pear-tyu";
Be careful, there is no Undo Button(Ctrl+Z) in life.
|
|
|
|
|
no space comes before -
the quieter u become more u hear
|
|
|
|
|
It looks like it in the code you pasted before.
Try this:
string[] substrings = Regex.Split(input.Replace(" ", ""), pattern);
The best way to accelerate a Macintosh is at 9.8m/sec² - Marcus Dolengo
|
|
|
|
|
hi friends,,,please help me that..i want to create action buttons same as in powerpoint action buttons..
|
|
|
|
|
You want to create custom controls ? OK, off you go then.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Hello, I need to show thumbnails for lets say, 4000 .jpg files in a SD card, is there a simple way to read the thumbnail embedded in the Exif of the JPEG file header.
I'm asking this 'cause calling Image.GetThumbnailImage is gonna take forever
thanks
|
|
|
|
|
|
That seemed pretty cool the thing is, it is still too slow.
I set the folder view to thumbnails in Windows Explorer and it takes forever to display the thumbnails.
Right now I'm testing that, and after 10 min, only 3 thumbnails have been shown.
I need something to extract the JPEG exif thumbnail.
but thanks
|
|
|
|
|
Hi folks -
This is my first post here, though I've gained some excellent knowledge by searching the site in the past.
I am having a problem with a Word-based mail merge in a C# Windows form application. The problem has to do with the Normal.dot template.
At a high level, my app copies a Word dot template file (not named Normal) to a temp directory, and performs a merge with a data file. If I wanted to save the newly-merged doc file at this point and then close Word entirely there would be no problem.
But, I need to keep the newly-created merged content doc file open. Right now, here’s what happens:
The merge takes place, my app ends, and you are left viewing the new doc file in Word.
At this point, you can either “Save As” with this new doc then exit Word, or just exit Word without saving the new doc – the following occurs either way.
A message box appears: “The file is in use by another application or user. (C:\Documents and Settings\...\Normal.dot)”.
Click OK (the only choice) and a “Save As” pane appears referring to Normal.dot.
Click on “Cancel” (because I don’t want to save Normal.dot) and you’re looking at a empty instance of Word.
Click the red X or choose File/Exit and a message box appears: “Changes have been made that affect the global template, Normal.dot. Do you want to save these changes?”
Select “No” and Word finally closes.
Again, if I just wanted to have the app save my new doc then shut down Word this would be easy. But how can I kill whatever has attached itself to Normal.dot while leaving my new doc open in Word? I don’t want the users to have to deal with making choices about the Normal.dot file. Again, the dot I use in the merge is not Normal.dot…
Thanks for any insight about this problem…
Frank
|
|
|
|
|
Well, I'm pleased to say that making one last Google search I finally found the answer to this problem. Here it is in case it can help anyone else out. The answer was found here:
*****
http://support.microsoft.com/kb/285885
Before you quit Word or transfer control to the user, set the Saved property of the Normal.dot template to True as follows:
Application.NormalTemplate.Saved = True
*****
That in effect makes Word think that the Normal.dot template has already been saved, so it now does not complain about it as Word closes. I verified the creation/edit time of the Normal.dot file in my Microsoft Templates folder to make sure it was truly not changed. This looks like the fix!
Frank
|
|
|
|
|
Frank,
Just wanted to thank you for this post, it helped me out a bunch with an app that I wrote parsing apart specified word files. I was getting very frustrated about Word not closing until I found your post.
Thanks a million
Greg
|
|
|
|
|
Using .Net 2, is there a way to determine if a date in the past falls under DST for a specific time zone using the DST rules for the year of the date. For example, if I have April 2, 2004, I would like to determine if I should be using DST using the 2004 rules for Eastern Time (GMT -5). It doesn't appear that .Net has anything that support this, and I can't tell if Windows even supports this for dates in the past. I know how to do this for current dates.
|
|
|
|
|
Yes, well sort of.
See DateTime.Kind[^]
However you might also read this[^] as it explains that there is no correct conversion.
|
|
|
|
|
Hi,
I am using an IDataReader with SQL and ASP.Net. I keep getting an IndexOutOfRangeException because in one of the columns there is only a value for some of the rows (ex. if the size is over 0.5 there is a value, but if it is 0.5 or under that column is blank). How can I do this?
So far I have:
public static List<name> GetAllNames(){
SqlDatabase db = DatabaseFactory.CreateDatabase() as SqlDatabase;
DbCommand cmd = db.GetStoredProcedureCommand("dbo.GetAllNames");
List<names> namelist= new List<name>();
using (IDataReader reader = db.ExecuteReader(cmd))
{
while(reader.Read())
{
namelist.Add(GetNameFromReader(reader));
}
}
return namelist;
}
private static Name GetNameFromReader(IDataReader reader)
{
Name name_obj = new Name(
(int)reader["ID"],
((reader)["size"] !=DBNull.Value)? (int)reader["size"] : (int)0));
return name_obj;
}</name></names></name>
Thanks so much for your help!
|
|
|
|
|
The code looks OK. I don't see why you'd get IndexOutOfRangeException for some rows but not others.
|
|
|
|