Ggreg's Q&A profile
Windows Forms save control user to xml file
hi, i want to know how can i save user control like textbox (i want to save the textbox as a control user not the value of the contorl ) in a xml file and when i press button named load from xml file he load the textbox on the from (ie. create the textbox) please any one help me thanks, You can't do it that way. The easiest way is to just store also the textbox's attributes/properties that you want to set during creation in the XML file. ...Show All
Visual C# Passwords
Hello, I have a few questions relating to passwords. For starters, how do you make the password application so that it will recognise both the password and the username (ie. if the username is valid but the password isn't (or vice versa) how can you make it object until both are valid) My second (and final) question is: if the user wishes to change his/her password or username, how can he/she do it with out it reverting back to the old one next time he/she needs to enter it Thanks. Eragon. Hi Where are you storing the user credentials Is it in a database, Active Directory or some other data store This will need to be established before a proper suggestion can be given as the techniques used would be different. If it is a ...Show All
Visual Studio Express Editions Simple DataGridView question
How can I loop through all the rows of a DGV using a For...Each loop I tried this code: For Each row As DataGridViewRow In DataGridView1 Next but it gives me an error. Can anyone help me out with this Thanks... Hi, try this: For Each row As DataGridViewRow In DataGridView1 .Rows ... Next Andrej ...Show All
SQL Server Problems using RSClientPrint
We are using VB.NET 2005 to develop a WinForms application that uses SQL Server 2005 Reporting Services to produce reports. We want to print a large report programmatically without preview. RSClientPrint looked like a good solution but it produces an error when we try to use it. Details... I added Interop.RSClientPrintLib.dll Version 1.0.0.0 to my application and used the code sample I found at: http: / / msdn2. microsoft. com/ en- us/ library/ ms159195. aspx The call to print looks like: RSClientPrint.Print(" http: / / ourServer/ reportserver ", strReportPathParameters, "Report_name") This call generates an error message: "An error occured during printing. (0x80004002)" and throws an exceptio ...Show All
Visual Studio 2008 (Pre-release) consideration about XamlView
Does anyone have tried the XamlView at http://www.codeplex.com/XamlView I have tried to use this tool to view my resource dll. The xaml content can be view almost as its original. Since I am developing a smartclient application, the dlls will be deployed to client machines. So how to avoid the design to be viewed directly Any suggestions Hi, Yong What you said is quite reasonable. But, I don't think there are commercial applications released without protection or obfuscation. What I am worrying is the xaml files almost remain what they are design. ...Show All
Game Technologies: DirectX, XNA, XACT, etc. How do i create models in XNA?
How do i create a model in XNA See this thread: http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=1069171&SiteID=1 You create models in the modeling software, export them to a format XNA understands, and load them in your XNA program. ...Show All
.NET Development Is there any method to assign encoding in mailaddress?
Hello. I have faced the problem about automatically sending email in my system. My website is allowed people type in chinese character and two of them are: 1. Seller Name 2. Seller Email Address After people type in all their information , a email will be sent for them for reference. Firstly, I found that while user type in chinese character in Seller Name Textbox, that email will become unrecognised code like this " P q C L " . My coding is shown below: MailMessage mailMessage = new MailMessage(); mailMessage.To.Add(new MailAddress(seller.Email, seller.Name)); It seems that I can't use chinese character as a displayName in MailAddress. Is there any method As I know, I can give encodi ...Show All
Windows Forms controlling the focus
Hi. Does anyone know how can I make a control work without recieving the focus The thing is that I'm trying to simulate a kyboard (on a UserControl) which is added to a form. Whenevet a key is clicked, I use the SendKeys.SendWait method to simulate a keystroke. In order to process the simulated keystroke, the recieving form should be in focus. To achieve this, I use the SetFocus API function with the handler of the recieving form. So far so good - it all works fine except for the slight occasional control bar flicker when changing the focus. So - is there a way to avoid all that focus transfer You'll need to give up on SendKeys if you want to avoid the focus problem. You could send the WM_KEYDOWN and WM_ ...Show All
Visual Basic how to create custom forms
hello everyone, i need to create a custom form of shape round, which should have a deferent title bar which is curvy on the top is it possible to do that, if so , pls tell what things i have to change(learn) thanks , rajamohan.m thanks nobugs, the code works perfectly, according to the code the the border the minimize buttons and maximise buttons should be placed manually to be specific with the location which the form elements can be seen.. any way thanks once again ...Show All
Software Development for Windows Vista Writing an ISO image to disc
Hello everyone! Thanks to everyone who participated in the Optical Beta chat today! I'm trying to get a better, full-feature sample that we can put up on the forums, but for now here is a sample derived from our WinHEC slides that burn an ISO image to a disc. The only missing piece is creating a stream over the ISO file. I cannot get a piece of code that I can release for this in VBScript yet, although a good start is SHCreateStreamOnFile for C++ development. Even though it does not work without this one function, this sample still shows the necessary steps to burn an ISO image. Although this is officially unsupported code, I'd be glad to answer any questions about the IMAPIv2 functionality it exhibits... ...Show All
Visual C# Are there any event delegate creation plugins out there?
Just found myself writing events that need to bubble up more and more. Specially when dealing with user control with multiple child controls. ...Show All
SQL Server SQL 2005 backup to a different server
I have a SQL 2005 database server. I need to create a database maintenance plan that backs up to a different server. Currently, I can see the C and D drives on my database server, but not any other drives - even the ones I am mapped to. In SQL 2000, I use to enter/type in the mapping, but when I enter the mapping in my database maintenance plan, the database backups are not working. I am not getting any error message. When I execute the maintenance plan, it just checks off the steps and ends with success. It only takes about a couple of seconds for the plan to finish with the success notice. I have added sqlserviceacct to my other server's administrators group, and it has full permissions on the other server also. How would ...Show All
.NET Development ExecuteReader requires an open and available Connection. The connection's current state is Open, Fetching
cmd.ExecuteReader Run-time exception thrown : System.InvalidOperationException - ExecuteReader requires an open and available Connection. The connection's current state is Open, Fetching. I'm having a issue with my program. My application does a search first, then the user has the ability to edit the search results. So first a datareader is created and the ExecuteReader is called and you know the rest. Then once the user is ready to submit their changes and executeNonquery is called and you know the rest. The code fails at cmd.exectuenonquery line. Here is my code First the user searches for records based off an id: Private Function RetrieveErrorRecords(ByVal ErrorID As String) As DataTable ...Show All
.NET Development Transferring Image File Using Sockets
Hi all, I have an Scenario where i have to send an Image (max size of 40KB) from the Windows Mobile 5.0 to an webserver. Currently iam using an Web Service to transfer the file as Byte array. But the problem iam facing right now is tat the Transfer takes a long time and transaction fails frequently. I heard tat there is an option using Socket where you will be able to send data much faster. Anyone know how to use Socket to send the image from the Mobile to the server. Pl. give your valuable inputs on this issue. Thanks in Advance Regards Biju S Melayil thanks Rizwan. As you have mentioned "if you have to use Sockets". Is there any other better way to transmit this images from the mobile to t ...Show All
SQL Server NtBackup & VSS
Hey guys Just a question. If I use NtBackup with Sql server 2005 & sql writer started, the NtBackup use the Volume shadow Copy Service and the Sql Server Writer That is if do I do the backup of the log and data files, is these correctly and with consistence Very Tanks Yes, ntbackup will invoke VSS, and indirectly the SQL Writer during a backup. The files you back up are guaranteed to not have torn pages, and are in a "crash-consistent" state. Kevin ...Show All
