|
Hi Luc,
In the end, I tried to create a new console project with just an empty Main() and tried to step into it - I can't figure out how to remove more from the main class... I tried to step into Main() and had the same AccessViolationException error about Windows.Forms. So I gave up and am trying to reinstall VisualStudio. It's weird... and I could have a better use of my time then trying to correct M$ errors... I'm under Vista SP2 (well, Windows still thinks that it is under SP1 - the machine is brand new and Windows is having problems since I tried to load SP2). Just hope I won't have to reinstall the whole machine from scratch.
|
|
|
|
|
I would run first outside Visual Studio, and try on a second PC. If it behaves badly outside VS and only on one machine, then I would reinstall the .NET Framework on that machine, rather than reinstalling/fixing VS.
If it runs fine outside VS, or badly on both machines, then I would reinstall VS.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
I tried to reinstall VS but no luck: it is still not able to debug a freshly created console project
I'm frustrated because I just bought a new machine to run as my development machine and VS won't run properly. I've spent a week setting it up and it looks like I'll have to restart the process - and, meanwhile, I can't finish my current project (which is becoming urgent). Why do things have to be so complicated with Windows?!?
|
|
|
|
|
Issue fixed: since I had issues with the Windows updates, I finally had to reinstall the whole machine from scratch - which now works! I'll be able to retake my productive work.
Thanks for your support
Olivier
|
|
|
|
|
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Well, it runs fine on my machine outside the debugger - that's why I suspect VS has an issue. I should know in a few minutes now.
|
|
|
|
|
I am using iTextsharp DLL for generating pdf's in my project. Does this dll need any license.
|
|
|
|
|
the project is in sourceforge, it means : opensource.
|
|
|
|
|
According to the license information in SourceForge, it uses the GNU Lesser Public General License. I'm not an expert on it, but I think that means you can distribute it with your application without including a license text document
Between the idea
And the reality
Between the motion
And the act
Falls the Shadow
|
|
|
|
|
Thanks
|
|
|
|
|
HI,
I need to code in C# to input a username and password for an authentication dialog box in Windows while trying to access a share in another system. The idea here is to pass the username and password in a function as argument so that this function will automatically enter both (username and password) once the Windows dialog box for Aithentication pop ups while accessing a share in any other system.
Can you please help me out with any API or any other piece of code to work out!
|
|
|
|
|
|
Is there such good tutorial on Windows Messaging that uses WndProc?
|
|
|
|
|
Hi all
I am trying to display the value of a variable in a label.
Easy enough I hear you say, but the variable can be changed by many different methods and functions, (some in dll's,) none of which trigger any specific event that I would normally use to update the label.
I need the label to show the current value of the variable in 'real time.'
public class MyClass
{
public DateTime datStart;
public DateTime datNext; <======== This is the one I'm trying to show
public int intParam1;
public int intParam2;
//Extra fields removed for clarity
}
And then in my form code:
MyClass _myVar = new MyClass();
I have a label called lblInformation that I would like to always show the value of _myVar.datNext.ToString()
I've spent many hours trying to find a solution so any help will be very much appreciated.
Thank you
|
|
|
|
|
Hi,
this is what I do in such situations:
- create a Windows.Forms.Timer that ticks a few times per second, say 10Hz
- in its Tick handler, set Label.Text=latestValue.ToString()
- done
Thay isn't exactly real-time, however it is almost as fast as the human eye can cope with, and it does not waste CPU cycles on updating all the time assuming the variable could actually be changing at a much higher rate.
BTW: by using the right timer, I also avoided cross-thread problems.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Luc
Thank you for a prompt and elegant solution to my problem.
Regards
Martyn
|
|
|
|
|
you're welcome.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Maybe I am understanding the question, so I will tell you what I would do...
Is it the case that this is an existing class that is used in many different places already, so you don't want to change it to much.
If you have access to the code, you can do this...
First change the member variable to private and rename.
private DateTime dateNext;
The add an event.
public event EventHandler datenextChanged;
Then add a property with the existing name.
public DateTime datNext
{
get{return dateNext;}
set
{
if(!datNext.Equals(dateNext) && datenextChanged != null)
datenextChanged(this, EventArgs.Empty);
}
}
Then you just need to subscribe to this event on your object and update the label in the handler.
Maybe this will work for you if I am understanding the problem.
Thanks,
Wendell
|
|
|
|
|
have you tried making the data bindable and then the form's label simply binds to the instance value. When the datNext changes the label is updated for free.
Panic, Chaos, Destruction.
My work here is done.
|
|
|
|
|
Hi,
I am trying to implement a functionality which will allow users to select rows by checking into the check boxes in the datagrid view and displaying the checked item in a new form. Can any1 help me out in this.
Many Thanks,
|
|
|
|
|
|
Hi everyone.
I want to make an application that has one Main Window Form.
From this main form I want to open new forms. Each newly opened form is showed in Taskbar and can be individually closed. But I want main window form to be Owner of all newly opened form.
In the above case I want single instance of Main Form running as an application and if i close the main form all other opened forms should be closed.
I cannot used this.AddOwnedForms(newForm) because there are few restrictions of minimize and focusing main form.
What is best way to achieve this functionality?
Thanks.
Good Day.
|
|
|
|
|
Just create and show all your 'child forms' inside your main form and you should automatically get all the functionality you have asked for
Life goes very fast. Tomorrow, today is already yesterday.
|
|
|
|
|
Thank you for reply.
I want Main Form as a separate window. Not like MDI container. Is that possible to have Main Form invoking new windows and works as parent to all new windows?
|
|
|
|
|
Hi!
I want to get the file path hosted by a certain excel process. I have its Process object only.
Thanks in advance.
|
|
|
|