CodeAccessPermission in framework code in .Net
If you use reflector to, for example, look at the implementation of the OnMouseEnter method of ButtonBase, it calls IntSecurity.AllWindows.Assert before showing a ToolTip control. Why? ...
If you use reflector to, for example, look at the implementation of the OnMouseEnter method of ButtonBase, it calls IntSecurity.AllWindows.Assert before showing a ToolTip control. Why? ...
I'm using Visual Basic 2010 Express. I have a form that can be minimized. There's also a tray icon. I've coded it so that if you double-click on the tray icon, the form's FormWindowState becomes set to Normal; this restores the form to where was before it became minimized, but the form does not become the active window on my desktop. Ho...
Hello everyone ! I'm working on a VB.Net project and using SVN. I noticed that every time I open my main form, Visual studio slightly modifies my .resx file, which means that I keep having to re-commit it, which is quite annoying. Has anybody experienced such problems? A diff file demonstrating the problem can be seen at http://synchro...
We have a .NET Winforms application that hosts the Crystal Reports Viewer control (Version XI). It works well for the most part but when an export of data from the viewer is performed the application will crash on exit and in unmanaged code. The error message is not very useful and just says that an incorrect memory location was accessed...
ok, here's the issue, I set a radiobutton.value to true. when I go to save and perform bindingsource.endedit. radiobutton.value is then nothing. any ideas as to what could cause this? Thanks. ...
I have some VB.net code that inserts data into my SQL database using a typed dataset as follows: dim usersTa As New authorizedUsersTableAdapters.Authorized_UsersTableAdapter usersTa.Connection = New Data.SqlClient.SqlConnection(MY_CONNECTION_STRING) usersTa.Insert(first_name, last_name) In the database, there is a primary key b...
Hi, I am looking for ways to implement custom user-roles in windows application with vb.net. I got a database table called Roles with Administrator and User entries. User cannot see some of the form data. In ASP.NET MVC we can do like. [Authorize(Roles = "Administrator")] public function GetAccount() as Array End Function If it cou...
This has probably been asked before, but if it has, I can't find it. Does C# have an equivalent to VB.Net's DirectCast? I am aware that it has () casts and the 'as' keyword, but those line up to CType and TryCast. To be clear, these keywords do the following; CType/() casts: If it is already the correct type, cast it, otherwise look f...
if (InvokeRequired) { BeginInvoke(new MethodInvoker(delegate() { textBox1.Text = args.Fax.Port.ToString(); textBox2.Text = args.Fax.FaxStatus.ToString(); })); } ...
ETA: I use visual studio 2008 express edition. If I override WndProc and mess up somehow, I'll usually backtrack by commenting out code until it works again. The strange thing with WndProc though is you can strip it down to: Protected Overrides Sub WndProc(ByRef m As System.Windows.Forms.Message) MyBase.WndProc((m)) End Sub and ...
Hi, Could you please help me? I've created a console .Net application and encrypted the app.config file with RSAProtectedConfigurationProvider. I've used an article http://www.codeproject.com/KB/dotnet/EncryptingTheAppConfig.aspx as an example for the Encryption. It works fine in an IDE on my XP desktop. Then I deployed my application to...
Hey Everyone I am starting off in the .NET world and wanted to know what a great beginner book would be that would explain how to use asp.net, vb and SQL. I hear "Learning Visual Basic" is a good series but wanted to see if there were anymore out there. Thanks for your help! ...
Hi folks, Got a chart control i wanna make from a data table. the table looks like this: the chart i want will look like this: ''' '''' ''''' '' ' ''''' '' ' ECCTMP ECCTMP ECCTMP Monday Tuesday Wednesday hope this makes sense for each day its grouped b y the type (email, calls). I'm just n...
I have developed a VB.Net code for retrieving data from excel file .I load this data in one form and update it back in excel after making necessary modifications in data. This complete flow works fine but most of the times I have observed that even if I close the form; the already loaded excel process does not get closed properly. I tri...
I have a ListView control on my form set up like this in details mode: What I would like to do, is get all the values of the data cells when the user presses the Delete booking button. So using the above example, my array would be filled with this data: values(0) = "asd" values(1) = "BS1" values(2) = "asd" values(3) = "21/04/2010" v...
I have written a small XML validator, that takes in an XML file and an XML schema and validates the XML files against that schema. It works well, except for an XML file, with this content: <?xml version="1.0" encoding="utf-8"?> <xc:program xmlns:xc="http:\\www.something.com\Schema\XC10" xc:version="4.0.22.0" > <xc:namespaceDecls> ...
I have a webservice that returns an object i have defined. One of the properties is of the type string and holds a significant amount of characters...over 500 at times. When pass data of the same type TO the webservice, it makes it there and i see the data in my DB. When I return data to the client side, that property is getting truncate...
sTitle = Regex.Replace(sTitle, @"&\w+;", "") ...
Need to convert a string to normal datetime format so it can be correctly inserted onto a datetime type field. String Format: 4/21/2010 4:43:03 PM Example: 2010-04-21 16:43:03.000 I have clarified question: The need is to change format and not type. ...
Hi folks, I wanna have a drop down that lets me select "Week Commencing Monday the 20th" going back 10 Mondays but I'm not sure how to go about doing this. I've used date.now(), etc. before but not sure how to do this one. Thanks, Billy UPDATED CODE Public Sub GetMondays() Dim dtMondays As New DataTable() dtMondays.Columns.A...