TCSC's Q&A profile
Visual C++ command prompt after compiling
The problem i have is when i compile the program the command prompt doesnt appear. If i am trying to enter data like numbers or a persons name i cant do that, I am student and this is hard for me to do my assigments for class. Would appreciate any help. What do you mean by "the command prompt doesn't appear" if you are compiling from within the IDE then there is no command prompt: if you are compiling from the command-line then the fact the the command prompt doesn't reappear seems to imply that the compilation process never finishes. Are you, perhaps, mixing up compiling your code and executing the program that is generated. ...Show All
Windows Forms Speeding up background image
I am using c# & .NET to try to make my version of the classic snake game, where the snake eats things and gets longer. I am using the GDI to do everything. My problem is that when I added a background image for a textured background instead of just using a solid background color, it slowed everything down a lot. I have tried putting the image in this.BackgroundImage, I have tried embedding the image instead of loading the file (which didn't help), and I have tried drawing the image from the OnPaint handler (which sped it up a little, but not nearly enough). I have also tried using bmp files instead of compressed jpg's and that didn't make any difference. Is there any way to have a background image without slowing things down this much, ...Show All
Visual C# How to disable properties?
Hi, I have been doing a lot of research into this but still can not find an answer. I am trying to disable/enable property depend on the condition. Below is an example of what I am trying to do: class Testing { string apple; public string Apple { get { return this.apple; } set { this.apple = value; } } string table; public string Table { get { return this.table; } set { this.table = value; } } enum Item { fruit, thing } //method to disable property public void Disable(string x) { if (x == Item.fruit.ToString()) { //disable this.table, make it read only if possible //this is where I am stuck on } el ...Show All
SQL Server Loading data from xml
I have an xml file I want to use as the source. It's not overly complicated, but not simple either. It has one hierachy, and one optional field and looks like this a 1 'text' 2 'text' b 1 'text' 2 'text' 'optional field' Ok, now I want the data to load like this: a,1,text a,2,text b,1,text b,2,text, optional field but when I try to use the xml source it won't create the xsd...anything I can do The error message is at the point when I hit the button to create a schema. Up to that point I'm simply pointing at a fairly simple xml file (part of which I've copied below. < xml version="1.0" > - < ADB ID =" 1 " > < I ...Show All
Visual Studio Team System WARNING: VSTS not compliant with DoD IA Policy
JTF-GNO COMMAND TASK ORDER (CTO) 06-02, update 3 requires two-factor authentication for all DOD private web servers. The Visual Studio Team Foundation Server application tier runs on Internet Information Server that is considered a DOD private web server. Since the Visual Studio Team Foundation Server Client was not designed to pass a client certificate to the application tier, this product is in violation of this Department of Defense Information Assurance policy and as such will need to be removed from our development infrastructure if Microsoft doesn't create a hot fix for this issue. Microsoft's business will also be negatively impacted because VSTS, in its current form, cannot be leveraged within any DoD installation. We use ...Show All
SQL Server FTP Task - File represented by _does not exist.
I've done some searcing on this forum and online. I found one thread that talked about this problem, but it didn't seem to help me at all. I have a package that downloads an xml file from a ftp server for processing. The file is named after the day that it was put on the ftp server. So, to help the situation I created a variable that gets set to the proper name before the FTP Task fires. Now, I've been working with this SSIS task for just over 2 months and haven't seen this issue ONCE until I deployed it on the production helper server. All of my other SSIS tasks are working fine in my other Tasks. I have set DelayValidation to true for the FTP Task, I have moved around the time the task gets run. This is what is really tricky. If I fire ...Show All
Visual Basic text formating
Hi, i would like to ask whether can i format the text in textbox in such a way that whenever there is a bullet, it will display it in a newline. the textbox data is retrieve from a database in the same column. Hi, sorry I wasn't clear. It should be: Private Sub txtDisplay1_TextChanged( ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDisplay1.TextChanged txtDisplay1.Text = txtDisplay1.Text.Replace("."c, ". " & Environment.NewLine) End Sub You also hadn't declared the characters correctly, as it would have been looking for a string "95". If you're using a full-stop now, it should work OK as above. However, you will want to be careful doing this in the text-changed event. Wh ...Show All
Internet Explorer Development accessing dhtml/dom within c# user control
Hi, I have an embedded .NET user control in a web page, and I need to be able to navigate to a different page with the same browser when I click on a button in the control. How can I access IE's DOM from within the embedded control written in C#. I've been researching this issue for months, and have only found answers that involve .NET 2.0, which I can't use now and C++ which I don't know. Please help me out. Thanks Thank you for the reply. Can you tell me 1. how to write the managed IE DOM wrapper and 2. how to request or grant the permission for the code to work. I would greatly appreciate it. Anhtai ...Show All
Smart Device Development VB.net mobile 5.0 application Cab File...please help!!!
All of a sudden when i build my app, then I build my Cab File the Cab file itself is over 2mb...it used to be under 1...and it does not work has anyone else had this happen...is there a fix... cannot deploy new vrsions.... thanks in advance Mase NETCF V2 CAB is over 5 MB while it used to be around 2MB in V1 and it works. Must be a problem with your CAB but since you've provided no information I can not say what's wrong or how to fix it. Here's something rather obvious: - Removing stuff from CAB makes it smaller. Make sure you don't have anything you don't need. - Compressing CAB makes it smaller - required for all SmartPhone devices, can be use on WM 5.0 PPC. ...Show All
SQL Server FAST_FORWARD Cursors
Does SQL Server 2000 creates a temporary table in tempdb for FAST_FORWARD Cursors ...Show All
.NET Development Cascading App.config from DLL projects
I have multiple DLL projects referenced from a Application project in my solution. I have settings in app.config files stored in each one, as the classes in the DLL libraries can be customized based on the config settings. How do you cascade the settings from the DLL projects to the application project Do you have to manually copy them What is the intended Microsoft way of handling configurable DLL settings AFAIK, System.Configuration cannot load .config files for class libraries, just the one for the main .exe. I've tried pretty hard. The IDE will build a .config for a DLL but it is of no use. Merging those into the app's .config needs to be done by hand. ...Show All
Visual C# Convert string to operation
Hi! Is it possible to convert strings to operations in a relatively simple way For example convert this string: string OperationInString = "3+3+9"; somehow, so I get back "15". Thanks in advance. ;) Wow you're expert! I guess it takes an amount of infinity^2 time to get to this level of knowledge. :) Thank you for that long piece of code, though I must admit, I get lost hopelessly while interpreting it after the 5th line. :) I hope at least I can implement it into my project. It does what I want it to do in itself so far, I'll see what bugs show up with my stitched-together project. ...Show All
.NET Development SmtpClient sending but not receiving
Hello I am trying to create an email application which will send a bulk email to all subscribed customers. i have the following code which apparently sends the email correctly. However when i did a test sending to my pop3 NTL World email account the email arrived just as expected, however when i send to my hotmail account the email never arrives Am i doing something wrong missing some setting Any help appreciated Thanks Lee ********************************************************************************************* SmtpClient mailServer = new SmtpClient ("smtp.ntlworld.com"); mailServer.UseDefaultCredentials = false ; mailServer.Credentials = new System.Net. NetworkCredential ( "xxx&qu ...Show All
Windows Forms Transparent labels
I am having very little success when I set the property of the BackColor of a label to Transparent. Does anyone know how to do this so I can put text over a color gradient Sadly ( for me), I've tried this and various other (messier) solutions I've found on the web, and not one of them works. I am adding a label to my form dynamically, I dunno if that makes any difference: class TransparentLabel : Label { public TransparentLabel() { SetStyle( ControlStyles .SupportsTransparentBackColor, true ); } } TransparentLabel l = new TransparentLabel (); using ( Font f = new Font ( "Verdana" , 340)) { Controls.Add(l); l.Name = "Label" ; l.ForeColor = Color .Red; ...Show All
Visual Studio Express Editions form2 combobox
Hi,i am new to programming i am having trouble with the following. i have a form with a splitcontainer i have added 2 usercontrols "usercontrol1" and "usercontrol2" i have set the usercontrols to fill splitcontainer panel2 i have a second form "form2" i have a combobox on form2 with collection items "conttrol 1" and "control 2" i am saving the selected text of the combobox to a user setting "startupcontrol" if i put the combobox on form1 on splitcontainer panel1 i get the results i want. But if i move it to form2 where belongs it does nothing. Please see the code below. The first part is working with the combobox on form1 splitcontainer panel1 T ...Show All
