Nathan Blevins's Q&A profile
Visual Basic String Functions
I am experiencing something very strange in a VB.NET project I am working on. The string functions Left(),Instr(), Right(), etc. do not work, and others, like Replace, do not work correctly. Is this a case of class pollution If so, how to deal with it Guessing a bit: Left() and Right() won't work in a Windows Forms form class, their names collide with the Form.Left and Form.Right properties. Use Strings.Left() and Strings.Right() instead. You might have a problem with Replace if you use the String.Replace() method, it takes two arguments, not three as the VB version does and character indexes start from 0, not 1. No idea why the InStr() function would give you trouble, other than that there are two of t ...Show All
Windows Forms Binding to a Business Logic Layer
Hi, The question is more for designers and architects. The question is about working with data, specifically about Binding to a Business Logic Layer. With introduction of typed datasets in .net 1.0 and especially in .net 2.0 I started to ask myself - isthat really necessary to create a class that is a mapping for a db table. I will explain what I mean. Take for example database pubs , table authors. With basically one click VS2005 creates for you a typed dataset, let's call it authorsDataSet , which incapsulates a complete object model of authorsDataTable , authorsDataRow and even multiple tables with their relationships. Notice that authorsDataRow IS an complete object model of an author. Besides, there is a authorsTableAdapte ...Show All
.NET Development Problem about opening Office document in a new Window.
Hi all (first post yipee), anyway.... currently my web application have an icon that allows the user to edit an office document (word./excel), it is begin brought up by window.open(). However, problem lays here, since this isn't a model/modeless dialog, the user is allowed to go back to the application and reclick the edit icon. This causes the first office document that popped up to become blank and a second office document window will come out. The function of the icon is simple, it just calls window.open(), i am just wondering if there is a way to not allow the user to go back to the parent window and click on the edit icon again. showmodelessdialog() does not work in this case, i have tired opening an excel document with it but it re ...Show All
Visual Studio New MPLex and MPPG tools in latest VSIP SDK
First of all, thank you for finally integrating these important tools into the MPF world. I can finally (hopefully) bring my language tools out of the unmanaged world. I'm running into a few issues, and I couldn't find any documentation on them in the help files. First is that mppg doesn't seem to create an output file, it just spews text to the console. It could be that it is failing silently before it gets to the point where it is supposed to create a file. If I do mppg parser.y > parser.cs, then it spits out a mostly complete cs file. I'm not sure if that is supposed to work that way or not, but MPLex seems to spit out a file without the need for output redirection. So if I bring my parser.cs file into VS, and after I found the ...Show All
Visual Studio Express Editions Update ProgressBar from athoher Class
Hi. I’m new in c# I trying update progress bar in Form1, from another class, below a sample: Class1: public void Update() { Form1 f = new Form1 (); for ( int i = 0; i < 100; i++) { f.Prog ++; } } Form1 property class public int Prog { get { progressBar2.Refresh(); return progressBar2.Value; } set { progressBar2.Refresh(); progressBar2.Value = value ; } } The values are refreshed in debug mode, but the progressbar in the form not is refreshed, anybory help me, is urgently Thanks for the help, and sorry for my bad English Hi, in your Prog property setter, move progressBar2.Refresh() one lin ...Show All
Game Technologies: DirectX, XNA, XACT, etc. collision detection - alpha channel mask?
I'm making a tile-based game, and some of the tiles are part walkable, part not-walkable. (like half mountain, half dirt). I need a way to determine which part of the tile can be walked on and which part can't. I can't do it based on pixel color, so I wanted to know if anyone could help me out with some bright ideas. I remember hearing something about an alpha channel mask you can put over your tiles, or recreate the tileset in black and white to designate walkable/not walkable. Is that the best (or only) way to pull this off If so, that would double the size of my tileset file I would recommend looking at the XNA Resources Color Key map tutorial .Using a method like that isn't the only way I'm sure, ...Show All
Windows Forms How to manage event handlers ofthe controls created in runtime
I am making a desktop application which produces tab pages at runtime on a click of a button ... My problem is I am not usre how to access the text properties of the controls which were created dynamically .... any help would be highly appreciated.. please do remeber I am developing in c# and have absolutely no ideas abt vb...... cheers, da_coder. the code for making tabs dynamically is here with and when the eventhandler cycleSaveButton_Click(object sender, EventArgs e), i need to access ycleCommentsTextBox.Text, cycleFrequencyTextBox.Text, cycleOnsetTextBox.Text, cycleOffsetTextBox.Text,cycleAmplitudeTextBox.Text,cycleDurationTextBox.Text and cycleChannelComboBox.SelectedItem private void button1_Click(object sender, ...Show All
Visual Studio Team System Questions about LoadTest Database
Hi all, Is there a limit of 1000 messages on Threshold violation Can the limit be increased I also want to use to use sql query to retrieve information from the loadtest. Does anybody know how to retrieve the response time from a url using sql script from LoadTest database For example, I want to retrieve the values for all applicant.aspx response time in our system. Thanks. Regarding the sql query here is a link to a blog post by Bill Barnett that details the loadtest db's tables, it should have all of the info you need to put together a query like the one you mentioned: http://blogs.msdn.com/billbar/articles/529874.aspx Someone correct me if I'm wrong but I believe the 1000 message limit ...Show All
SharePoint Products and Technologies BDC Business Data Related List web parts pass the wrong entity
I am having a problem with the Business Data Catalog Business Data Related List web parts. I have the following generalized BDC schema: Entity A in Business Data List Entity B in Business Data Related List connected to entity A list via A to B relationship Entity C in Business Data Related List connected to entity B list via B to C relationship When selecting for a Business Data Related List with entity B to provide data to Business Data Related List with entity C, it passes the wrong entity--the one from the source Business Data List (entity A), not the entity exposed by the first Business Data Related List (with entity B). The same error results that I was getting after applying beta 2 TR (this worked in beta 2): 01/31/2007 09: ...Show All
SQL Server Error when deploying forms authentication sample
Hello I'm trying to get the forms authentication sample working - I have followed the instructions given in the ReadMe that came with the samples. When I try to browse to localhost/reportserver (on the server), instead of seeing the logon page as expected, I get the following error message: An internal error occurred on the report server. See the error log for more details. (rsInternalError) Get Online Help Request for the permission of type 'System.Web.AspNetHostingPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed. Request for the permission of type 'System.Web.AspNetHostingPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed. ...Show All
Windows Forms Sending a new form to a hotmail account
Hiya, I'm trying to send a form which I've created to a hotmail account but when I do it just sends a blank email to the hotmail account instead of my form!! ! What do I need to do to get my form to send properly Please Help!! xXx If you wouldn't mind, could you share your code to send the email with the community I know it would be very useful if I knew how to programicly send emails... If you don't, that's ok too. ...Show All
Visual Studio Express Editions trivial question : passing data between application forms ?
i am using this approach to pass data and variables between application forms ----------------------------------------------------------- form2 class public Form2( string strTextBox) { InitializeComponent(); string strPass = strTextBox; } form1's button click event handler private void button1_Click( object sender, System.EventArgs e) { Form2 frm= new Form2(textBox1.Text); frm.Show(); } ------------------------------------------- In form2 how to make the variable strPass visible by other methods and fucntions in this form so i can use it i tried to use "public" keyword as i know but it produces an err ...Show All
Visual Studio Express Editions Machine UI
Building a new production machine. Are set to use Parker controls ACR9000 servo controller. Has anyone used VB.net for building the U.I. Parker offers .ocx's and controls for .net. I have used dos in the 'long' past. For some reason I am a bit skidish about using windose for the U.I. Any comments st I'd much prefer to build a UI using Windows and VB.NET than trying to code up a UI using any DOS based application. Much quicker to develop and really very easy. The concept of OCX controls is that its basically canned functionality that you can include and much of the UI stuff is hooking items up and writing code to tie everything together. The controls have events which you just ...Show All
Windows Live Developer Forums Messenger bot development toolkit
Hi, I have heard a lot about messenger bots and trying to find out if there are any toolkits or sdks available for developers to use and build messenger BOT. I tried googling but not really much help. Can some provide me more information on this Neti There are currently 3 SDKs available to play with. They are listed here: https://www.robotinvaders.com/main/About.aspx They were available for the robotinvaders contest. So I don't know if they will still work after November 15th. ...Show All
SQL Server SQL Mobile 3.0 (Update and Insert Question)
Is it possible If I use insert query to insert a record, but the record is already exist, it will automatically change insert to update And I have a row: customer_name, last_update is it possible to use sql to check if the customer_name I want to update is the same as the customer_name in database, it can automatically stop the update ...Show All
