
John_0025
Avatar/Signature-
Posts
38 -
Joined
-
Last visited
John_0025's Achievements
Newbie (1/14)
0
Reputation
-
Not true. Changing the value in a textbox has no affect on the viewstate. As long as the sub is called before the page renders the new buttons will be drawn. Can you show your code?
-
Hi and welcome, It would help if you posted what you had done already so we can guide you and let you know where/if you are going wrong. Don't worry about getting it wrong we've all had to learn to program here and have all made some embarrassing mistakes along the way.
-
Have a look at using LINQ http://msdn.microsoft.com/en-gb/library/bb384429.aspx
-
Can you give a bit more information about what you want to do? If you really are thinking of making your own web browser check out the source code for Mozilla. Its open source so no stealing involved. Theoretically you could also customise it but this project has a reputation for being hard to use. Anyway if you take a look you�ll get an idea of the scale of the work needed to make a web browser. Visual Studio has a WebBrowser control you may be able to use. Take a look at http://msdn.microsoft.com/en-us/library/system.windows.forms.webbrowser(VS.80).aspx
-
Do you mean the HoverMenu from the Ajax control toolkit? I don't think there is any option to change the behaviour but you can download the source code, it is open source (you should check the license) yourself to be sure about redistribution. You then just need to copy or edit the existing HoverMenu and change the handlers to listen to the onclick event rather than the mouseover.
-
I don�t think your cell will contain any text because you�re using databinding. Rather it�ll contain a databoundcontrol. I don�t really know much about how you�d get that value and how it�s persisted in a postback. You could use the item index and then finding the values from the original data source. This will mean less performance as you�ll need to re-fetch the data in the postback. protected void itemCommand(object source, DataGridCommandEventArgs e) { if (e.CommandName == "Edit") { var index = e.Item.ItemIndex; var dataSource = DataSource(); var data = dataSource[index]; Session["Username"] = data.Username; //etc } } Or you could pass the selected row are a parameter to your �Update.aspx� page and let that page find the data from your datasource. protected void itemCommand(object source, DataGridCommandEventArgs e) { if (e.CommandName == "Edit") { var index = e.Item.ItemIndex; var url = string.Format("Update.aspx?rowIndex={0}", index); Response.Redirect(url); } }
-
This is also discussed here http://www.xtremevbtalk.com/showthread.php?t=301457 is anyone else is interested in it.
-
How do you kill excel when you are finished?
John_0025 replied to mskeel's topic in Interoperation / Office Integration
:eek: I don't think killing the process is an option. Firstly I think you can only do this if you run the program with local admin rights. I'm sure other users won't get permission to do this by default. Secondly what if the user was already using Excel? You'd find yourself in a bit of trouble ;) I found GC.WaitForPendingFinalizers() helped me. -
Regular Expression with string exlusions
John_0025 replied to david7777's topic in Regular Expressions
As I understan it he doesn't want to match the b in bundled because it is between the bold tags. Apart from being a bit untidy is there anything wrong with having bold tags within bold tags. Does it become ULTRA bold :D -
You could use a structure to hold the values. Public Function myFunction() As Costs Dim objRequirements As New elantis_BUS.BusRequirements Dim decResult() As Decimal decResult = objRequirements.BOM_Explosion_Costing_Level_One(CType(Me.tvwBillOfMaterial.SelectedNode.Tag, String), CType(Quantity_From_Node_Description.Remove(0, 1), Decimal), 2) Dim costs As Costs costs.decMat = decResult(0) costs.decLab = decResult(1) Return costs End Function Public Structure Costs Public decMat As Decimal Public decLab As Decimal End Structure
-
You shouldn't have the '.*' in the square brackets. Also . and - are special characters so you need the backslash before them to use them normally try. ((\d+)|(\d+\s+))\-(.*)\.(([wW][mM][aA])|([mM][pP][3]))
-
How do you distingish between the method and property names in VB.NET? To show what I mean in C#, a case sensitive language, you can do this: public class example { private string name; public string Name { get {this.name;} } } As VB.net is case insensitive this doesn't work so what is a good convention for naming the methods and properties. Thanks
-
In my opionion it's best to avoid (.*) or (.+) in your expressions or better still avoid '.' altogther. This is really VERY generic and is what is causing your problem. You need to be more specific about what characters you want to match between the @@@ bits in your text. The @ character will be matched by the (.+) part of the expression and the program will try to match the largest string it can find. You need to make your expression say that the @ character can not be included between the '@@@' tags. This will make your expression a lot longer. ;)
-
I have a similar problem. Records in my database must have unique names. So I catch the exception. Allow the user to rename the record and then I wanted to 'retry'. I was using the goto and label stuff in VB. Not sure if this is now frowned upon in VB.net ;) Public Sub CallDB() tryAgain: Try 'Make db call Catch ex As uniqueNameException Dim errorHandler As New ErrorBox(ex, ErrorBox.buttonTypes.OkCancelBox, "Please enter a new record name.", True) If errorHandler.response = ErrorBox.Selected.OkButton Then Me.recordname = errorHandler.InputText GoTo tryAgain End If End Try End Sub Nerseus you seem to have morphed VB and C# together. :)