16,020,114 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Visual Basic questions
View Javascript questions
View .NET questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by Kubajzz (Top 40 by date)
Kubajzz
10-Dec-14 2:36am
View
I guess you will need to provide more information in order to get help. How far did you get with your WPF implementation? What exactly is not working? Is there a specific thing you don't know how to do? What are you missing in that Sacha Barber's article?
Kubajzz
8-Jun-11 7:14am
View
That's not really true... There is a better and more elegant solution, see what Tarun.K.S and I posted...
Kubajzz
7-Apr-11 9:57am
View
Just made my day :)
Kubajzz
7-Apr-11 9:55am
View
I'm wondering whether it is a question or a statement since there is no question mark (well, not even a verb, subject or object...).
Your chance to get a meaningful answer will be much higher if you make it look like a question and you explain exactly what kind of information you need and what you have done so far.
Kubajzz
23-Mar-11 3:09am
View
The funniest question I have ever seen! :D What a pitty it's probably going to be removed in a few minutes...
Kubajzz
8-Mar-11 3:59am
View
It would increase your chance to get an answer if you could provide the piece of code that made it work in WinForms and the piece of code that doesn't work in WPF.
Kubajzz
11-Jan-11 8:42am
View
DrawingBrush allows you to combine multiple geometric shapes together and paint each of the shapes with a different gradient brush. I believe that is enough to create the texture you need... Both ImageBrush and DrawingBrush are kind of heavy-weight to create such a simple effect, but I'm afraid there is no other way.
Kubajzz
18-Nov-10 5:36am
View
I would have given you the links if I had them...
Kubajzz
19-Oct-10 6:41am
View
...and I assume you expect somebody to provide the complete solution here. No, it doesn't quite work that way. Not speaking about the fact that demanding code without even saying "please" is simply rude.
Kubajzz
13-Oct-10 13:28pm
View
Yes, when looking at the front side of the triangle the points must be assigned in counter-clockwise order.
Kubajzz
10-Oct-10 7:22am
View
Reason for my vote of 1:
does not answer the question at all.
Kubajzz
17-Sep-10 4:23am
View
Just create an Image control and a Viewport3D control and put these 2 on the same position.
Something like:
<Image ... />
<Viewport3D ... />
And make sure the Viewport3D control is placed over the Image control. There is nothing more to explain here...
Kubajzz
16-Sep-10 7:33am
View
Actually your last sentence is not exactly true. It will compile, but it will not execute, because an exception will be thrown at runtime... Good answer anyway, have my 4.
Kubajzz
11-Sep-10 4:48am
View
Oh, that's another story... See this article for some information on embedded files in a WinForms assembly: http://www.codeproject.com/KB/audio-video/PlayWavFiles.aspx
Kubajzz
10-Sep-10 7:25am
View
Yes, but if your Excel file is embedded in the assembly, then you won't be able to edit it. As far as I understand you need to be able to edit the Excel file, so embedding is not an option.
If you keep the file separate, encrypt it and change its name, it will be visible to the user, but the contents and the purpose of the file will be hidden and your program will be able to edit it.
Kubajzz
8-Sep-10 7:33am
View
Reason for my vote of 1
Yet another homework? Show some effort first, then there will be many people willing to help you.
Kubajzz
8-Sep-10 7:15am
View
Your question is the same like "Why do XML tags start and end with '<' and '>' instead of '{' and '}'" or "Why is C# case-sensitive"...
It's because it was designed that way. You may not like it, but that's all you can do about it.
Kubajzz
7-Sep-10 6:07am
View
Every array implements the IEnumenrable interface and therefore the foreach statement should work. Otherwise your code wouldn't even compile. The problem must be somewhere else... Unfortunately I can't give you more help.
Kubajzz
7-Sep-10 4:37am
View
Reason for my vote of 1
What an answer!
Kubajzz
7-Sep-10 3:45am
View
This sounds pretty weird. Are you compiling your project using debug configuration, without optimizations disabled etc? A line of code can't just get skipped, especially a control-flow statement such as foreach. Maybe the debugger steps over the line, but that doesn't mean that the line is not executed.
Kubajzz
6-Sep-10 14:08pm
View
When you are asking for help make sure you don't make it difficult for those who are willing to help you. The link you posted contains a lot of advertisements including pop-up windows. I originally wanted to leave the page instantly, but in the end I decided to give you a chance and downloaded the .zip file... And the file was corrupted. Do you really expect to get any help?
I sugget posting a few screenshots of the game, that would increase the chance that you will get an answer.
Kubajzz
6-Sep-10 13:17pm
View
If I posted my answer, it would be very similar to what Pallini and Sandeep Mewara posted. There is no need to have duplicate answers here. However, the fact that I didn't post my answer doesn't mean that I don't have the right to point out that your answer is wrong. (huh, what a wonderful sentence!)
I don't want to start an argument here, so I apologize if I spoiled your day... Bye
Kubajzz
6-Sep-10 10:10am
View
Reason for my vote of 5
The best answer in my opinion
Kubajzz
6-Sep-10 10:09am
View
Reason for my vote of 1
Voting 1 to everyone else's replies seems to be a wrong thing to do, especially because your reply is not correct.
Kubajzz
6-Sep-10 8:04am
View
Deleted
Good job!
The DerivedConverter method could be a bit simpler using lambda expression syntax:
return derivedList.ConvertAll<TBase>(
new Converter<tderived, tbase="">(item => item)
);
Or even simpler using Linq:
return derivedList.Cast<TBase>().ToList();
I guess it's just the matter of personal preference...
Kubajzz
6-Sep-10 7:18am
View
If NullReferenceException occurs at the following statement: "SmsPdu smsrec = message.Data;", then it is most probably because "message" is null. Again, I have no idea how to fix it since I have no knowledge of your application and the library you use... Use the debugger to track the state of your variables and I'm sure you'll find the source of your problem.
Kubajzz
3-Sep-10 4:47am
View
Huh... I would like to answer this question, but it doesn't make any sense.
Kubajzz
2-Sep-10 9:08am
View
Reason for my vote of 2
Your method is not efficient. There is no need to read the whole file if you read it line-by-line... The following is better:
private string ReadLine(int lineNum) {
int count=0;
using (StreamReader sr = new StreamReader("C:\SampleFile.txt")) {
string line;
while ((line = sr.ReadLine()) != null) {
count++;
if (count == lineNum)
return line;
}
}
return null; // It might be appropriate to throw an exception here...
}
Kubajzz
1-Sep-10 5:37am
View
The ArrayList class was introduced in early versions of .NET long before generics were added. List(T) is a newer generic class that provides pretty much the same functionality. The advantage is that List(T) is type safe, therefore brings better performance and decreases the probability of various bugs...
I think you will never ever need to use ArrayList unless you need to work with an old version of .NET (older than 2.0).
Kubajzz
30-Aug-10 7:09am
View
You need to provide more information to get an answer... First of all, which technology do you use? WinForms? WPF? Silverlight? ASP.NET?
Kubajzz
29-Aug-10 12:12pm
View
Reason for my vote of 1
Makes no sense...
Kubajzz
28-Aug-10 7:20am
View
Reason for my vote of 1
Answers should not be used to ask more questions... Anyway, search for "WPF Styles and Templates", that's what you need.
Kubajzz
28-Aug-10 7:05am
View
Reason for my vote of 5
Simply perfect answer
Kubajzz
28-Aug-10 7:04am
View
Reason for my vote of 1
This is not an answer, comments should be used for this stuff...
Kubajzz
28-Aug-10 7:02am
View
Reason for my vote of 3
A good solution, but far from perfect...
Kubajzz
28-Aug-10 7:01am
View
I know all that.
1. That's why there's a comment saying it's not a thread-safe way to raise the event. I only provided the simplest and most basic solution.
2. I know the method should be protected virtual according to the recommended practices. However, I'll say it again: I wanted to provide the simplest possible solution just to show the basics, because the guy who originally asked the question obviously doesn't know anything about events... That's why I ignored this rule.
You are right though that my OnSomeValueChanged method should take an EventArgs parameter (although it's useless) to keep the common pattern... Your solution is somewhat more complete.
Kubajzz
31-Jul-10 11:25am
View
Reason for my vote of 1
Your question is way too general... I recommend that you read a tutorial about datagrid and then, if you have a specific problem, ask a question here.
Kubajzz
30-Jul-10 9:04am
View
Deleted
Reason for my vote of 2
Good job and an interesting idea, but the class is pretty useless... VS Object Browser and MSDN is much easier to use.
Kubajzz
27-Jul-10 7:09am
View
Reason for my vote of 1
This question does not make any sense and doesn't belong here since it is probably supposed to be a reply to an article (possibly this one: http://www.codeproject.com/KB/miscctrl/WinformsDirtyTracking.aspx)
Kubajzz
25-Jul-10 9:52am
View
Your question is too general... please specify which platform/technology you use (WPF, Silverlight, WinForms, ASP.NET...)
Show More