IamHuM's Q&A profile
SQL Server Datediff and Record navigation
Hi: I need help to find the difference between two times within the same table as follow For every alarm incident (alarm will repeat within the table at different times) Alarm acknowledge time: AkTime = AkAlm – InAlm Alarm repair time: ReTime = OutAlm – Akalm Alarm DownTime: AdtTime = OutAlm – InAlm The table contains a decent number of records (> 10,000,000) and is indexed by the timestamp. The table looks like this: Alarm AlarmType tsTimeStapm 3030 InAlm 1/11/05 9:11:00 AM 3030 AkAlm 1/11/05 10:48:00 AM 3030 OutAlm 1/11/05 1:32:00 PM 3032 InAlm 1/11/05 2:51:00 PM ...Show All
Game Technologies: DirectX, XNA, XACT, etc. XNA with languages different than C#
Will XNA express run with other .NET languages different then C# For example, VB or Managed C++ ... Not apparently 8( When I try to install the XNA Game Studio Express it tells me "Sorry you don't have installed Visual C# Express"... but I have installed VS2005 Pro.... so I can't get the .NET dlls to start programming because the MSInstaller can't continue without installing the Visual C# Expres... ...Show All
Windows Forms "datagridviewcomboxcell value is not valid" when i want to bind object to datagridviewcell
Have anybody have idea to solve my problem!! i have a class name clsProductUnit, have 2 properties, Unit and Price. (This Class represent Unit of Product) Assume that "A product have 2 Units" when user select product, i bind 2 objects of clsProductUnit to comboboxcell (I bound by using object, not string) PROBLEM OCCUR when user dropdown and select any Unit from combobox It will show "datagridviewcomboxcell value is not valid" I think problem occur because, grid try to convert my selected value (which .net determine in string to object(clsProductUnit)) PS! In this combobox column, i already set proerpty of "valueType","DisplayMember","ValueMember" ...Show All
Visual Studio 2008 (Pre-release) WPF dialog owner
I've got a custom dialog that I want to launch from a Page within a Window. I want to set the dialog's Owner property to the Window so they minimize together, etc. However, I can't seem to find a way to get the top-level window in the heirarchy from the page, short of manually iterating the Parents until I find what I want. Surely there's got to be an equivalent of the TopLevelControl property from WinForms controls. Am I up in the night Window has a static method called GetWindow that allows you to get the window that hosts an control. http://windowssdk.msdn.microsoft.com/en-us/library/system.windows.window.getwindow.aspx ...Show All
Windows Forms Generated DataBinding and ComboBox Problem
Hi, I make use of the automatic databinding in VB 2005. I have got two tables. One is called customers and the other is called WorkingStations. Every Customer is assigned to one WorkingStation. I have created the dataset that displays thw rows from both tables. The customer table contains a column called WorkingStationID that is related to the primary WorkingStation key. Now I created a form that allows me to edit a customers data. I load one single customer by his ID. The basic editing works without any troubles. Now I added a combobox that has following attributes: Source: WorkingStationBindingSource Member: WorkingStationName Valuemember: WorkingStationID Value: Customers.WorkingStationID I load both tableAdapters(the one for the custom ...Show All
Windows Forms adding 10,000 rows into a DataGridView takes 10 seconds
I am adding 10,000 rows into a DataGridView with 50 columns, this takes 10 seconds - 6 seconds to add rows and 4 seconds to set initial values. :( What is interesting - setting 2nd column values takes NO time SuspendLayout does not help, there is no BeginUpdate method... Any trick to improve here is an example of my output: now only adding rows 11/30/2006 3:56:05 AM now setting 1st value 11/30/2006 3:56:11 AM now setting 2ns value 11/30/2006 3:56:14 AM done! 11/30/2006 3:56:14 AM here is the code: int c = 10000; dataGridView1.SuspendLayout(); Debug.WriteLine("now only adding rows " + DateTime.Now); for (int i = 0; i < c; i++) { dataGridView1.Rows.Add(); } ...Show All
Smart Device Development where is hidpi.h file??
Hi, I want to develop a HID class device used with PPC. But I can't find the hidpi.h header file in SDK,please tell me which package include the file This file only included in the Windows CE Platform Builder. A eval edition is available here . ...Show All
SQL Server Update Datetime
Question How can one update a DateTime field when the change request may alter any of the attributes of the time (Day | hour | hour & minute). WHY Of course the whole point of a timestamp is to stamp the time of the record. The problem comes in when the user wants to tweak that timestamp. I am not interested changing anything about the time at the seconds point. The user will only change major time factors. Platform .Net 1x C# SQL Server 2000 Eventually this will be in a Stored Procedure. advTHANKSance Can you explain how you will pass the change units Will it be number of days, hours and so on If you are passing the datepart as numerical units then you can use the built-in dateadd function for example to change the d ...Show All
SQL Server Problem on Sync Access database
Dear all, I have a software written in C#, using RDA to sync access database from desktop. But it is tricky that some time during "Pull" data from SQL Server Agent, my PDA tell me "A request to send data to the computer running IIS has failed. For more information, see HRESULT". This also happening when I try to unplug the ethernet cable from my desktop however the push and pull actions did not required to go through internet. Here are part of my codes m_intdb = new SqlCeRemoteDataAccess("http://desk01:1024", "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\\inttemp.mdb; Jet OLEDB:System Database=C:\\Documents and Settings\\user\\Application Data\\Microsoft\\Access\\System.MDW"); m_intdb.Inte ...Show All
Visual Studio Tools for Office Dreaded "document opened in multiple windows" error
I know it's normal for the task pane to disappear when users hit F7 to launch spellcheck. My problem is if a user manually runs spellcheck and the first error encountered is in the text of a comment, Word turns on the comment preview pane on the bottom of the document, and this error appears just before the task pane disappears: You are currently viewing this document in multiple windows. To attach an XML expansion pack, you must first close all additional windows so that you are viewing the document in only one window. This error is overlaying the spellcheck dialog. When I click OK, the following exception appears: An unhandled exception occurred in your application. Contact your administrator or the author of this document for further ...Show All
.NET Development System.net.mail problem
Hi everyone, I have a little problem using the system.net.mail namespace implemented in the following code: Private Sub Envio_Correo( ByVal ruta As String ) 'Creando la instancia del mensaje Dim correo As new MailMessage correo.From = New MailAddress( "b98123839@usmp.edu.pe" ) correo.To.Add( "amonasiq@usmp.edu.pe" ) correo.Subject = "Archivo de Confirmacion de matricula" correo.Body = "Se adjunto archivo de confirmacion de matricula de su respectiva facultad" correo.IsBodyHtml = False 'correo.Attachments.Add(New Attachment(ruta)) correo.Priority = MailPriority.Normal 'Crando la instancia del SMTP cliente Dim smtp As New SmtpClient smtp.Host = "134.5. ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Levels with XNA
Hello, I'm looking to make my levels in 3D Studio Max however I have no idea how to get it working as a level within XNA. For example if I made a Office Building with 3 Floors a lobby, middle floor and an upper floor how would I go about making movement with a camrea when you go up stairs for example Or if you run into a wall so you don't go through, I'm looking to work a 1st person game with nothing but an office building and movement to learn from. Any help would be great! I have done the 3D tutorials and made a model move around and rotate like in a game, I have also made a Pac Man in XNA, I'm a bit confused on how you think I should start with something more simple If it's because of my post co ...Show All
.NET Development Thread.CurrentPrincipal -v- HttpContext.Current.User
I have a .Net 2.0 web-service used by a WinForms app, with IIS set to Windows Authentication and anonymous access turned off. Within the web-method, I wish to retrieve the Windows login of the calling user. I've saw different articles suggest different ways to do this. Some say Thread.CurrentPrincipal, others say HttpContext.Current.User. Is there any difference, or do these reference the same principal object I'm accessing Thread .CurrentPrincipal.Identity.Name and HttpContext .Current.User.Identity.Name Also, if IIS has the web-service set to Windows Authentication, and anonymous access turned off, but the web.config doesn't have <authentication mode="Windows" />, what difference will that make Thanks, An ...Show All
Visual C# Please help me confirm on windows service
Dear All, I have a windows service which I need to run on particular time of a day. So I have build my windows service and add the code of my action of checking the database in the onStart function Is this correct or must I have a main function Another thing I have added is the debug.write I dont know whether it prints or not I done with installer and manage to successfully install my window service. So I dont know how to confirm if my windows service is running or not How can I set the time to be like specify for certain hours in a day eg. to run at 10 am, 12 pm, 2pm and 4pm daily Thanks. Dear Rizwan, About the timer I am confuse. Some articles say use Timer some say use Timer.Th ...Show All
Visual Studio ReportViewer in Firefox version 1.5.0.1
I have problem rendering the ReportViewer in Firefox version 1.5.0.1. The width of the ReportViewer is much smaller than expected and the data is just messed up. But the ReportViewer works fine in the early version such as 1.0.7. Any clue on that Thanks. Brian, Is there a hotfix available to resolve the "narrow width" issue when the ReportViewer renders columns in Firefox We're seeing the same error with Firefox 2.x, and our client is considering a switch to Crystal Reports if we cannot resolve the issue promptly for them. Please contact me at jeff.townes@parivedasolutions.com with any information you may have. Thanks, Jeff ...Show All
