|
Excellent. Thanks for your help.
I found this, is this a good place to start?
http://www.codeproject.com/cs/database/SqlWrapper.asp
|
|
|
|
|
Hello,
Does anyone know how can i generate the code to copy one class to another ? the class is not seralizable.
I was thinking implmenting it by recursive reflection that would generate a code (I don't want to use refelction due performance).
Did anyone already implmented it ?
Thanks,
|
|
|
|
|
Hello,
I think implementing IClonable would help you!
Look at this article[^] from Amir Harel.
All the best,
Martin
|
|
|
|
|
I'm drawing Video on a Panel Object using AudioVideoPlayback Class. Now I'd like to put some text (or Image) on it. Any Ideas on how to do that???
Thanks...
|
|
|
|
|
Erhm, do you want to place the text in the video file, or do you just want to render the text over the video when playing ?
|
|
|
|
|
Hi.
I have some classes which I want to serialize to XML Documents.
If there is a field/property in an object of such type and it has a null value, when I serialize the object, the corresponding XML Node is omitted, so it doesn't appear at all in the output document.
Is there a way(I'm thinking maybe a Serialization attribute) to change this behavior so that in the generated XML document, the node appears with an empty value?
Thanks.
|
|
|
|
|
blackjack2150 wrote: he generated XML document, the node appears with an empty value
In the case of a string, How would it distringusish between empty and null?
<XmlNode attribute=""> - here "attribute" is empty
<XmlNode> - here "attribute" is null.
No way around that unless you want to make your value empty rather than null!
|
|
|
|
|
Thanks for the interest.
But it's not about attributes. It's about the value itself.
Let me give you an example:
Say I have the simple class:
class Human
{
public string name;
public int age;
public int height;
public char gender;
}
If I declare a "Human" variable and give values to some of the fields, but not all:
Human John = new Human();
John.name = "John Stevens";
John.age = 23;
I don't give any value to the height and gender fields.
After that I serialize this class to XML.
The output will be:
<xml...>
<Human>
<name>John Stevens</name>
<age>23</age>
</Human>
You notice that there are no tags for height and gender because these values were not initialized.
Bottom line:
Is there a way to get this output xml for the same chain of events as described above?
<xml...>
<Human>
<name>John Stevens</name>
<age>23</age>
<height />
<gender />
</Human>
Thanks.
|
|
|
|
|
Hello all,
I've created a setup project in visual studio 2005 in c#.
When I run the setup.exe to installation folder step, I realized that it installed some other data in system driver-usually drive c (press the Disk Cost button) even if I installed the application in other drive (let's say drive d).
Does anyone knows what's this data?
this data is 1.2 Mb..
RoyRose.
|
|
|
|
|
RoyRose78 wrote: Does anyone knows what's this data?
I don't know. But I do know how to find out: Find some sort of file monitoring tool (sysinternals might be a good place to start) and watch what it is writing to disk.
Upcoming events:
* Glasgow: Mock Objects, SQL Server CLR Integration, Reporting Services, db4o, Dependency Injection with Spring ...
"I wouldn't say boo to a goose. I'm not a coward, I just realise that it would be largely pointless."
Ready to Give up - Your help will be much appreciated.
My website
|
|
|
|
|
I have one RDLC report and it has many value fields(Data fields).
I want to print only this data values but see all report in reportviewer .
Like billing system ......
simplly i have two name see reportviewer but print only one name....
Thanks in advance....
hi...
|
|
|
|
|
Hi,
i'm new in using Crystal Report Viewer..i want to ask how can we bind our data so it can appear in the Crystal Report Viewer, for example: i have a database name Contact and a table name User..what i dont know is bind the data inside table User and view it in our CrystalReportViewer.Please Help me..i use sqlserver2005 for the database
Thank You
Regard,
TCim
|
|
|
|
|
Hi,
I'm a beginer in this language and i hope that there is someone out there who can help me
I want to create a form that has 2 areas. One area is where all the pre-drawn shape is located and the other area allows the shapes to be drag and drop onto it. Any tips what i should do and what kind of classes that i should use?
Thanks
|
|
|
|
|
It's a bit complicated, but you have to set properties into two different objects (sender, receiver):
- Allow Drag
- Allow Drop
Basically you want to drag on object (a shape control) into a container that'll accept the object. It's not that simple, but you do need to handle the events that are triggered by the drag/drop event.
There's a lot of articles/projects on this site that go through drag/drop in detail. I'd take a look at some of that code and adapt it to what you're trying to do. Good luck!
|
|
|
|
|
Hi,
Currently I am working on a multilingual application.
1. I willing provide a Button on UI which will toggle IME mode, say from English to Japanese. How can do that ?
2. How can I detect if systems IME mode is changed by user ?
3. As well as above I want to transliterate the inputed text to english. Can I do it ?
Regards
Prasad
|
|
|
|
|
Erhm, there are several ways to 'translate' your application. I'm also currently working on a project which must be able to support multiple languages. I choose to create a new set of controls to support multiple languages. Therefore created an interface containing translation methods, and make all controls (for example buttons and labels) member of this interface. Then as soon as the user changes the interface language, set the CultureInfo object to the new language, and call the translate method on every control member of the interface
However, VS.NET contains full support for multi-language apps (using resources) you should consider some options, and find 'the best solution' for you
|
|
|
|
|
Thanx Allot Eduard,
I am developing framework for mentioned project now, and I have done with the display part using resource files (i.e. to display label and button text dynamically from resource files). That works fine, problem is with data entry controls like TextBoxes, where IME comes into picture. I wanted to know how can I change IME mode (say from English to Japanese or any Asian language) programatically ?
Awaiting ur reply.
Prasad
|
|
|
|
|
iprasad007 wrote: 1. I willing provide a Button on UI which will toggle IME mode, say from English to Japanese. How can do that ?
All text in the UI is set using the control.Text property on each control. To change the text change that value.
Heres a search for how to use satallite assemblies to achive this.
http://www.google.co.uk/search?hl=en&q=c%23+localisation+satallite+assemblies&meta=[^]
iprasad007 wrote: 2. How can I detect if systems IME mode is changed by user ?
Not sure. You might be able to find out more about this whilst researching localisation.
iprasad007 wrote: 3. As well as above I want to transliterate the inputed text to english. Can I do it ?
It's possible theres some software out there that will do it badly. If you want decent results you'd have to get a human to do it.
Heres some computer translated text. I've no idea if it's mangled or not since I don't read japanese but it should give you an idea of the quality.
English:
This is an example of some computer translated text. It's probably not very good.
Japanese:
これはコンピュータによって翻訳されるテキストの例である。それは非常によくないおそらく。
|
|
|
|
|
Hi originSH,
It seems that u didn't got me correctly. U have told me about Text property of control, but I was talking about setting IME mode. U have told me about translation but I was asking about Transliteration.
Anyways thanx for ur efforts.
Regards
Prasad
|
|
|
|
|
|
Hi All,How can I create popup menu with images in C#...for example in iGoogle when we want to change the theme,it lists us several options with images...
Hi,Im Razana
|
|
|
|
|
Hello,
There are some articles here on CP which will help!
I found this one[^] written by John O'Byrne.
All the best,
Martin
|
|
|
|
|
Hey Martin I would like to do it in web form...
Hi,Im Razana
|
|
|
|
|
i want to know how can i write combobox items in a file
here is coding which i wrote but its giving error
StreamWriter sw = new StreamWriter(".\\ABCD.B");
for (int a = 0; a < am.Items.Count; a++)
{
sw.WriteLine(am.Items(a));
}
sw.Flush();
sw.Close();
where "am" is combobox
the error is
'System.Windows.Forms.ComboBox.Items' is a 'property' but is used like a 'method'
|
|
|
|
|
Hello,
Use "Items[a]".
xmen_xwk wrote: where "am" is combobox
You should really name it different, than you wouldn't have to explain it!
All the best,
Martin
|
|
|
|