Troy Lundin's Q&A profile
Visual C# SImple Inheritance Question - Inherited Form
In VS 2005, C#, WinForms app I have a form "BaseForm" which contains a 'protected' button. The button's click event code is 'MessageBox.Show("BASE FORM")'. I have another form, "ChildForm" which inherits from "BaseForm". In the inherited button's click event code is "MeaasgeBox.Show("CHILD FORM") When I run the child form and click on the button, first "BASE FORM" pops up, then "CHILD FORM", so I guess the code in the button on the child form does not override the code in the button on the parent form. 1. Is there a way in the child forms button click event to prevent the code in the button on the base form (MessageBox.Show("BASE FORM")) from executing 2 ...Show All
Visual Studio Express Editions S.M.A.R.T. hard disk data
is there anyway to access s.m.a.r.t. data through c# i'd like to be able to make a tool that extracts the hard disk's reliability data and post's it to a database on the web! unfortunately not. You will have to make some low level calls either via some API or some other form as its locked by the system itself. C# is not designed for this at all since its a high level language. The only possibility you will have is by using some Win32API call perhaps ...Show All
SQL Server A call to SQL Server Reconciler failed. Sql Mobile, BusinessLogicModule
I got a merge replication published by my SQL Server 2005 and subscribed by my Pocket PC emulator having SQL Mobile. This works fine. I've now developed my own class to handle my business logic according to MS specifications. Inherits from BusinessLogicModule in Microsoft.SqlServer.Replication.BusinessLogicSupport. I had by using the sp_registercustomresolver and sp_changemergearticle. When I now try to synchronize from the emulator I get the error Message: "A call to SQL Server Reconciler failed." Native Error: 29006 Source: Microsoft SQL Server 2005 Mobile Edition Any ideas what has happened I also tryed to run the class in debug with my mobile app but same thing happens and it happens before any of ...Show All
Visual C# Dynamically Creating Aspx files and Associated .Cs Files
Hi all i want to dynamically create an .aspx file and its associated .cs file, and dynamically manipulate its contents ,handle the events how to acheive it Thanks you want to make an application that generates code for another (web) application Just out of curiosity, why would you want to that :-) Anyhow, i cant see that it would be very difficoult, just make your application create the files and write the text (code) to them...( !). Sounds like an awful lot of work if you plan on making large sites though. ...Show All
Visual Studio Express Editions Controls on tab pages just disappearing
Hi there! I am experiencing the following problem: From time to time, all controls placed on the currently active tab page just disappear and reappear only after reloading the project. This behavior is very disturbing and eats a lot of time for closing/reopening etc. Is this problem known to anybody Does someone have a solution Best regards, Merry Its refreshing the form or someting like that...i dont think you can disable it...i know its annoying and it happens to me too.. ...Show All
Windows Forms How to Fill 1st textboxcolumn of Datagrid...
hi, In my application...I have a datagrid on my form.My datagrid contains a textcoxcolumn & a comboboxcolumn…so I want to know how I can put values in textbox column on form load event…. Say I have 5 rows & I want those 5 rows to have 5 strings in the textbox column. Strings are(string1, string2, string3, string4 & string5). So how I can put it in that datagrids 1 st textboxcolumn (in form load event ). Thanks, Vinay ya... Thanks...can u tell me ...how by default i can select 1st option of each ComboBoxColumn in the DatGridView on Form Load Event... Thanks once again... Vinay ...Show All
Visual C++ Error when going to wizard mode from tabbed mode
Hi friends, Unhandled Exception in TabbedDialobBox.ex (MFC42D.DLL):0xC0000005: Access Violation I am getting the above error when i am inserting the code line "SetWizardMode()" in my code, But when i am running it in the tabbed mode it's working perfectly, When i tried to debug i got that some where assertion is being done due to the abscense of the window handle, but it is working in tabbed mode.With out a handle how can it work in tabbed mode.That's why i am unable to solve. Please send me the solution for the problem. With regards Suman#SS185 I tried dubugging , but as we use thw afx header file it is going deep in to the file, which i can't understand . since i am still in the initial stage of ...Show All
Visual Studio 2008 (Pre-release) Readonly dependendy property
Hello, I have defined custom readonly dependency property (below). I need to bind to it inside XAML (in my example it is bound to Label.Content), but it does not work... It looks like it never goes thru Get accesor, because in my custom dep. property is still default value... What is wrong Any suggestions Thank you RostaB My XAML: <Window x:Class= "Test.WindowTest" xmlns= "http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x= "http://schemas.microsoft.com/winfx/2006/xaml" xmlns:own= "clr-namespace:Test" Title= "Test" Height= "300" Width= "300" > <Window.Resources> <Style TargetType= "Button" > <Setter ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Selling Games on Xbox Live Arcade
Hello, I am currently putting a team together to create new Xbox Live Arcade games. They will be using the XNA development tool and the projects will be financed by myself. How long will it be untill Indy developers can sell their games online in order to re-coup some of the money and produce additional games Any help is appreciated. Regards Ian vhold wrote: It kinda smells of how big record labels treat small artists. I know that's being conspiratorially minded, but you have to admit that the lack of information in this department has a somewhat purposeful feeling. Indeed, that is how the game industry has worked in the past. Our vision with XNA Game Studio Express is to help change that. HOWEVER: The infrastructure ...Show All
Visual Basic OPEN NEW WINDOW WITHIN WEBBROWSER1 AND NOT LOOSE THE SESSION
I have this code whre I want to open a new window within browser1 of my form8 Instead I loose control of the browser and by loosing my session Private Sub WebBrowser1_NewWindow( ByVal sender As Object , ByVal e As System.ComponentModel.CancelEventArgs) Handles WebBrowser1.NewWindow e.Cancel = True Form8.Show() 'Form8.WebBrowser1.Name = what goes here I am not sure what to do here 'Here I am forcing the opening of this specific website/I want to open whatever url is clicked Form8.WebBrowser1.Navigate( http://www.accountingonline.us/invoice/index.php page=open ) ' Form8.WebBrowser1.Navigate(sender) this did not work End Sub The solution above catches window opens and set the ad ...Show All
SQL Server using text file data in a SQL Task
I have some fields in text file that I want to use in a SQL Task. What is the best way to read these fields and then plug them into the SQL Task Thanks Aref No. Read them into package variables and then use an expression on the SQLStatementSource property (as I pointed you towards further up this thread). -Jamie ...Show All
Windows Forms Binding to Multiple Datatables in a Dataset
Please Help: I have 2 tables in my dataset: T1{Key, Value1} - loaded from SQL database T2{Key, Value2} - created by calculations in VB. I need to display a DataGrid showing {Key, Value1, Value2}. How do I do this In crude terms I wish to Bind my control to an 'SQL statement' opperating on the 2 tables in my Dataset. Is this possible I have looked everywhere and can't find the answer. Thank you. yep I have a similar issue, and i use stored procedure, i promise you it is not the easiest way around, when u will have to update, add, But it is possible with longer programming time,. Yep it does produce better solutions. http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=605166&SiteID=1 Same scenario answered. - t ...Show All
.NET Development how to update multiple tables
hi, i want to update two tables(one referencing other). i used oledbadapter and the query i used to select table was SELECT student.student_id, student.name, student.branch, student.[year], student.college_id, college.college_name, college.location, student.event1, student.event2, student.event3, student.event4, student.event5 FROM (college INNER JOIN student ON college.college_id = student.college_id) Only the ...Show All
Visual C# Problem with System.Web.Mail
Hello Everyone, I am trying to write code in my c# windows program to send email. I found good tutorials online to get this done. Most of which use the System.Web.Mail namespace. When I come to write that in: using System.Web.Mail; I get this error: The type or namespace name 'Mail' does not exist in the class or namespace 'System.Web' (are you missing an assembly reference ) I even tried: using System.Web.Util;............but I pretty much got the same error message. When I come to look System.Web.Mail in the help files, I find it there, I just can not use it. Can someone please help me by pointing out what is wrong. I am using visual studio 2003 c# on windows xp home edition. ...Show All
.NET Development impersonating the user initiating an action over the network
I am trying to write a simple server/client application that will perform operations on the server using the permissions of the person running the client. I have saught to do this by serializing a WindowsIdentity object representing the client and sending it through a NetworkStream that is connected to the server (which will run as a windows service). Then I attempt to impersonate the user on the server using the WindowsIdentity object. Well, aparently the WindowsIdentity object does not contain a full set of credentials because once it gets to the server it simply sais that the handle is bad. I can see how this situation would happen, but what to I need to do to transmit the user's security token to another computer so tha ...Show All
