|
From what I understand you are trying to do, you are trying to set the size of your panel to be equal to that of the contents inside of it?
You can loop for that
int i = 0;
int max = panel1.controls.items.count -1;
panel1.height = 0;
while i <= max
{
panel1.size += panel1.controls.items.i.height;
i++;
}
'edit
you can suspend your layout so you don't see it resize
|
|
|
|
|
Dear,
Can anyone give me a code that can print DataGridView in C#.NET 2005?
Socheat
|
|
|
|
|
I can't but Google can
|
|
|
|
|
Try rent-a-coder or google.
Jeez, we WORK for a living and you want us to give out da codz for free? Ask your Mumma about the meaning of the word 'polite'
Panic, Chaos, Destruction.
My work here is done.
|
|
|
|
|
Socheat.Net wrote: Can anyone give me a code
Once you say that, the answer automatically becomes "No", regardless of what the rest of the question or post says. You've been around here more than long enough to know that.
|
|
|
|
|
I posted a question a little while ago about how to link a treeview to a list view.
What i actuli was trying to say is "How Do you Binding a ListView to a TreeView"
|
|
|
|
|
Will you not do this. Post one question about a topic and then stick with it. Don't spam the boards.
|
|
|
|
|
Try keeping to one set of posts and put a useful topic. As far as I can remember, you have been asking this for the last 2 days and have been given loads of useful hints, so your best bet is either get a few books on programming in general and C# in particular, or try another career.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
Hi
I am new to c# and im trying to link a treeview to a list view.
Thanks in Advance
|
|
|
|
|
And do what? One of the first things you need to learn as a developer is how to lay out your requirements. From your question, I have no idea what actions you expect.
|
|
|
|
|
Oh Sorry.
Im trying to make it so that when click on a node in the treeview it will display in the treeview.
|
|
|
|
|
One way to do this is to use the Tag to store the row in the TreeNode, and then find the same item in the ListView where you will also have stored the object in the Tag. This isn't a particularly elegant way, but will work for small solutions.
|
|
|
|
|
Hi,
what do you mean exactly by "link a treeview to a list view"? If you mean updating the listview when you click at the treeview, than you have to register for the SelectedIndexChanged (or something similar) event of the treeview and update you listview within the event handler.
Regards
Sebastian
|
|
|
|
|
Yes that what i meant
Thank You
|
|
|
|
|
You actually have to write code to do it (I know, that may be too close to being an actual programmer). There is no such thing as "linking" a view to another view. You can attach the same data source to both views.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
Hi,
Is WPF is feasible enough to develop very complex games like motogp .
?
“You will never be a leader unless you first learn to follow and be led.”
–Tiorio
"Coming together is a beginning, staying together is progress, and working together is success." Henry Ford
|
|
|
|
|
Lol, no. Those are written in native C++ and use DirectX.
|
|
|
|
|
You should look at DirectX (or OpenGL) for this - possibly you might want to look at XNA.
|
|
|
|
|
SO IT IS ONLY FOR CREATING NEW INTERFACE LIKE COLORFULL BUTTONS LIKE THAT
“You will never be a leader unless you first learn to follow and be led.”
–Tiorio
"Coming together is a beginning, staying together is progress, and working together is success." Henry Ford
|
|
|
|
|
Please don't shout - and no it's not. Well not quite. It is about creating new interfaces, but it's a lot more than just colourful buttons.
|
|
|
|
|
WPF does use directx to render it's 3d graphics, so does use hardware acceleration, but it is not intended as a games platform. It does not support all the 3d operations you will need to build a decent 3d engine.
If you are looking to write games you should look at XNA[^] (XNA Creators club[^]). It's a framework specifically intended for games. Your other options are DirectX[^] or OpenGL[^]. Both are high end hardware accelerated graphics/media libraries. Both are generally used with c++ rather than .net though. Alternatively, there are plenty of other free/open source 3d engines that you can google for - some are specifically designed for use with C#.
Simon
|
|
|
|
|
Sorry... WPF is only for powering presentation layer of biz apps... not "motogp" type games
You should rather choose an existing game engine... that in turn depends on the type of games you wanna write... for instance, for FPS games you might wanna use Unreal engine or Quake3 engine.
Read this article to know more!
http://en.wikipedia.org/wiki/Game_engine[^]
Usually these engines take care of rendering the texture and adding effects and to some extent, the AI coding also. But for defining your own texture, you might either use a software (like Maya) but for most scenarios, you can search for textures online and use them in your game.
|
|
|
|
|
Hi
I am using Visual Studion 2005 and C# to create a Windows application.
I used the designer to bind a DataGridView to a MS Access database using a BindingSource. In the designer the correct column headers are displayed now on the DataGridView. When I run the application the correct column headers are still displayed, but there is no data displayed. When I preview the data on the smart tag of the DataGridView within the designer it shows me that there is data in the relevant table inthe database.
When I have the DataGridView directly on the Windows Form then it displays the data, but I would like the DataGridView on a UserControl that I then add to the Form at runtime. On the UserControl the DataGridView does not display the data.
Any ideas?
Thanks.
Kobus
modified on Thursday, October 16, 2008 3:30 AM
|
|
|
|
|
Why don't you post the runtime code that you used?
Anyway, did you call the DataBind() method on the grid view
this.[gridViewName].DataSource = [dataSourceName];
this.[gridViewName].DataBind();
|
|
|
|
|
what do you got there? meaning code!!!
DataGridView is a gentleman, accepts allmost everthing, doesn´t need a 100% fit dataset.
Try to put DGV inside the form (not inside usercontrol) just to check if is about delegates, if doesn´t works either your code is wrong
nelsonpaixao@yahoo.com.br
trying to help & get help
|
|
|
|