DavidThi808's Q&A profile
.NET Development how to use where clause in data adapter
SqlDataAdapter AdapObj = new SqlDataAdapter("Select * from Employees WHERE employeeid = 1", myConnection); hi im using the above code, but it is genarating an error, I know the way i have used the where clause is wrong, can somebody please show me how to correct the above code. thanks in advance I presume you are learning/ testing due to the use of a textbox for your SQL Select statement. You should not pass TSQL to your DB from a textbox. You should use SQL Command Parameters whenever possible. You would probably be better served if you work on declaring the command and connection objects independently, ensuring correct disposal etc. Then you get a better understanding of the i ...Show All
Visual Studio Team System Adding the Build_Type field to the TFS Builds Report...
HI, Reporting Newbie... I wanted to do what i thought was a simple thing...just add an extra field to an existing report... I setup a new Reporting Project, added the Datasources and downloaded the Builds.RDL file from the Report configuration page. I then added a field: < xml version="1.0" encoding="utf-8" ><Field xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance " xmlns:xsd=" http://www.w3.org/2001/XMLSchema " xsi:type="Level" UniqueName="[Build].[Build_Type].[Build_Type]" /> called Build_Type. I added a column to the designer & assigned the above field. When I upload and run the report through the Reporting Services Web page, I get an ...Show All
SQL Server Trace stored proc calling event
I wanna use the SQL Profiler to trace some stored proc. calling events, such callings are originated from an .NET or Java application. Which event, RPC:Starting or SP:Starting, should I use Hi, look in the MSDN Online Library. It describes the events in detail. RPC means RemoteProcedureCall, SP mean Stored procedure. These event are for showing the information which is sgiving when any of these events occur. HTH, Jens Suessmeyer. --- http://www.sqlserver2005.de --- ...Show All
SQL Server Problem passing columns as parameter!
Dear friens, I need to pass a column as a parameter in my query. I did this: ALTER PROCEDURE [dbo] . [GD_SP_GET_UsersByDIR_COD] @Direccao nvarchar ( 11 ), @prmFieldName nvarchar ( 25 ), @prmFieldValue nvarchar ( 25 ) AS BEGIN IF @prmFieldValue = '*' OR @prmFieldValue = '' BEGIN SELECT TOP ( 100 ) PERCENT dbo . ADServico_User . UserID , dbo . ADUser . UserName AS Nome , dbo . HARDWARE . New_Computername AS Computername , dbo . ModeloPC . MOD_ModeloPC AS ModeloPC , dbo . Monitor . MON_Monitor AS Monitor , dbo . Status . StatusNome AS Status , dbo . HARDWARE . Migrada AS Intervencao , dbo . HARDWARE . MigraViaChange AS [Migrada via Change] , dbo . HARDWARE . S ...Show All
.NET Development Access Excel File On Different Server ** Help Urgently Needed Plz **
Hi all, I am trying to link to an excel file on a web directory on a different server but can't seem to get access to the file, This is the code i'm using: Dim sConnectionString As String = "Provider=Microsoft.Jet.OLEDB.4.0;" _ & "Data Source=\\fse1web563\fsetrain$\public\Equiv\FSE_PAS.xls;" _ & "Extended Properties=Excel 8.0;" Any ideas, help appreciated OK, so your web application has been configured for Anonymous access only Is the Excel file on the same server as the web application or is it on a remote resource ...Show All
SQL Server How to get "Current Week" details in MDX query
We are trying to migrate TFS (RC) warehouse report to TFS (RTM) warehouse. My query in TFS (RC) is using “[Current Week]” for getting the current week details. SELECT NON EMPTY {([Measures].[Current Work Item Count]),([Measures].[tasksendedthatweek]),([Measures].[tasksactuallyendedthatweek]),([Measures].[tasksactuallystartedthatweek])} ON COLUMNS, lastperiods (5, strtomember ( ' [ HP_Apprise_PM_Task_StartDate1].[Year Week Date].[Week].[Current Week] ' )) on rows FROM [Current Work Item] where { strtoset (@TeamProjectTeamProject)} The above query is failing in TFS (RTM) reporting (its not giving any error, but am not able to get the data). When I replaced “[Current Week]” with the specific Week date, am able ...Show All
Software Development for Windows Vista How to start process in session before user logs on?
I have a need to start a process in a session before the user logons on. On XP I used a Windows Logon Notification Package to do this. When a new session was created, Winlogon.exe in that new session called my WLNP and it was able to start the process before the user logged on. The process is used to support smart card logons for that session. I'm trying to find out how to do something similar on Vista. I know logon notification packages are no longer supported. I know how to write a service to get session creation notification, but I don't know how to start a process in the new session before the user logs on. Is there a function I can use to start a process in another session If so, I could have my session tracking sevice start th ...Show All
Smart Device Development OpenFileDialog Problem
Hi, I am using the OpenFileDialog to locate a file called "data.csv", located on my Pocket PC. When I place the file in "My Documents\Taxes "I can locate this file and I have no problems. When I place the file in "My Documents\Taxes\Data" the OpenFileDialog can`t locate the file. It even can`t locate the "Data" subdirectory in "Taxes" directory. As I noticed the OpenFileDialog can`t browse deeper than one subdirectory of "My Documents". If anyone had this problem could you please tell me a solution. ...Show All
.NET Development Using a Dynamic Assembly built using Reflection.Emit at compile time
I have built a dynamic assembly using very similar code to the sample in the TypeBuilder documentation. I am saving the dynamic assembly by calling AssemblyBuilder.Save. http://msdn2.microsoft.com/en-us/library/system.reflection.emit.typebuilder.aspx Can I use this dynamic assembly at compile time I have added a reference to it in my project, but I am unable to get any intelisense on it, and any use of the types or namespaces in the dynamic assembly produce compile errors. I have run peverify.exe against the saved assembly without error. Andrew Feldman wrote: Can I use this dynamic assembly at compile time I have added a reference to it in my project, but I am unable to get any intelisense on it, ...Show All
.NET Development Net 2.0 install errors
I have been trying to install the .Net Framework 2.0 on a windows 2000 computer, I keep getting the following error at various points during the install. "The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2905." I have used this install on other computers and it worked fine. I have also downloaded the dotnetfx.exe again, only to get this error again. What is a 2905 What can I do to get this installed Hi Kevin, Could you please zip the 2.0 install logs (starts with dd_*) from %temp% folder and send it to us. Thanks, Manisha. ...Show All
SharePoint Products and Technologies keep footer at bottom of page?
what do i need to do or add in my master page to make the footer stay at the bottom of the page depending on page content my footer will move up or down... ...Show All
Visual C# How to clone List<IBaseClass> that contains derived classes?
If I have the following object model: interface IBaseClass { object Clone(); } interface IDerivedA : IBaseClass { object Clone(); } interface IDerivedB : IDerivedA { object Clone(); } interface IDerivedC : IDerivedB { object Clone(); } For each interface there is a concrete class that implements the interface. For example: class BaseClass : IBaseClass { public object Clone() { ....} } class DerivedA : BaseClass, IDerivedA { public object Clone() { ....} } ETC..... class Container { List<IBaseClass> _items; // Copy c'tor public Container (Container containerIn) { this._items = new List<IBaseClass>(); IBaseClass itemClone; foreach (IBaseClass bc in containerIn._items) { ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Right forum? Where to obtain the source code for the XFest 06 Exploiting D3D 10 - Adv Tech talk by Shanon Drone
Is the source code available I tried searching the forums and the web to no avail. If you mean GameFest instead of XFest (which, as I understand it, is now dead) then I'm not aware of a public download for any source code. You could always email directx@microsoft.com to see if they're prepared to let you have it. But, based on them stripping some videos out of the GameFest slides, I'd imagine you'd had to of been there to get any additional material... hth Jack ...Show All
Game Technologies: DirectX, XNA, XACT, etc. need to get graphics device in a library
Im making a game library and i need to know how to find out the graphicsdevice I saw another post that said to use: IGraphicsDeviceService gds = game.GameServices.GetService< IGraphicsDeviceService >(); but that was for a game component, when trying to use that code in my regular class, game doesn't have gameservices under it. does anyone know how to get the above code to work for a game library The above should work outside of components: void MyCoolMethodOnSomeClassInMyLibrary(Game game) { IGraphicsDeviceService gds = game.GameServices.GetService ... } You might consider just passing around the IGraphicsDeviceService interface instead so callers can get the service however the ...Show All
Visual Basic passing a function's name to another function (or sub)
Dear all when programming in FORTRAN I was used to pass the name of a function to another sub or function. With VB.NET I have some problem. Suppose I have several functions, named F1,F2, F3,.., and that I have to perform some common task on these functions (for instance numerical integration). Well, I wish to manage things in such a way to have a library function or subroutine (to do integration) and to call it passing various parameters 'and' a function name ( e.g. F3 ) to perform the integration of F3 . In other words I wish something similar to this fragment of code to work (declarations and initialization omitted): module main integ1= integration(a,b,step,F1) integ2= integration(a,b,step,F2) end module m ...Show All
