|
Butterfly_h wrote: how can I make the database path valid to any system
I'm not sure what you mean. Are we talking an .mdb file here?
|
|
|
|
|
yes an Access database.
I added the access database to my crystal report and located the feilds as it is on the actual form and the printing result is great. But how can I make the program dynamicly find the database for the crystal report if I installed it on the user system?
Regards,
Butterfly
|
|
|
|
|
As the subject says, I need to change the column width in a DataGrid. The problem is that I'm using .net framework 1.1 (Visual Studio 2003). The code is this:
this.dataGrid.DataSource = myDataTable;
//here should come something like: this.dataGrid.Columns["Col1"].Width = 0 or whatever
It's driving me crazy... I can't seem to find a collection of columns...
And another thing: is there a way to set some auto sizing propery for all columns to fit the DataGrid? In VS 2005 that's set easily, but in VS 2003... I just can't seem to find it...
Thanks!
|
|
|
|
|
go for method like this....
private void datagrid_itemdatabound(object sender, system.web.ui.webcontros.datagrideventars e)
{
.....
.....
e.items.cells[column number].width= value;
....
}
and for the datagrid events write this method name for itemdatabound event.
Hope this works!!!
Gautham
|
|
|
|
|
I forgot to say.. I'm creating a Windows Forms application, not a Web one... And I can't get that Items collection... That's the whole problem... But thanks, anyway
|
|
|
|
|
Ok, I solved it... After you set the DataSource property, you have to create a TableStyle, and DataGridColumnStyles. Each column style has to be mapped to a DataColumn from DataTable, and there you can set Width property... So that's it...
Still haven't figured out how to auto size the columns so that they fit into the grid...
|
|
|
|
|
I have been told to write a windows service which 'periodically' checking for messages and application updates from the web service.
The user has the choice to download updates and messages automatically or to be prompted to download them when they are available.
Note: A Message may contain documents.
Now my question is is it the right approach to do this using a windows service or windows app/form.
Please help me out on this.
Thanks
kash
|
|
|
|
|
wrote: Now my question is is it the right approach to do this using a windows service or windows app/form.
I would say a windows forms application that sits quietly in the system tray until it needs to tell the user something. When there is no user logged into the system a windows service will have no one to tell, so its continual checking would be redundant.
|
|
|
|
|
Hi,
I need to develop a PCB(Process Control Block) datastructure managed by OS for applications. I need some info or code regarding this.
Regarding this I need to find out turnaround time, starting time, state etc of two applications.
Thanks in advance
Ali Raza
|
|
|
|
|
Some of that information can be retrieved from a System.Diagnostics.Process class instance.
|
|
|
|
|
I´m working with XML at VS2003.
I have a file called Escola.xml
I´m covering it, i´d like to take the "Text" everytime that it found the element <name>.
Example:
<name>Charles
I want to show "Charles"
Can anybody help me?
Thanks
|
|
|
|
|
From memory, the property is InnerText. How are you iterating over the nodes ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
I´m jrvelloso..
i just changed my name!
take a look
XmlTextReader xmltr = new XmlTextReader("Escola.xml");
while (xmltr.Read())
{
switch(xmltr.NodeType)
{
case (XmlNodeType.Element):
{
if (XmlNodeType.Element == "Name") lstLeitura.Items.Add(xmltr.Value);
break;
}
It´s wrong.. but that´s the idea that I had.
Thanks for helping!
|
|
|
|
|
I guess this is what you're looking for:
XmlTextReader xmltr = new XmlTextReader("Escola.xml");
while (xmltr.Read())
{
switch(xmltr.NodeType)
{
case XmlNodeType.Element:
if (xmltr.Name == "Name")
lstLeitura.Items.Add(xmltr.ReadString());
break;
}
}
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
That´s it man!
Thank you so VERY much!
Cheers!
|
|
|
|
|
I would personally use a XmlDocument and search for the nodes instead of iterating over the entire document, but if the doc is small, your way might be fine.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Hi,
I am new to C# and .Net Framework, can any one please tell how to find index of character in string.
for example: string myteststring = "abc,def";
then here can i find the index of char ",".
Warm Regards,
Mushq
|
|
|
|
|
Use the IndexOf method from the string class
All the best
Martin
|
|
|
|
|
You could try the string's method .IndexOf
VirtualVoid.NET
|
|
|
|
|
How is your response different than the one posted two hours before you?
only two letters away from being an asset
|
|
|
|
|
Mark Nischalke wrote: How is your response different than the one posted two hours before you?
Maybe it took him that long to come up with the solution, so he could not see someone else already answered the question
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
i didn't noticed that someone already answered... don't be silly, everyone can make mistake, or you're the god ?!
VirtualVoid.NET
|
|
|
|
|
Relax man, it was just a joke (my posting is marked as such with intend).
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
Mark Nischalke wrote: How is your response different than the one posted two hours before you?
Actually, it was only one hour and 59 minutes.
--EricDV Sig---------
Some problems are so complex that you have to be highly intelligent and well informed just to be undecided about them.
- Laurence J. Peters
|
|
|
|
|
I developed a windows-based application in C# ,there is a browse button, a textbox and a treeview control on the window, when i click on the browse button i can import managed DLL, the treeview control can display the classes, methods and methods parameter inside the DLL in a tree form, i want to call anyone of the method in a class in DLL at runtime,it is okay for static method but not okay for non-static method,
I used MethodBase.Invoke(object,params) for this.
Please help me so that i can create an object of the specified class and and also call that class method with the help of that class object at runtime in C#.
Thanks.
|
|
|
|