|
Try:
myPanel.BringToFront();
The BringToFront() method is part of the Control class.
Later,
Nathan
---------------------------
Hmmm... what's a signature?
|
|
|
|
|
Duh ! I don't know why I thought bring to front could only be used from the IDE. Man, I feel stupid.
Thanks Nathan
|
|
|
|
|
Not stupid.... Just overworked
Glad, I could be of help.
Later,
Nathan
---------------------------
Hmmm... what's a signature?
|
|
|
|
|
Try changing the order or creation of the status bar and panel.
-- LuisR
──────────────
Luis Alonso Ramos
Chihuahua, Mexico
www.luisalonsoramos.com
"Do not worry about your difficulties in mathematics, I assure you that mine are greater." -- Albert Einstein
|
|
|
|
|
That was the first thing I tried. I did every possible combination for creating and defining the two controls.
Thanks for the suggestion though
|
|
|
|
|
Hi,
Does anyone know if it is possible to call the Scheduled Task interface from C#. Its located here Start -> All Programs -> System Tools -> Scheduled Tasks. Once you Add a Scheduled Task and you get the properties of it -- this is the interface I would like to call. Is there a class in C# that will handle this. I have seen Symantec using this in their Norton AntiVirus program. Any help would be greatly appreciated since I need to do this in my program. Thanks
cAptHiDDeN
|
|
|
|
|
|
Yes very similar to this, but is there a way to called the actual design interface within windows without having to shell out into DOS. It would be nice to call the interface design within windows. There has to be someway to call this but I can not seem to figure it out. This is what I am trying to call: If you got to Start --> All Programs --> Accessories --> System Tools --> Scheduled Tasks. Click Add Scheduled Task and pick the options you want for your particular job. Once your job is add, click on it and get its properties. A window pops open showing you the job you just scheduled. This is the window, I am trying to call. Is it possible to call this either from a class library or a dll in windows? If this isn't possible, is there a way to call the actual wizard (Add Schedule Task)built into windows?
If anyone else might be able to provide me with some help, I would be greatful. Thank You.
cAptHiDDeN
|
|
|
|
|
I'm in the middle of writing a Source Safe automation tool and I have a Traversal method which takes a delegate. While I've used delegates quite a bit in the past I've never really run into the issue where I've needed to pass things along to my delegate that couldn't be found derived during the traversal. IE Checkout delegate needs a checkout destination. I have ideas, but would like some more if anyone has some.
|
|
|
|
|
I don't understand what you're asking. What does the delegate need to do?
|
|
|
|
|
Actually I solved my problem nicely or at least nicer than my quite poor path was taking me earlier. Here is what I was in need of solving, what I was thinking of doing, and what I did:
I had a traversal method which accepted a delegate as a param. This method is, of course, called during the traversal on each VSSItem retrieved from the database.
My original goals was to pass the extra arguments need by each different delegate implementation through the traversal method and then pass them into the delegate call each time. While this may be fine and dandy when you know the signature of the method I didn't want to do that. I thought of using a param list but that isn't really nice either, avoid indexers at all cost type of thing. So my final thought was really what I need is a sub-class, or external, whatever ties your shoes, that would take care of that type of process. IE a GetHistory, GetFile, or Checkout class that really only concerned itself with one file at a time, but knew what it needed and only that (selfish I know). That class exposed a method that was used as the delegate. Its quite nice and quite clean. Any thoughts...
|
|
|
|
|
That sounds reasonable. It's similar to the way events typically work; they always pass the sender as an object, and then the values as a class derived from EventArgs.
|
|
|
|
|
i heared that there is a function in c# that convert images from a format to another ( like from bmb to jpg)
do anyone know it?
|
|
|
|
|
The idea is to use the Image class to load an image in one format (FromFile static method) and save it with another format (Save method). For example:
Image img = Image.FromFile("image.jpg");
img.Save("image.bmp");
That's it!
-- LuisR
──────────────
Luis Alonso Ramos
Chihuahua, Mexico
www.luisalonsoramos.com
"Do not worry about your difficulties in mathematics, I assure you that mine are greater." -- Albert Einstein
|
|
|
|
|
Is there a way of applying something similar to the web's "session" to a windows application (many forms, MDI parent window)? I want users to be logged out after 20 minutes.
Thanks
|
|
|
|
|
Hi,
You can use a Timer. Activate it on application start, set it for 20 minutes, and reset it everytime the user does the required function, like clicking a specific button or whatever... I have used it for a BlackJack game where the user has 1 minute to bet, if not he get removed from the game and the game continues. Just a tip, print starting and stopping times in the console so u can see whats happening .
Hope this helps
MYrc : A .NET IRC client with C# Plugin Capabilities. See
http://sourceforge.net/projects/myrc for more info.
|
|
|
|
|
I was thinking of this, but the application is complex and contains multiple windows. So i'd need to map every navigation back to the original window and its timer, which is not really practical.
|
|
|
|
|
I'm under the impression I can use the XMLTextWriter to output my XML nicely formatted, but my attempts so far have failed. Does anyone have any ideas ?
Thanks.
Christian
come on all you MS suckups, defend your sugar-daddy now. - Chris Losinger - 11/07/2002
|
|
|
|
|
Christian Graus wrote:
I'm under the impression I can use the XMLTextWriter to output my XML nicely formatted, but my attempts so far have failed. Does anyone have any ideas ?
I may be going over the obvious here but:
xtwArticles = new XmlTextWriter ("test.xml", 0);
xtwArticles->Formatting = Formatting::Indented;
That is the C++ version that I am using and the XML comes out nicely formatted. For the C# version just replace the 0 with System.Text.Encoding.UTF8
regards,
Paul Watson
Bluegrass
Cape Town, South Africa
The greatest thing you'll ever learn is just to love, and to be loved in return - Moulin Rouge
Alison Pentland wrote:
I now have an image of you in front of the mirror in the morning, wearing your knickers, socks and shoes trying to decided if they match!
|
|
|
|
|
Comes out of where ? I have a complete XML file which is not formatted, coming out of an XmlDocument. I tried passing it into an XmlTextWriter as a string and pulling out the result, but it was just a blob of unformatted XML, just the way it started.
I want to take
<xml><node><subnode>sdjkfsl<node><node2>sdfsf
for example, which I have as a string, and pass it into something that formats it. I've actually written my own function which does this, but I'd prefer to use the one provided if I can make it work.
Christian
come on all you MS suckups, defend your sugar-daddy now. - Chris Losinger - 11/07/2002
|
|
|
|
|
Paul Watson wrote:
That is the C++ version that I am using and the XML comes out nicely formatted.
Paul, I thought you were a devout Visual Basic user, nonetheless never creep near the C++ neighborhood, what gives?
Nick Parker
|
|
|
|
|
Nick Parker wrote:
Paul, I thought you were a devout Visual Basic user, nonetheless never creep near the C++ neighborhood, what gives?
*sigh* I am not devout anything. Yes I have up until a short time ago mainly been using VB, though that is really VBScript and that was a limitation of ASP and so was forced.
However VB has always been up to my needs and it is good at what it does. Right tool for the right job.
As for venturing into C++: I am entering the Visual C++.NET competition
I thought it would be a fun thing to learn and also as a way to prove that a VB coder can do C++.
That "C++ version that I am using" bit is because my MC++ class writes and reads some XML.
I like knowing a little bit about everything, makes me dangerous (you know, the saying "A little knowledge is a dangerous thing" )
regards,
Paul Watson
Bluegrass
Cape Town, South Africa
The greatest thing you'll ever learn is just to love, and to be loved in return - Moulin Rouge
Alison Pentland wrote:
I now have an image of you in front of the mirror in the morning, wearing your knickers, socks and shoes trying to decided if they match!
|
|
|
|
|
Hi,
If you look at an article about XmlSerializer submitted end last week, you should get an better idea too.
Here some code i have used:
System.Xml.XmlTextWriter xmlwriter = new XmlTextWriter(filename, System.Text.Encoding.ASCII);
xmlwriter.Formatting = Formatting.Indented;
xmlwriter.WriteStartDocument();
xmlwriter.WriteDocType("Options", null , null, null);
xmlwriter.WriteComment("MYrc Option File. Edit at own risk!");
xmlwriter.WriteStartElement("Options");
PropertyInfo[] props = this.GetType().GetProperties();
foreach (PropertyInfo prop in props)
{
xmlwriter.WriteStartElement(prop.Name);
object da = prop.GetValue(this, null);
xmlwriter.WriteAttributeString("Type", prop.PropertyType.ToString());
if (da != null) xmlwriter.WriteAttributeString("Value",da.ToString());
else xmlwriter.WriteAttributeString("value", "null");
xmlwriter.WriteEndElement();
}
xmlwriter.WriteEndElement();
xmlwriter.WriteEndDocument();
xmlwriter.Flush();
xmlwriter.Close();
This is for an OptionGrid class in trying to get going, but I have had no success with non primitive types , but it works well with primatives
Hope this helps.
MYrc : A .NET IRC client with C# Plugin Capabilities. See
http://sourceforge.net/projects/myrc for more info.
|
|
|
|
|
Thanks - I had seen that the writer could be used to write XM a node at a time, but I already have the XML as a string, and I want to pass it in one go. A method is provided to do this, but I tried it and it did not format the XML for me, it just passed it back. I set the Formatting to be Formatting.Indented before I passed the string in.
Christian
come on all you MS suckups, defend your sugar-daddy now. - Chris Losinger - 11/07/2002
|
|
|
|
|
Hi,
Ive just Deployed my new web service to the main company IIS using a deployment app and it installed ok, the IIS has the .NET Framework installed.
When I try and add a web reference to another project by browse to service1.asmx page it brings up the windows download file dialogue.... everything has worked a treat so far, my last hurdle
any thoughts?
Thanks guys
|
|
|
|