|
hello all i need help
iam zidan from egypt
and i love programming so much and i want to learn how can i start
i hear about C# and more, i want some one help me , how can i start
and thank you all
my mobile num is ( +20104893140 )
Best Regard
A.Zidan
zidan
|
|
|
|
|
Read some articles that are posted on this site.
There are some beginner articles in the C# section.
You know you're a Land Rover owner when the best route from point A to point B is through the mud.
Ed
|
|
|
|
|
See these sources of information. Amazingly, they are all free!/ravi
My new year's resolution: 2048 x 1536
Home | Music | Articles | Freeware | Trips
ravib(at)ravib(dot)com
|
|
|
|
|
Hi,
In one of my Windows Form displaying data using infragistics UltraWinGrid control in C# VS2003, I need to add a new row when user clicks "Add" button in the existing grid so that user can enter values for each column and then posting this entry to the database.
Any idea about how to do that in UltraWinGrid control
thanks
Share knowledge to enhance your learning
|
|
|
|
|
How do I create events for Dynamically created Controls?
?
|
|
|
|
|
I have a ComboBox that has the DataSource property set to an ArrayList. I am using the following code to force the ComboBox to update when I make changes to the ArrayList:
this.cboTrains.DataSource = null;
this.cboTrains.DataSource = alTrains;
this.cboTrains.DisplayMember = "Name";
Is there a better way?
Also have the same issue with ListBox.
Thanks.
www.lovethosetrains.com
|
|
|
|
|
Try calling the "Refresh" method on the comboBox to make it update instead of resetting its data source...
|
|
|
|
|
Nope.. Doesn't do the trick. The Refresh method just forces the control to redraw (not update what it knows)..
I was thinking of adding an event that fires when the ArrayList is changed and entending the control (ListBox/ComboBox) to have a new method that updates the bindings. I'm just not wanting to overly complicate it (or do more work then needed).
Thanks.
www.lovethosetrains.com
|
|
|
|
|
Hi and THANKS a lot in advance.
I'm in a big urge to get this done, so please, any help is greatly appreciated.
I'll use a simplified scenario of my case, but the error happens the same. I'm creating a new User Control, I add a DataGridView to it, that's the only control in it. I then create a public property called "Columns" to expose the DataGridView Columns property so I can access the property from the Designer Editor. I do that this way:
namespace WindowsApplication3
{
public partial class myUC : UserControl
{
public myUC()
{
InitializeComponent();
}
[Editor("System.Windows.Forms.Design.DataGridViewColumnCollectionEditor, System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a", typeof(UITypeEditor))]
[MergableProperty(false)]
[DesignerSerializationVisibility(DesignerSerializationVisibility.Content)]
public DataGridViewColumnCollection Columns
{
get { return this.dataGridView1.Columns; }
}
}
}
I took all that Attributes code from the System.Windows.Forms.DataGridView metadata, just like the Columns property appears in it.
Then, I add a Windows Forms item to my application and drag&drop one MyUC control from the toolbox into it. Then I click the MyUC and go to its properties page to modify the Columns properties just like with an ordinary DataGridView. The property is there but when clicking on its "..." button to open de Edit Columns Dialog I get the mentioned error. Something like this:
"Unable to cast object of type 'WindowsApplication3.myUC" to type "System.Windows.Forms.DataGridView".
After posting in other forums and threads, a guy came with a suggestion to use Attribute Redirection to accomplish the goal. So, I included this:
[AttributeProvider( "System.Windows.Forms.Design.DataGridView", "Columns" )]
public DataGridViewColumnCollection Columns
{
get { return this.dataGridView1.Columns; }
}
(Afert adding that, remove the [Editor (...)] attribute line)
This partially solves the first problem. Now, the Columns Editor finally appears, BUT, Two things happen now:
1. New columns can't be added using the editor. A error is shown when trying to add new columns.
2. Even worse, no changes are saved to the control. As soon as you build the project, all the changes are gone. For instance, if the Header Text of the columns is changed, and then a build is done, the Header text changes are lost. No data is being persisted.
I really really need the Columns property to be accesible in Design Time this way. I don't know how to work this out.
I get this error and problems with an almost blank project. Just add a User Control Item, put a DataGridView into it. Add the code above to make the Columns property visible and then try to access the property in the Property page.
I think what I'm trying to do is quite simple, so I'm wondering what the problem is, and how to work it out.
Thank you so much in advance.
F.
PD: I'm using the shipped VS.NET 2005.
|
|
|
|
|
hi,
is it really possible to send a message from a tcp socket to a webservice. any sample code, links will help. thanks.
|
|
|
|
|
I'm getting in a muddle with Generics and hope one of you generic guru's happen to pass my plea for help.
Basically I want to implement a generic abstract BaseCollection which holds abstract BaseItems, but the BaseItem requires a reference to it's parent collection. Which is where I'm getting trouble. How do I declate a variable to hold a list of type BaseCollection, when BaseCollection is itself generic and what it holds is essentially unknown.
Here's the scenario, without using generics I'd probably implement the following (please excuse the formatting)
<br />
public abstract class BaseCollection : CollectionBase<br />
{<br />
... collection base routines etc...<br />
<br />
public void DoSomeBasecCollectionStuff()<br />
{....}<br />
}<br />
<br />
public abstract class BaseItem<br />
{<br />
BaseCollection _parentCollection;<br />
<br />
public BaseItem( BaseCollection parentCollection )<br />
{<br />
_parentCollection = parentCollection;<br />
}<br />
<br />
public void DoSomeBaseItemStuff()<br />
{<br />
_parentCollection.DoSomeBaseCollectionStuff();<br />
}<br />
}<br />
Therefore I'd have a PersonCollection and Person item simply as
<br />
public class PersonCollection : BaseCollection <br />
{}<br />
<br />
Public class PersonItem : BaseItem<br />
{}<br />
Here's the problem, how would you implement the above using generics? I understand the collection would be declared as
public class BaseCollection<T> : List<T> <br />
<br />
public class PersonCollection<PersonItem> : BaseCollection<PersonItem><br />
but how would I declare the constructor for BaseItem and the _parentCollection variable in the BaseItem class???
Andy
-- modified at 11:28 Wednesday 3rd May, 2006
|
|
|
|
|
I think that you can do something like:
public interface IMyCollectionItem<T> {
public MyCollection<T> Owner { set; }
}
public class MyCollection<T> where T : IMyCollectionItem {
private List<T> list;
public MyCollection() {
this.list = new List<T>();
}
public override void Add(IMyCollectionItem item) {
item.Owner = this;
this.list.Add(item);
}
}
public class PersonItem : IMyCollectionItem<PersonItem> {
private MyCollection<PersonItem> owner;
public MyCollection<PersonItem> Onwer { set { this.owner = value; } }
}
---
b { font-weight: normal; }
|
|
|
|
|
I'm trying to create a simple .NET remoting application that can be accessed over Http through the internet, not internally.
When I get my object through Activator.GetObject and try to perform a method on that object, I get a System.Web.Exception stating basically (401) unauthorized.
Has anyone experienced this and have any tips for me? I'm new to remoting. I tried TCP and couldn't get my router to forward the port correctly.
Thanks.
|
|
|
|
|
Hello
I used VS 2003,
Tools -> Build COmment Web Pages
A file consisting of project namespace is created, when I click on it, it went blank.
I do not understand the reason. Does anyone know about this?
Thanks in advance.
|
|
|
|
|
I'd like my program to look through all folders and subfolders within the location it is run from, to find all instances of the file "cover.jpg". When an instance of the file is found other functions are performed. Can anyone recommend the best way to go about looking through all the folders and sub folders? Should I look through all the initial folders first, then go back and look through the sub folders? or do each branch all in one go? I'm sure this is a widely used function so if there are good guides on this could someone point me to them, I tried searching through them but could not find anything.
Thanks.
|
|
|
|
|
This should do it:
string[] files =
Directory.GetFiles (rootDir, "cover.jpg",
SearchOption.AllDirectories); /ravi
My new year's resolution: 2048 x 1536
Home | Music | Articles | Freeware | Trips
ravib(at)ravib(dot)com
|
|
|
|
|
Would anyone like to recommend a book or Internet-based resource where I could learn to use MSHTML from C#? I need to know how get access to the IHTMLDocument* interface pointers, how to call them and what pitfalls to avoid in the use of unmanaged interface pointers in a C# application. I'm learn-by-example kind of guy, so the more practical examples I can look at the better.
I've been forced into this position by the limited capabilities of the .NET 2.0 Webbrowser control in VS 2005 C# Express.
|
|
|
|
|
Hi,
I need to use maps in my C# desktop application...
I m not getting any solution for the same.
If some one have used the google maps in desktop application then pls guide me how to use google map.
Aur any other alternative.
Thanx
Anuj Kamthan
Software Developer
Solversa Technologies,
Pune - 411007, India.
http://www.solversa.com
|
|
|
|
|
I haven't used them in a desktop app, but it should be pretty simple to do this: you can add a WebBrowser to your form and show the maps inside that as if it were a normal web browser. That way, you can still code to the Google Maps API using javascript.
Optionally, you could write a .NET library wrapper that wraps the javascript API. That would be cool.
You might want to look at this CP article[^] to help get you started.
Tech, life, family, faith: Give me a visit.
I'm currently blogging about: Is Jesus the Jewish Messiah?
The apostle Paul, modernly speaking: Epistles of Paul
Judah Himango
|
|
|
|
|
|
Hiii,
Yes u r right, i have to do something like this only but this wrapper provided for ASP.Net i need to use this in windows based application...
Thanx
Anuj Kamthan
Software Developer
Solversa Technologies,
Pune - 411007, India.
http://www.solversa.com
|
|
|
|
|
I m writing a websevice that will b consume by winforms (C#). evey thing is working fine but i m afraid when I ll give webservice n application to my client that time i can face prb in connectivity with webservice. is ne one tell me how to make it dynamic. like in webforms we can use web.config for dynamic connectivity but in win forms?????
many thanks in advance
|
|
|
|
|
I have a tab control with n tab pages. When I click on a new tab page to change tabs, I want the focus to be on the first field of the new tab page. Currently the focus is on the tab page itself. I have tabStop = false for the tabcontrol but the tab page is still getting focus when I switch tabs. I have also added a "Selected" event handler on the tabcontrol that based on the tab page selected, it gives focus to the first item on the new tab page. The event works somewhat, the item gets focus, momentarily, but then focus goes back to the tab page.
I also have an OnEnter event and I can see the item getting focus, but right after that, the new tab page is getting focus. Is there a different event handler that I should be using? Or do I not have something set up correctly.
TIA
Bob
|
|
|
|
|
Hi All,
I am new to c#.net implementation and i need to implement property grid where few properties are normal ones and few have ellipses and drop down list. All this is implemented and works fine but now i have one more property where on click of the ellipse, form needs to be shown which will have a tree view and based on the selection of nodes comma separated string needs to be set as the property value. Can some one show me some sample code or any kind of help is highly appreciated and Thank you all in Advance.
-Jeevan
|
|
|
|
|
Hi All,
Is there a possibility to do this or not? Atleast if i get answer to this question then i can change or mend my way speaking to my Boss.
This is really critical for me. so please any help is highly regarded and appreciated.
Thanks
-Jeevan
|
|
|
|