Hello I have a Windows Service developed in C#. On startup it gets a Instance of a simple Gatewayobject. And make it available on the TCP port 13101. On a WinXP Professional maschine there are no problems starting it but on win2k it only starts in 2 out of 10 times. I have a WindowsForm app that do the same thing as the WindowsService and there are never a problem with that app on win2k or winXP. What can be the problem?:confused:
Knappen
Posts
-
Problems starting a WindowsService on win2k Server. -
dynamically assign tag propertiesWhat I would have done is to build the list of buttons in the Page_Load method. And have a PlaceHolder tag in the HTML-part (aspx-page). The Placeholder component is god as it dosn't leav any html-tags.. Then I can do whatever complicated task in the code-behind. code-behind example:
protected Placeholder plcButtons private void Page_Load(object sender, System.EventArgs e) { Button btn; for(int i=0;i<10;i++) { btn = new Button(); btn.Text="go" btn.OnCommand="GO" btn.CommandArgument= i plcButtons.controls.add(btn); } }
-
Nested Repeaters with datasourceHelo I have a Repeater that prints content from a DataSet. But for each loop I want to have a second Repeater printing the relation-children of the row in the DataSet. The DataSet has to Tables and 1 to n relationship between them. How to set the DataSource for the nested Repeater ???:confused:
-
Formating the xml-output from a DataSet:-DGreat! That was the best and eazyest solution. To solve it with XMLSchema created alot of overhead and puluted the xml with alot of xmlns-information...
-
Formating the xml-output from a DataSetHelo :~ I know that I have done this before, controling how the output-xml is formated. The default i:
<NewDataSet>
<table>
<col1>val</col1>
<col2>val</col2>
</table>
<table>
<col1>val</col1>
<col2>val</col2>
</table>
<NewDataSet>But I want it to be:
<NewDataSet>
<table col1="val" col2="val">
<table col1="val" col2="val">
</NewDataSet>What is the property to set ????
-
Formating the xml-output from a DataSetHelo :~ I know that I have done this before, controling howe the output-xml is formated. The default i:
<NewDataSet>
<table>
<col1>val</col1>
<col2>val</col2>
</table>
<table>
<col1>val</col1>
<col2>val</col2>
</table>
<NewDataSet>But I want it to be:
<NewDataSet>
<table col1="val" col2="val">
<table col1="val" col2="val">
</NewDataSet>What is the property to set ????
-
Formating the xml-output from a DataSetAnd the xml visible..... The default i:
<NewDataSet>
<table>
<col1>val</col1>
<col2>val</col2>
</table>
<table>
<col1>val</col1>
<col2>val</col2>
</table>
<NewDataSet>But I want it to be:
<NewDataSet>
<table col1="val" col2="val">
<table col1="val" col2="val">
</NewDataSet>What is the property to set ????
-
Implementing the SelectSingleNode for NetscapeHelo Im trying to add the SelectSingleNode funktion supported i MSXML to Netscape/Mozilla. By implementing a prototyp-funktion that wraps the Moz corresponding native-implementation. Has any one done this ore a suggestion on artikels. The idea is not to loop the XMLdocument finding the corresponding node to the xpath, but to use the Mozilla xpath funktionality. :cool:
-
Saving Form-data to DatabaseThat's not what you would have figured if you are a old ASP-programmer like me. But It's kind of cool that I only hav to populate it ones. Thanks
-
Saving Form-data to DatabaseHello I’m perhaps a bit old fashion when it comes to ASP. I try to build a Form populated whit Database data (from a Stored Procedure) and when I click the “save” button the data will be saved to the database thro a Stored Procedure. But it won’t work, it looks as if the load event is fired before the button.click?????
-
LEFT OUTER JOIN leaves rowsI have to tables 1: Main table 2: Text table the relation is one to many. If there isent any matches in the text-table i want the post from the main-table My query: (Swedish columname´s) ------------------------------------ SELECT arrProdKat.prod,arrProdKat.lev,arrProdKatText.sprak, rubrik =CASE WHEN(arrProdKatText.sprak is null) THEN arrProdKat.rubrik ELSE arrProdKatText.rubrik END, info =CASE WHEN(arrProdKatText.sprak is null) THEN arrProdKat.info ELSE arrProdKatText.info END FROM arrProdKat LEFT OUTER JOIN arrProdKatText ON arrProdKat.arr=arrProdKatText.arr AND arrProdKat.lev=arrProdKatText.lev AND arrProdKat.prod=arrProdKatText.prod AND arrProdKat.arrKat=arrProdKatText.arrKat WHERE arrProdKat.arr=@arr AND arrProdKat.arrKat=@arrKat AND(arrProdKatText.sprak=@sprak OR arrProdKatText.sprak is null) ------------------------------------------- The result dont find the post in the main-table if ther are child-posts in the text-table, even if they dont equals @sprak.
-
ODBC.NET and ExcelHello I want to open a Excel-file in ADO.NET as a DataSet. I downloaded the ODBC.NET. and made a DSN-file pointing to the excel-file. Then I made a connection to the DSN-file in the Server-explorer. So far so good. But when I try to use the generated connectionString opening a OleDbConnection. I get the following error: The .Net Data Ole DB Provider(System.Data.OleDb) does not support the MSDASQL Provider, Microsoft OLE DB Provider for ODBC Drivers. ----- My connectionString looks like this: Provider=MSDASQL.1;Persist Security Info=False;Extended Properties="DBQ=G:\costumers\foretag.xls;DefaultDir=G:\costumers;Driver={Driver do Microsoft Excel(*.xls)};DriverId=790;FIL=excel 8.0;FILEDSN=G:\costumers\foretag.dsn;MaxBufferSize=2048;MaxScanRows=8;PageTimeout=5;ReadOnly=0;SafeTransactions=0;Threads=3;UID=admin;UserCommitSync=Yes;" How do I do this?
-
An array of all Selected rows in a DatagridHelo I want to get a array off the index on all rows that are selected.. Whitch property chould I use?
-
Override events in TreeView:cool::-DHelo If any one is intressted - I solved the problem..... What I did: A event handler tied to the MouseUp Private Sub OnTreeViewMouseUp(ByVal sender As Object, ByVal e As MouseEventArgs) Handles TreeViewA.MouseUp Dim pt As Point pt = New Point(e.X, e.Y) recursNodeSearch(pt, TreeViewA.Nodes) End Sub And the Sub that do the trapping: Private Sub recursNodeSearch(ByVal pt As Point, ByVal nodes As TreeNodeCollection) Dim nNode As TreeNode For Each nNode In nodes Try If nNode.Bounds.Top <= pt.Y And nNode.Bounds.Bottom >= pt.Y Then 'This check the row, is you want to check the exact location. ' If nNode.Bounds.Contains(pt) Then '=================================== TreeViewA.SelectedNode = nNode Exit Sub ElseIf nNode.IsExpanded Then recursNodeSearch(pt, nNode.Nodes) End If Catch End Try Next End Sub
-
Insert a [Enter] in a StringYes in VB6 but in VB.NET it´s System.Windows.Forms.Key.Return ---- The I moved on to RichTextBox and found this nice sample - using XHTML to RTF-format a RichTextBox http://www.gotdotnet.com/userarea/keywordsrch.aspx?keyword=xhtml (XHTML is well-formated HTML => XML) no unclosed tags (ex:
is in XHTML
) -
Override events in TreeViewHelo One problem whit the TreeView in VB.NET, is that right-clicking don´t select the node. Im trying to add Context-menu´s to my Node´s. But I cant figure out a way to catch the node that was right-clicked. :confused:
-
Insert a [Enter] in a StringI solved it, by using a RichTextBox. Then concating chr(13) into a String, ended upp showing return´s. (simple TextBox´s dont do the trick)
-
Problem whith System.Windows.Forms.Keys.ReturnIm trying to insert a Return in my textBox but all I´m end upp whit i a ugly "13" -------------------- for i = 0 to ubound(aryInfoText) txtInfo.AppendText(aryInfoText(i) & " " & System.Windows.Forms.Keys.Return) next -------------------- X| Baaaa
-
Insert a [Enter] in a StringHelo Im new to VB-programming but im a good on ASP (VB-script). In ASP I inserted a chr(13) if i wanted a [enter] in my HTML-kod. But concating a chr(13) in a String ends up whit a square. HELP !!!
-
Error when trying Update on SQLDataAdapter:mad:Helo What´s wrong when this Error commes up? System.InvalidOperationException: Update requires a valid UpdateCommand when passed DataRow collection with modified rows. at System.Data.Common.DbDataAdapter.Update(DataRow[] dataRows, DataTableMapping tableMapping) What im trying to do is Updating a SQLServer Table with a offline updated Dataset. The Dataset is build by the .copy method. And the first table is identical to that on the SQLServer