AshishMalhotra's Q&A profile
Windows Forms Maximized form is visible on the screen before call to OnShow()
Steps to reproduce: Create new Windows Application project Add control to the main form (e.g. ListView) Set form's WindowState to Maximized Override OnLoad() and OnShow() methods Set breakpoints on the calls to the base and run under debugger Note that the form is present on the screen when OnLoad() is hit (before call to OnShow()) Note that form's content (the ListView) isn't visible yet Repeat same steps for WindowState set to Normal and compare using any visual designer is not proper to learn something in depth. The following few lines of code will do it quite painlessly, and everything will be in front of ur eyes-- using System.Drawing; using System.Windows.Forms; class F ...Show All
Visual Studio Express Editions Putting text on a new line within a text file
I've created a program and part of that program puts out some results to a text file. However when it next adds text to the file it just tags it onto the end of the previous text. How do I get it to start on a new line I'm using the line below to write text to the file : My .Computer.FileSystem.WriteAllText(ReportPath, " This is the text that goes into the file !! " , True ) Use Environment.newline, like this: My.Computer.FileSystem.WriteAllText(ReportPath, Environment.Newline & " This is the text that goes into the file !! " , True ) Grtz, Tom. ...Show All
Visual Studio 2008 (Pre-release) ColorAnimation, Binding From Property
Hi guys, May be someone knows how can I bind "From" Property of the ColorAnimation list.cs /////////// private Color m_ListColor; public Color ListColor { get { return m_ListColor; } set { m_ListColor=value; OnPropertyChanged("ListColor"); }} list.xaml /////////////// <ColorAnimation Storyboard.TargetName="fillb" Storyboard.TargetProperty="(SolidColorBrush.Color)" From="{Binding Path=ListColor}" To="#111111" Duration="0:0:0.1" /> There is an exception in Presentationframework.dll Appreciate any help, Irina try changing From="{Binding Path=ListColor}" to From="{Binding E ...Show All
Visual Studio Team System SP1 source control issue - solved by reinstall and migrating data to the new server
I was finally able to get everything working by reinstalling the server and then migrating the databases to the new server. I assume it was an issue with something during one of the many upgrades from betas beta 3 - beta 3 refresh - rtm trial - rtm workgroup - sp1 beta - sp1. Everything installed fine on a the RTM bits. Thanks for everyones help ...Show All
Smart Device Development visual studio 2005 and platform builder ????
Hi All, I am fairly new to Platform Builder. I have built an OS using platform builder to support the .NET compact framework version 2.0. When trying to run the OS image, the only deive that I could select that resembles my device is the wince 5.0 device. However when trying to attach a device, it gives me an error message, indicating that the devices virtual memory needs to be increased. I assume that this is a deployment error and that if I could reolve the problem listed below, then this may solve the virtual memory conflict. I am also trying to synchronise Platform Builder with Visual Studio 2005. The problem here is, the active target device drop down box in platform builder has different devices from those listed in visual stud ...Show All
.NET Development Data type mismatch in criteria expression
When inserting a boolean field in my DB, I get the following error msg.: Data type mismatch in criteria expression. The field is declared as Yes/No and its format property is set to True/False in my Access DB. I've seen this error msg. before with a date/time field and resolved by substituting single quotes (') with hash (#) characters. Now, what do I use for boolean fields, or is there another way for me to get around this See my code below. Sub AdminRights() If (rbNo.Checked = True ) And (rbYes.Checked = False ) Then admin = False End If If (rbYes.Checked = True ) And (rbNo.Checked = False ) Then admin = True End If End Sub 'Grant admin rights. Private Sub btnSave_Click( By ...Show All
Visual Studio Express Editions Get program's file name
In Visual Basic 2005, is it possible to get the file name of my program I found I can get the directory the program is in through My.Application.Info.DirectoryPath. However, that does not return the name of the program, just where the program is. Basically, my program installs itself, but if the program does not know its own filename, how can it copy itself to the installation directory Thanks. My .Application.Info.AssemblyName See post http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=327593&SiteID=1 ...Show All
Visual Basic Math Questions
This is my code I'm working with. I'm trying to use the sum from the lhGal to show in lhGal2.Text. Dim FirstNum, SecondNum, ThirdNum, FourthNum As Double 'Intial Fuel Add FirstNum = lhPounds.Text SecondNum = lhDensity.Text ThirdNum = lhGal.Text FourthNum = lhPounds2.Text lhGal.Text = FirstNum / SecondNum - 0.4 'Additional Fuel Added to bring to 1200 lhGal2.Text= FourthNum / SecondNum - lhGal I was assuming that you're getting the values from textboxes and outputting the results to textboxes. If not, what is the lh prefix referring to However, I noticed that you are outputting one of the results to the same place where you are getting one of the operands. S ...Show All
Software Development for Windows Vista Modified CTextureRenderer freezes System when used with multiple Threads
Greetings everybody, My App needs to copy the content of a IMediaSample-Videoframe to several Direct3D-Textures. I do this via Texturelock and memcpy, which works quite nice. I've done it successfully sequential with 4 memcpys and now want to do it iwth multiple Threads for better performance. The Problem is that my whole Systems freezes after an arbitrary time of Playback and I have to do a hard restart. My Textureloader-Threads are build like this: do { WaitForSingleObject(pThis->m_hTLA_Go[index],INFINITE); -> Lock texture memcpy(pTxtBuffer,pThis->m_Samples[index],pThis->m_textureWidth*pThis->m_textureHeight*4); -> Unlock the Texture ReleaseSemaphore(pThis->m_hTLA_Done[index],1,&pre); } ...Show All
Visual Basic Hiiii I Need To Send A Picture
Hi Every One I need to send a picture via my email application in the MailMessage Body not in attachment if there is any way possiable to do it please share it with us Sorry, I don't quite follow - are you wanting to attach a file in the MailMessage From what I understand you do not want this However if you are wanting to attach the file in the MailMessage object then there are a few examples on these forums also. I hope this helps: Dim theMailMessage as new MailMessage(" address@from.com ", " address@to.com ") theMailMessage.Attachments.Add(new Attachment( PathToFile )) .. .. .. this is how you would attach a file in an email using the MailMessage object, is this what you are after I understand af ...Show All
.NET Development Where's the WinForm event for AFTER a form has finished loading?
I need to fire an event AFTER a form has finished loading and is displayed to the user. Currently, I'm initializing my MapPoint control on my form in the form_load event. But, if the connection to the MapPoint server is down, the form never really finishes loading before an exception is thrown and it's very slow. I want to put my MapPoint initialize inside an event that fires AFTER the form has finished loading and is displayed to the user. How can I do this Hello All. _Quimbly_: And it does the same thing in the Activated event handler Have you tried setting the DoubleBuffered property of the form to true HTH. ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Managed vs. Unmanaged code - please assplain
i'm reading a lot of talk about managed vs. unmanaged code. i've tried to understand the difference on my own, but Wikipedia writers aren't known for stating things simply :) i come from a Flash background. What is Flash Actionscript Managed or unmanaged Or neither Or both Can anyone explain the managed vs. unmanaged debate What are the points for and against each And why might i care Thanks, -MrSock I'm not sure if there is a parallel to the pipeline, but the the Framework in ActionScript would be the various pre-defined functions that you can call within individual frames (onclick, goto, etc). The Framework is just the underlying structure of the language/programming environment. ... ...Show All
.NET Development Installing .NET Framework 3.0 x64
Hi There, I'm trying to install the .NET Framework 3.0 x64 bit and i keep on getting the following error :- [12/14/06,14:51:45] WIC x64 Installer: [2] Error code 1603 for this component means "Fatal error during installation. " [12/14/06,14:51:45] WIC x64 Installer: [2] Setup Failed on component WIC x64 Installer [12/14/06,14:52:15] WapUI: [2] DepCheck indicates WIC x64 Installer is not installed. [12/14/06,15:14:52] MSXML 6.0 Parser [x64]: [2] Failed to fetch setup file in CBaseComponent::PreInstall() [12/14/06,15:14:52] setup.exe: [2] ISetupComponent::Pre/Post/Install() failed in ISetupManager::InternalInstallManager() with HRESULT -2147467260. [12/14/06,15:14:52] setup.exe: [2] CSetupManager::RunInstallPhase() - Call to ...Show All
Visual Studio Express Editions thanks renee
y,know I have just been thinking...... there are a lot of nice helpful people on here, who do all they can to help those in need of help or advice.......and I would just like to thank you all........sincerely renee has just walked me through creating a little project which I am very happy with..... it is not finished yet, and we have had a couple of disagreements, and perhaps we shall have some more.....but I would just like to say....thanks renee...for taking the time and effort to help.... it is greatly appreciated cheyenne You're welcome, Cheyenne. I have a philosophy here that is different from most. I've spent a lot of years on academia and I believe in giving eighty percent of an answer and the reason I ...Show All
SQL Server Converting data question
I need to combine two columns and copy them to another. One column is varchar and one is decimal (3,0) and the destination column is int. The column of decimal contains only 1 and 2 digit numbers. I need to perface a 0 to the data with 1 digit before combining the two columns. If someone could guide me here, I'd appreciate it. I've been trying to use cast and convert with no success. Kinny: I put together a quick mock-up of what I think you are trying to do. Do either of the output columns look like what you are trying to do Dave -- -------------------------------------------------------------------------------------- -- This mock-up works correctly for "correct values" as discrib ...Show All
