I currently worke on Programm working with the DevComponents.DotNetBar.DockingContainers, those Containers have a lot of functionality. My Problem is now, since i'm working with them as dynamic objects, e.g. a new usercontrol Needs to be shown -> Check if a DockingContainer is empty -> if not create one and put the uc in the new Container, i get several issues that i'm not able to solve.
1. The DockingContainers get deleted from time to time, e.g. uc is not needed anymore -> dispose it and delete the Container.
In this case my dockSite gets shrunk by the amount the Container was.
I have a "Workaround" for that but ist not satisfying as the other Containers are flashing while i resize.
Code for delete given:
/// Deletes the container.
/// <paramname="sender">The sender.</param>
/// <paramname="e">The <seecref="EventArgs"/> instance containing the event data.</param>
/// <exceptioncref="System.NotImplementedException">Something went terribly wrong</exception>
privatevoid DeleteContainer(object sender, EventArgs e)
DockContainerItem _tmp = (DockContainerItem)_currentClickedBar.Items;
PanelDockContainer _tmpPanel = (PanelDockContainer)_tmp.Control;
if (_tmpPanel.Controls.Count != 0)
... // Codeblock that is unfinished and not relevant
//Wenn der Container leer ist kann er einfach gelöscht werden
_dockingPanels.Remove(_dockingPanels.Find(dp => dp.Name == _tmpPanel.Name));
_dockingContainers.Remove(_dockingContainers.Find(dc => dc.Name == _tmp.Name));
_barContainer.Remove(_barContainer.Find(bc => bc.Name == _currentClickedBar.Name));
DockSite _ds = (DockSite)_currentClickedBar.DockedSite;
int _width = _currentClickedBar.Size.Width;
int _height = _currentClickedBar.Size.Height;
//delete the Container
//resize the DockSite
_ds.Size = new System.Drawing.Size(_ds.Size.Width + _width, _ds.Size.Height + _height);
_currentClickedBar = null;
2. Another Problem i have is that if i undock a Container, dock it into another one everything gets pretty messed up as i can't undock it out of the Container again and the old one stays inoperable for some reason.
It wasn't inoperable, i just messed up the Text property of the DockingContainerItem, therefore i couldn't see it in the "Tabs"
Here the other code for my Containers:
/// Creates the named docking container.
/// <paramname="NameContainer">The name container.</param>
/// <paramname="NameBar">The name bar.</param>
/// <paramname="NamePanel">The name panel.</param>
publicvoid CreateNamedDockingContainer(string NameContainer, string NameBar, string NamePanel)
// Create the new Bar and set the specific Settings
Bar newBar = new Bar("neuer Container");
newBar.Name = NameBar;
newBar.LayoutType = eLayoutType.DockContainer;
newBar.GrabHandleStyle = eGrabHandleStyle.Caption;
newBar.Stretch = true;
newBar.CanCustomize = false;
newBar.CanAutoHide = false;
newBar.MouseClick += bar_Click;
newBar.BarUndock += barContainer_BarUndock;
//Create the dockContainerItem
DockContainerItem tempDock = new DockContainerItem();
tempDock.Name = NameContainer;
//Create the dockingPanel
PanelDockContainer tempPanel = new PanelDockContainer();
tempPanel.Name = NamePanel;
tempPanel.MouseClick += panelDockContainer_Click;
//Create a new Control for the ContainerItem and reset it to the panel
tempDock.Control = new Control();
tempDock.Control = tempPanel;
//add the dockContainer to the bar, the bar to the dotNetBarManager and set the dockposition
Any help or experience with those DockingContainers would be appretiated
C# / VS2013
if(this.signature != "")
MessageBox.Show("This is my signature: " + Environment.NewLine + signature);
MessageBox.Show("404-Signature not found");
After you assign the DataSource to the Report, I want to assign to the label, textbox, xrTableCell1,... Report should I do? or I want to DataBinding, currently running it does not appear at all records
// After successful connection Northwind// Create an empty report.
XtraReport1 report = new XtraReport1(); string sql = "select * from Customers";
DataSet ds = new DataSet();
SqlDataAdapter da = new SqlDataAdapter(sql, cnn);
report.DataSource = ds;
report.DataAdapter = da;
report.DataMember = Customers; // Table Customers of Northwind
I am developing a C# Windows Application which will run with MySQL backend. I want to have a server application running on the server to do few server tasks. It will be great if my server application will also check the license for me which means it should be running all the time as service or actually running on system tray.
But how can I make sure the application is always running and if not then user won't be able to connect to the server? so the client will do the check for example? or any other idea!
Where is your problem?
The client application contacts your LicenseServer during its start. Windows Service is a good choice for that server application; there are options for re-starting a windows service if it happened to crash. If the client does not get a connection to the server, or the server does not issue a license to it, have it showing an error message and quit. You may also set a timer (on the client) to check for the license every few minutes and stop it if no license can be retrieved.
For client-server communication, there are several options like WCF or .Net Remoting.
What "time" are you talking about? Be specific.
If you are saying that time to execute the application will be longer after splitting, then when you create two exe's your application will be two, and will be launched separately ? isn't it?
And time will hardly matter in this case.
Do not forget to comment and rate the article if it helped you by any means.
Are your 'seniors' developers or managers. If they are developers then ask them to explain the business reason why they need to be in 2 exe's. If they are managers then you need to explain the design is invalid and they should leave the design to the architect or the developer.
Never underestimate the power of human stupidity
My direct senior is a senior developer.
Actually our project deals with hospital patients and their orders.
In first form patient will be displayed according to their category.
When a particular patient is clicked His/Her order form should be displayed.
Its already developed.
The clients abroad asked to separate Exe's to make Main EXE free from Order EXE else if any errors happens the main EXE should not be corrupted.
That's an X-Y-Problem. As usual. There is a problem, someone has an idea of how to tackle it, and experiences a problem on that way - now the question is how to continue that way.
Instead of the correct question: what does the customer really need, and - next (nto same!) question - how can that be accomplished. A totally common problem in requirements engineering....
I'm not familiar with ABAP at all and I'm trying to automate a SAP report for my job.
At the momment I gotta open SAP (manually of course), login, call the transaction, add some parameters to it, execute it and download the first report. After that I have to work it around (thing that I already automate, so it's not a problem) but then I have to get some other parameters from it and call another transaction to execute with the new parameters that I got from the first report... And so on 2 more times.
My problem is that, after automating all the excel related stuff with C#, I can't find a way to interact with SAP R/3 to login, call the transaction, execute with the parameters and get the report.
Can somebody give me a hint about this?
I googled for a couple of hours and all I found out is that I may have to work with RFC's and BAPI's but I still can't figure out how to do it nor how to use these properly (if I'm right that I have to)
first time poster.
I have been programming for quite a while (and used code project quite a lot) but have so far avoided to use XML files.
Now I have to and while I can parse the data, and read values, it still escapes me how XML is the new, so easy way to store ans retrieve data.
I have a XML structure that basically contains a list of files on a hard drive and while I can imagine all kinds of complicated loops to list all paths and files in a list box, I cannot find an easy way to accomplish that.
(I which I could upload an image of the structure
so here it is a code.
The length of the path (Contained folder) is totally arbitrary of course:
XML really wasn't designed to be a database if that's what you mean by "store and retrieve data". It's more intended for the formatting, serialization, transmission and transformation of data. It just so happens that XML is a text format that happens to be very easily stored on any storage medium.
In any case, I think your schema could be laid out a bit better. Such as:
A better option would be to skip trying to worry about the details of the XML file and worry more about your class definitions that can be serialized into an XML file. That way you can just build an object graph with the data you're tracking and then just send it to the XmlSerializer and it'll create the XML file for you.
The same serializer can be used to reconstitute the graph from the XML data it wrote.