BillK28's Q&A profile
SQL Server Report parameter with datetime
Hi, Anyone can help me I created a store proc with @startdate and @enddate in query analyser - I run it as Exec SP_Admission '2006/01/01','2006/01/25' and it is ok. Then I created a report in VS2005 and set the parameter as datetime in report parameter. if I manually force to fill startdate and enddate with ‘yyyy/mm/dd’ format in preview, it works. However if I choose the date from the given calendar(Date Time Picker), it doesn’t work it is said that "The value provided the report parameter 'enddate' is not valid for its type. Of course it not valid because it always ...Show All
SQL Server Server Does Not Exist or Access Denied ConnectionOpen[Connect]
Server Does Not Exist or Access Denied ConnectionOpen[Connect] Help please, I'm stuck. I get the above message trying to add a new SQL Registration to Enterprise Manager. I've installed/uninstalled 3 times, all with the same result. EM sees it to register, it is the same name as my box, which is what I was expecting. Install went without problems each time. TCP/IP is enabled. I've searched the forums looking for this problem but have not come across another situation such as this. I don't have a clue of as to what to check next. Thanks in advance to anyone who can help me. OS - XP Pro, S ...Show All
SQL Server Cannot run job created by SMO
I've create a SQL Agent job using C# SMO to process an Analysis Service Database (see code below). When I tried to start job from Management Studio, I get the following error message...any ideas TITLE: Microsoft.SqlServer.Smo ------------------------------ Start failed for Job 'Schedule Job OLAPProj'. For help, click: http://go.microsoft.com/fwlink ProdName=Microsoft+SQL+Server&ProdVer=9.00.1314.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Start+Job&LinkId=20476 ------------------------------ ADDITIONAL INFORMATION: An exception occurred while executing a Transa ...Show All
Smart Device Development Run an executable as a background service
In Compact Framework 2.0, I want to run a 'console application' as a background service. Here is the code I have: class Program { static void Main( string [] args) { BackgroundTasks bt = new BackgroundTasks(); while ( true ) { System.Threading.Thread.Sleep(10000); } } } I just want the object of BackgroundTasks to run forever (listening for events), but I feel that causing the main thread to keep sleeping isn't the most efficient way And yes, I can do this nativally with an extension to services.exe, but I want managed :) Thanks in advance, Andrew FWIW, getting any thread to go to sleep ...Show All
SQL Server Problems with LOOKUP component (repost)
Hello, Can anyone address these: http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=142849&SiteID=1 http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=142837&SiteID=1 -Jamie Jamie, It does make sense that you can't override the sql statement for a lookup component since you would typically connect to a relatively static table to import in a related column. My example would be to pull in a State's full name when the source file only has a State code (NY --> New York). What are the circumstances for which you need to override the sql statement You could try using a stored procedure as the SQL command and passing i ...Show All
Visual Studio Express Editions Lesson 8: Working with the GridView and FormView
I have follow this lesson 8, by creating GridView and FormView, however I cannot do any editing or deleting my record. At the sametime, I have another question. There are two tables which need to be combine to insert new records, and update records. How do I do As I have use "INNER JOIN" in my SELECT statement, but there is nothing when click on 'edit' / 'delete' / 'new'. Kindly help! Thank you. Hi Androidi, you mentioned in your reply that I have to go to the property (aka settings) that enables updates to backing DB. Can you tell me how, and where Please help!!! Thanks. ...Show All
Visual Studio Team System TF30177: Team Project Creation Failed
I am trying to create my first Team Project and this is the error I'm receiving from the wizard: Error Unable to connect to the specified source control server on the Team Foundation Server localhost. Explanation The Team Project Creation Wizard was unable to connect to the Team Foundation Server {0}. Without a connection, the wizard was unable to create the team project root directory on the server. User Action Contact the administrator for the Team Foundation Server {0} to confirm that the server is available on the network. Also, you might find additional helpful information in the project creation log. The log shows eac ...Show All
Visual Studio Failed to open a rowset
I'm developing in Visual Studio .Net 2003 using VB. I'm trying to create a report that draws data from a MSSQL 2000 Server, I have created many other reports in the same project that connect to the same database without having any problems. However, this report is giving me an error, the message only says "Failed to open a rowset". I've also placed a try catch around the line of code which loads the report but it did not raise an error.I'm using the VS 2003 built in Crystal Reports and Viewer. I fanyone can shine any light on why this is happening please do. Thanks, Alberto. ...Show All
Visual Studio 2008 (Pre-release) Many-to-many relationship keys in DLinq
When mapping a many-to-many relationship, if the two foreign-key holding fields on the joining table are marked IsIdentity="true" then DLinq throws an error when attempting to traverse the relationship: A first chance exception of type 'System.InvalidOperationException' occurred in System.Data.DLinq.dll at System.Data.DLinq.ProviderBase.DeferredSourceReader`1.QueryableLink.BuildQuery() at System.Data.DLinq.ProviderBase.DeferredSourceReader`1.QueryableLink.get_Expression() at System.Data.DLinq.ProviderBase.DeferredSourceReader`1.QueryableLink.GetEnumerator() at System.Data.DLinq.EntitySet`1.GetEnumerator() at LinqManyToMan ...Show All
Visual Basic extra records add in multiple query insert in vb6
we are using vb6 and adodb when we execute an insert query ie, sql = "SET NOCOUNT ON ; " sql = sql & " INSERT foo(foo) SELECT 'A' ; " sql = sql & " Select @@identity as RecID ; " set rec as new adodb.recordset with rec .source = sql .open end with after the execution of this code we are getting 3 new records of course we are getting the last record identity which is ok but the extra 2 records are a problem. if i run the insert query by itself it will work just fine Any ideas would be helpful Thanks Mark Update to solve our problem we changed ...Show All
.NET Development DeriveParameters with Provider-Independent Data Access
Well the Provider-Independent Data Access is quite good in ADO .NET 2.0 My only problem with it and what makes it somehow useless is that DbCommandBuilder does not have an implementation for DeriveParameters... Now My code goes: ------------- DbProviderFactory DbProvider = DbProviderFactories .GetFactory( "System.Data.SqlClient" ); DbConnection dbConnectionObj = DbProvider.CreateConnection(); dbConnectionObj.ConnectionString = ConnectionString; DbCommand dbCommandObj = DbProvider.CreateCommand(); dbCommandObj.Connection = dbConnectionObj; dbCommandObj.CommandText = storedProcedureName; dbCommandOb ...Show All
Visual Studio Express Editions Can't assign a property from a module
Hello I have a form called Mainform and a module called module1. On the form, there is a statusbar with a label and a progressbar. Now I have this code in the module: '// Place a progressbar an our statusbar Public Sub provide_status( ByVal text As String , ByVal complete As Integer ) Mainform.ToolStripProgressBar1.Visible = True Mainform.ToolStripStatusLabel1.Text = text Mainform.ToolStripProgressBar1.Value = complete End Sub '// Please call this when your process finishes Public Sub status_finish() Mainform.ToolStripProgressBar1.Visible = False End Sub I call the f ...Show All
Visual Studio Express Editions Project Location is not trusted
Hi All, I have Visual C# 2005 express edition installed on my computer and I'm having trouble with non trusted projects. All my projects are saved in the default location (my documents\visual studio 2005) yet, if I save a solution I received via email in that folder and try to open it in Visual C#, it complains that the location is not trusted. All other projects created within Visual C# 2005 work fine. I looked at the sln and csproj files but couldn't find anything that would justify the different behaviors. Any clue what's going on Any help greatly appreciated. Thanks. After for a while, ...Show All
Visual Studio Express Editions Subtraction of a decimal less then 1
I am not sure if anyone else had this problem, if so please help... While writing a simple function that holds the equation: bVariable = 1 - aVariable (where: 0 < aVariable < 1) Every so often a nasty little bug showed its head. I have used every number decleration (keeping both the same). My problem is that the code works, but the value calculated is wrong! When "aVariable" is equal to 0.94, the value calculated for "bVariable" becomes 0.060000000000000000000001 This calculation error only shows up when "aVariable" has the values: 0.94 or 0.97 It is just like the error in win 3 ...Show All
Visual Basic How can I change a DataGridView Fontsize in VB.Net at runtime
Is it possible to change a datagridview's fontsize at runtime I have an application that is designed to run on a 1024 x 768 screen. However it will fit on a 800 x 600 screen if I reduce the fontsize. I have determined the screen resolution using the screen.primaryscreen.bounds.size.tostring function I tried this: Me .RatesDataGridView.Font.Size=8 but it is readonly. Yeah you can also do it without the lable by saying me.ratesdatagridview.font = new Font("Arial", 10, FontStyle.Bold) (the enum might be wrong, can't remember). Basically Font.Size is readonly, but Font isn't. ...Show All
