NILKAMAL's Q&A profile
Windows Forms how to change the state of checkbox without showing the error messagebox again?
hi, following is the simple code private void cb8_CheckedChanged(object sender, EventArgs e) { if (cb12.Checked) { MessageBox.Show("You can not choose this channel. \n Please uncheck Channle D first", "Channel Tangly", MessageBoxButtons.OK, MessageBoxIcon.Error); cb8.CheckState = CheckState.Unchecked; } else ... If cb12 is checked, an error message box will be shown when user check cb8... So the checkstate of cb8 should be unchecked... However, with the above code, since the state of cb8 changed again, the error message will be shown again... So user had to close the error message box twice... Is there any way to solve this Thanks a lot! ...Show All
Windows Forms Error on trying to Update data grid
I am new to this so pardon my ignorance :) I have two tables with inner join displaying a bunch of feilds in a datagrid... i am able to view, edit and save the values from the datagrid. heres the sql statement SELECT tblInspectionItems.InspItem_CategoryID, tblInspectionItems.InspItem_Name, tblInspectionDetails.InspectDtl_Condition, tblInspectionDetails.InspectDtl_Notes, tblInspectionDetails.InspectDtl_InspID, tblInspectionDetails.InspectDtl_InspItemID, tblInspectionItems.InspItem_SortOrder FROM tblInspectionItems INNER JOIN tblInspectionDetails ON tblInspectionItems.InspItem_ID = tblInspectionDetails.InspectDtl_InspItemID WHERE (tblInspectionDetails.InspectDtl_InspID = @InspID) AND (tblInspectionItems.InspItem_A ...Show All
Visual Studio Express Editions Compiling
Is there any way to get the express edition to compile a source code or project If not, is there a way I could get my hands on the MFC Library and just add it to my current compiler (Bloodshed Dev-C++). Any help is highly appreciated. well Visual Studio does compile code....Express or the full version. Just go to build > build solution (or CTRL+SHIFT+B). It will output the application in the project folder\bin\debug folder. In order to run it on destination machines they must have the appropriate version of .NET Framework installed to run it. is this not what you are after ...Show All
Visual Studio 2008 (Pre-release) Publisher/Subscriber Problems: Orphaned Subscribers
I implemented a publisher/subscriber demo, but ran into a problem. In particular, when a client registers as a subscriber, but then shuts down/crashes without unsubscribing, the service locks up. For the notification, I use the below: [ OperationContract ] public void Notify( NotificationMessage message) { lock (_lock) { for ( int i = _subscribers.Count - 1; i >= 0; i-- ) { try { _subscribers .ReceiveMessage(message); } catch ( Exception ex ) & ...Show All
Visual Studio Team System vs 2005 server explorer does'nt show sql server
i have VS 2005 pro and SQL SERVER dev. does anyone know how i can make "server explorer" in my VS show my SQL server i have to "add connection" every time i want to view or edit a DB. very annoying! thanks You do have to add each database on the SQL Server as a separate connection in server explorer. If you want to view it as a server, you should use SQL Server Management Studio Do you have a question about Team Edition for Database Professionals ...Show All
.NET Development Writeable IList<T> Poperties in Linq to XSD
The Linq to XSD Overview document states: The object model for the running example looks as follows: class Batch : XTypedElement { constructor Batch(); explicit coercion Batch( XElement ); property IList < PurchaseOrder > PurchaseOrder { get ; set ; } } Why is PurchaseOrder not readonly, as is custom with collection properties Apologies for my late reply. And yes, good questions. Basically, it's write-enabled so that you can using the cu ...Show All
Visual Basic how do you custom a message box?
Hi All! Is there a way to custom a message box Change the font, font coloring, background color of box. Stuff like that. Thanks! Rudy ...Show All
Visual Studio Express Editions Database Login fails from VB Express
Hi I can logon to my Sql server using the SSMS management tool, I am using Windows Authentication to logon to SSMS. Create a database OK, with all the necessary tables. However when I start a VB Express app and try to connect to this database I get an error that login filed for user AMD\Larry, AMD is my PC name and my login (Larry) is the computer Administrator logon. The PC is a standalone ie not part of a domain etc. Can anyone help Regards. Larry. ...Show All
SQL Server Calculating Age in a Stored Procedure
Currently, I'm having an issue with patients under the age of 1 year. I had a patient 9 months old and it calculated 8 weeks. Can anyone see where there may be an error in this This is the section pertaining to the "Patients Age" -- Full SP below this. '308.PatientAge' = CASE WHEN datediff(day, pp.birthdate, @ApptDate) <= 6 THEN cast(datediff(day, pp.birthdate, @ApptDate) as varchar(10)) + ' dys' WHEN datediff(day, pp.birthdate, @ApptDate) <= 112 THEN cast(floor(cast(datediff(day, pp.birthdate, @ApptDate) as decimal) / 7) as varchar(10)) + ' wks' WHEN floor(cast(datediff(day, pp.birthdate, @ApptDate) as decimal) / 365.25) < 2 and day(pp.birthdate) <= day(@ApptDate) THEN cast(datediff(month,pp.birthdate, @ApptDate) ...Show All
SQL Server Stored credentials on Shared Data Source
I'm trying to use stored credentials to enable caching. I've created a special windows user account with minimum permissions for just this task, and once set up, it works great (almost). I can update the shared data source using SQL Mgt Studio or directly via the Report Manager to use a set of - windows - stored credentials. But I don't seem to be able to do the same via VS.NET 2005. I can only store - SQL - credentials, which I have no need to enable and no desire to add to my surface area. The problem lies that every time I deploy any report that using that data source (which is nearly all of them), the data source is re-published, which wipes out the stored credentials and caching immediately stops. I've tried messing with the ...Show All
Visual Basic Login Form VB 2005
Hi , i can’t make a loging form, checking a database users, i already have the users db, but how can i made th validation, a full step explanation it'll be great, please help me i already read a lot of books about vs2005, but i still with this trouble i'm usin Microsoft SQL server, thanks a lot!!! because you dont have the connectionString declared in the scope of that function/sub. you need to either create it in there or pass it in as a parameter or use the GetConnectionString() function you have to return it the connectionstring: Private Function DoCheckUser( ByVal username As String , ByVal hashedPassword As String ) As Boolean Dim success As Boolean ...Show All
SQL Server Using declare statements and converting dates
I am having some issues trying to get a date into the right format. Here is the statements I am using DECLARE @Month INT , @Year INT , @Day INT , @Date VARCHAR ( 10 ), @FirstOfMonth SMALLDATETIME , @SecondDt SMALLDATETIME , -- Lst day of Previous Month @FirstDt SMALLDATETIME , -- 1st day of Previous Month @8mnthOldDay1 VarChar ( 10 ), -- 1st day of 8 months ago @8mnthOldDayLst SMALLDATETIME , -- Lst day of 8 months ago @13mnthOldDayLst SMALLDATETIME --Lst day of 12 months ago SET @Month = DATEPART ( MONTH , GETDATE ()) SET @Year = DATEPART ( YEAR , GETDATE ()) SET @Day = 01 SET @Date = CONVERT ( VARCHAR ( 4 ), @Year )+ '-' + CONVERT ( VARCHAR ...Show All
Visual Studio Team System Load Testing > Counter Sets > 'Threshold' Values > Visual Studio 2005
I am very confused with Counter Sets 'Threshold' values........ There are 3 categories under Counter Sets which are: Load Test, Controller, Agents and under each category there is a list of sub-category. Questions: Q1: Is there any way I can find out what is the average 'Threshold' values for each category for my website Q2: Is there any online resource or help available which I can use as a guideline to set 'Threshold' values Q3: Do I have to set all 'Threshold' values for all categories or I can leave some blank If I leave them blank than what is the default values Are they all set to 0 Q4: At the moment when I run a load test I get the following 'Threshold' errors even though I ...Show All
Visual Studio Express Editions template link errors
I've been looking for a solution for this all day now, and it's driving me crazy. I have a C++ couple of C++ template classes that I'm using in a test executable for a DLL I built. The templates are used in the DLL as well, but in all cases that I use it, to avoid errors, I have all the template code in the header, so when it's included all the code is available for the compiler to do the type resolutions. When I build the DLL, it compiles and links just fine. However, when I build the executable, I get unresolved token and unresolved external symbol errors for the template, but only for the one that I use in the executable, not for the ones used in the DLL. I have tried to change the type temporarily to int and have copied and p ...Show All
Windows Forms update code works for modify but not add new
I have these 2 lines of code for both saving new record and modifying existing record, this.staffBindingSource.EndEdit(); this.staffTableAdapter.Update(this.hPMDataSet.staff); however, it only works for modifying new record, but not saving the new record, seems that it does update the actual database for the changes made to existing records, but doesn't update database with the new record. please help well, i have 2 buttons, "add new" and "save" buttonAddNew has code " this.staffBindingSource.AddNew(); " buttonSave has those 2 lines of code. btw, i set my d ...Show All
