|
Fine, you did not show/explain actual output, so I don't know how much you already had.
Anyway, since you have a stack traceback, look for the first method name WITH line number,
that is most likely to be where the problem SHOWS; of course as always the cause of the
problem may have happened before that.
"Object reference not set to an instance ..." means you are using an object reference that
holds null rather than a valid object. As in:
myClass something;
something.DoMethod1();
If you want specific help, please clearly explain what you get, how it differs from what
you expect, and show code and exceptions.
Luc Pattyn [Forum Guidelines] [My Articles]
this months tips:
- use PRE tags to preserve formatting when showing multi-line code snippets
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
Hi, another newb here, if i had an enum like this:
enum test
{
zero, one, two, three, four, five, six, seven, eight, nine, ten, eleven, twelve, thirteen, fourteen, fifteen, sixteen, seventeen, eighteen, nineteen, twenty...
}
How would i display the string instead of the integer in auto tooltip?
I can't make this blog work for me, help?
http://joshsmithonwpf.wordpress.com/2007/09/14/modifying-the-auto-tooltip-of-a-slider/#comment-6921
Also if i would bind the value to a label would numbers be displayed in the label or strings?
How would i bind it to a label even if not using strings for integers in the slider and make strings come out instead?
EDIT: This was a problem of cast:
this.AutoToolTip.Content = (test)Convert.ToInt32(this.AutoToolTip.Content);
EDIT2:has a flaw though, first time i clock the slider's bar only one char wide tooltip appears, how can i change that?
-- modified at 23:25 Saturday 10th November, 2007
|
|
|
|
|
Hi,
I'm currently working on a project to read in an excel file and display it using a DataGrid.
However every time I try to open the connection I get the error - Could not find installable ISAM. I have Office 2007 installed and have also installed the Access Data Acces components.
This is the current code that opens the connection
<br />
OleDbConnection cnCSV = new OleDbConnection(@"Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\\test.xlsx;Extended Properties=Excel 12.0;HDR=NO");<br />
cnCSV.Open(); <br />
Does anyone know a work around for the ISAM? Do I need to re-install MDAC?
Paul
|
|
|
|
|
|
Yes it it
"The early bird may get the worm, but the second mouse gets the cheese" - anonymous, found in Uncle John's Bathroom Reader
|
|
|
|
|
Hi, I have a Textbox that I've bound to a property in my business object (Person object, FirstName property).
firstName.databindings.add("text", Person, "FirstName");
Works fine. If I manipulate the Person object and change the FirstName property, I need the textbox to reflect the change.
Other than raising an event to set the textbox.text to the new property value, is there any other way to go about it?
Thanks!
|
|
|
|
|
Refresh?
Need a C# Consultant? I'm available.
Happiness in intelligent people is the rarest thing I know. -- Ernest Hemingway
|
|
|
|
|
Hi,
I have a list box of items and I want to change the style of the newest item in the list.
I tried some things, but no results...
|
|
|
|
|
gabi_coman wrote: I tried some things, but no results
Does that mean you tried typing some code? Did you try reading? You know reading documentation and articles about how the list box control works so you could "know" how to solve your problem?
|
|
|
|
|
I don't really know what's wrong with what I've wrote. If you put a question on a forum it means that you know the answer?
Thank you for your support, now it's all clear.
|
|
|
|
|
Hy
I have a WebBrowser. Enter to mail.yahoo.com, make the login, after that I change the page. How can I do if I want to re-enter to mail.yahoo.com to not login to my account. I don't want to do Sign Out. I try to create a new instance of the WebBrowser but doesn't work.
thx
|
|
|
|
|
Find the Yahoo cookie stored in temporary internet files and delete it.
There's a better way to do sign into yahoo mail without using a behind-the-scenes-web browser. Use the Yahoo Mail API[^].
|
|
|
|
|
Hello everyone,
I have created a simple WIndows Application which user can download, install, and use it on thier computer. I was wondering if it is possible to make the application functional on IE browser. Would it possible for the user simply get connected and have all the functionality online?
If this is possible, what are the steps that I need to take in order to convert my existing code into a browser base application?
Any information on this issue would be greatly appriciated. Thank you and have a great day.
Khoramdin
|
|
|
|
|
Khoramdin wrote: what are the steps that I need to take in order to convert my existing code into a browser base application?
Well, if your application is written in layers (presentation, business, data) then it should be fairly easy to swap out the presentation layer and create a new one based on a web application. If it isn't written properly then you'll have a fair bit of redesign to go to get it to work in a browser.
|
|
|
|
|
Hi there.
I've developed a media player like application.
This uses Windows forms and runs stand-alone locally.
Now, i want to embed that player application into a website.
[ Just like those flash players around ... ]
But how to achieve this ?
Especially, how to achieve this for either IE AND FF ?
Can I 'easily' use <object> and <embed /> tags to run the application IN
a website from the WWW, or has there some more 'magic' to be done ?
I want to run the application / player just like the flash player.
|
|
|
|
|
There is some magic to be done: first, your program must be compiled to a library, and the bits you want to show up on the web page must be a UserControl, not a form.
From there, you'll want to expose your control as an ActiveX control. A quick Google Search[^] reveals a good deal of articles on this.
|
|
|
|
|
|
Hello All,
Just a question I was hoping to get answered. I completed an application about a month ago which implemented a FileSystemWatcher object and most of of the time is works great; but, sometimes for some reason, it will miss some files, which I will have to manually cut and paste the files to get the file watcher to process. I have increased the InternalBufferSize but it still happens.
I was thinking of another approach which may be foolproof (in my little mind anyway.) I was thinking a employing a timer and when the elapsed time is met, I could check the directory and see if there are any files available. If so, I want to grab the name of just one of the files and then do the processing. Yeah I know, sounds an awful lot like the watcher but I think I would have more control by just processing one at a time and no matter how many files pile in there at once, I will systematically process them all.
My only problem is trying to figure out how to get just 1 of the names of the files at the timeElasped point. Say there are files named like A.txt all the way to Z.txt. I want to check the directory and just return A.txt. I don't want to put all 26 into an array.
Any thoughts would be appreciated and thanks in advance.
F
|
|
|
|
|
Have you looked at this article that goes into detail about the FileSystemWatcher[^]? From the article,
The sample application simply logs messages to the UI. In general however you will be doing far more work. Work that will take a reasonable amount of time (such as retry counting). The FSW communicates to the underlying file system through a shared buffer. This buffer is limited in size. If more events come from the file system than the FSW can handle the buffer will overflow. In this case two things will happen: you will miss events and the Error event will be raised.
|
|
|
|
|
I don't think there's a method that just returns 1 file. As far as I know your options are the static Directory Class and it's GetFiles() method and the same method with the DirectoryInfo Class. But you could just use the first file in the array and toss the rest if you only care about 1 file.
If you're not going to use the FSW and want to just run this app on a scheduled basis, then make it a generic console application and use the Windows scheduled tasks to run it once an hour or whatever time increment you think works best.
Your applciation could always store the last runtime in a config file so you know not to process files with a date before that last runtime.
|
|
|
|
|
Hi Chris,
Good old kernel32.dll offers the Win32 function "FindFirstFile" which returns a single file.
From that, one could find the next file using "FindNextFile", or somehow eliminate the
file found, and repeat "FindFirstFile". So a little P/Invoke might help here, although I am
not convinced it would offer a better solution that what you suggested with GetFiles()
assuming the number of files is reasonable.
Luc Pattyn [Forum Guidelines] [My Articles]
this months tips:
- use PRE tags to preserve formatting when showing multi-line code snippets
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
I've read the article about FSW a couple of times and I still think there is that margin of error that I don't want to deal with, seeing how I am experiencing it now. I am going to try the array route and let you guys know how things turned out.
As always, thanks for taking the time to respond to my simple questions.
F
|
|
|
|
|
Dear programmers,
I want to create a large/complicated application which has a user-interface that start a lot of operations in background via threading.
If these threads are running, then the user-interface has to be partially disabled (depending on the type of operation).
This can be complicated because of a lot of dependencies.
My question now is:
Is there any "kind of design-pattern" by which this problem can be solved?
Thanks for your support ! ! !
|
|
|
|
|
Have you looked into the BackgroundWorker[^] component? It's designed especially for this. *edit link fixed
|
|
|
|
|
Thanks !
Unfortunately your link does not work
|
|
|
|
|