Create Sections Of Code Which Can Be Collapsed And Expanded Like A Normal Public Or Private Sub?

Mar 8, 2011

I have been told before that it is possible to create sections of code which can be collapsed and expanded like a normal Public or Private Sub, but containing multiple Public Subs So say I have code for a variety of textboxes I wanted to be able to collapse, how would I do this?

View 3 Replies


ADVERTISEMENT

TreeNode Always Expanded - Preventing Nodes From Being Collapsed?

Mar 10, 2009

I'd like my TreeView's nodes to always be expanded. Is there an elegant way of preventing nodes from being collapsed?

View 4 Replies

IDE :: Make The Collapsible Markers(-) Or (+) For Collapsed Sections/regions Larger?

Mar 10, 2011

it is possible to make the collapsible markers(-) or (+) for collapsed sections/regions larger.VS 2010 Pro.

View 7 Replies

Find The Number Of Expanded / Collapsed Master Rows And Grouped Rows In A DevExpress GridView?

Jan 18, 2012

I am currently using DevExpress 10.2 within Visual Studio 2010. In a previous question I was trying to print the current user view of a DevExpress GridControl with the user's choice of expanded or collapsed master rows and/or group sections. I was told this was not possible at this time. I have now decided to use the following code:

[Code]...

View 1 Replies

Difference Between Public Sub And Private Sub And Private Function And Public Function And Sub And Shared Function?

May 31, 2011

explain me the difference between them? I'm new to visual basic, and I need to know the very basic things in Visual Basic allowing me to become a professional User

View 8 Replies

Generate Public Private Key?

Apr 12, 2010

How to generate public private key VB.net code...

View 1 Replies

C# - When Should Use Public / Private / Static Methods

Apr 27, 2009

I'm new to C#.Till this moment I used to make every global variable - public static.All my methods are public static so I can access them from other classes. I read on SO that the less public static methods I have,the better.So I rewrote my applications by putting all the code in one class - the form class.Now all my methods are private and there's no static method.

My question: What should I do,keeping everything in the form class is dump in my opinion. When should I use public,when private and when static private/public? I get the public methods as a 'cons' ,because they can be decompiled,but I doubt that.My public methods can be decompiled too.What is so 'private' in a private method? EDIT: I'm not asking how to prevent my program to be decompiled,I'm asking whether I should use static,private and public.And also : Is there are problem in putting all the code in the form class so I dont have to use public methods?

View 6 Replies

Convert From Private/public .pem File?

Jul 27, 2010

It is possible convert a private / public rsa key from a .pem file in vb.net ? to xml file.

View 1 Replies

Have The Get Part Of A Property Available As Public But Keep The Set As Private?

Sep 22, 2009

is there a way to have the Get part of a property available as public, but keep the set as private?Otherwise I am thinking I need two properties or a property and a method, just figured this would be cleaner.

View 3 Replies

Make A Dataset From Private To Public?

Jul 5, 2011

basically how do I make my dataset public so I can access it on another form.

Dim ds As New DataSet("Dataset1")
Dim filePath As String
OpenFileDialog1.ShowDialog()
filePath = OpenFileDialog1.FileName
ds.ReadXmlSchema(filePath)

[Code]...

View 2 Replies

Make A Property Public Get But Private Set?

Apr 25, 2009

I just stumbled over this in some C# code...:public Foo Foo { get; private set; }

View 2 Replies

Private / Public - Subtracting Variables

Mar 11, 2010

I am a little new to .NET Developing, and have learned a great deal recently, but I'm stuck with something. I come from an ASP Background, I'm trying to subtract 2 variables, but they don't seem to 'see' one another.

[Code]...

View 6 Replies

Private And Public Interface Implementation In VB Not In C#

Oct 27, 2009

Private Sub ActivateMe(ByVal active As Boolean) Implements IGraphicControl .ActivateMe compiles.How is possible in VB.NET? A private method can be an interface implementation. VB.NET... a lot of compliments to this language and IDE..

View 6 Replies

Public Variable Goe Out Of Scope In Private Sub?

Aug 23, 2009

I have a public variable which seems to be going out of scope. I am confused as it has been dimensioned as a public variable: Public xlCell as As Microsoft.Office.Interop.Excel.Range

I originally had all my code in the same module in the same project and it was wrapped within a For/Next Loop (Example 1). I decided to clean up my code and make it more modular (Example 2). All the code is still in the same module in the same project.

Upon doing so, my public variable is not recognized in any of the private subs that I have created. I keep getting the following error: Message="Object reference not set to an instance of an object." When I test the variable using ?IsNothing(xlCell) in the Main Sub I get False in the main sub. this tells me te variable is recognized. However as soon as the Call SelectCaseSub() is triggered, I get a True value for ?IsNothing(xlCell). Why is this? Shouldn't this variable be in scope regardless?

[Code]...

View 6 Replies

Using Public/Private Keys In Reverse?

May 26, 2010

I have a situation where I need to make some data available for reading by anyone from a specific device, where the data is pre-loaded on the device, but I cannot allow anyone to create their own device and populate it with their own data in the same format.I know this sounds a little crazy, but there is a good reason!I was planning to use Public Key cryptography, encrypting the data with a public key, but then publishing the private key to anyone who wants to read the data.

View 1 Replies

Class Private/Public Naming Conventions?

Mar 25, 2011

I'm relatively new to .NET and am wondering how people handle naming their private variables and the public properties that access them. Like if you want to be able to just read it, but not write to it.

[Code]...

So far I've taken to putting a 'l' (for local) in front of the all the private variables so as to be able to use the full name for the property. Is there a better way around this, or do you just always have to have different names for private variable/public properties? If so, what sort of conventions do people use?

Its not a huge deal, its just a minor annoyance and I was wondering if I was missing something.

View 4 Replies

Class, Method, Namespace, Private Vs Public?

Feb 16, 2012

what websites, books or courses you guys suggest to use so I learn the fundamentals of programming. What is a class, method, namespace, private vs public. That leads me into .Net programming. A lot of intro to programming use java or C++ as the platform but I want to find one with VB.net or maybe C# if.

View 6 Replies

Property ReadWrite In Private And ReadOnly In Public?

Feb 23, 2009

Can i have a property that is Readonly for Public but can Read/Write in Private?

View 4 Replies

Completely Hide All Constructor Subs Whether PRIVATE Or PUBLIC?

Jul 19, 2010

If you have a class with a PRIVATE constructor.>>

Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim example1 As New ExampleClass[code]......

View 5 Replies

Copying A Set Of Private Variables Into Corresponding Public ReadOnly Properties?

Oct 18, 2011

I have a bunch of private variables I've typed out and I want to put all of my corresponding Public ReadOnly Properties in a bunch below them.Is there some way of copying ten lines of

Private _myVar As String

and pasting in ten sets of

Public Readonly Property MyVar As String
Get
Return _myVar[code]....

I'm currently copying the whole bunch of variable declarations, Find+Replacing Private _ into Public ReadOnly Property then going line-by-line expanding the definitions and writing return statements.how to avoid all this nonsense in the future, as I'm developing on a virtual terminal server, and the input lag on my little copy/paste/type operations on the code is driving me up the wall.

View 1 Replies

Difference Between A Private, Public, Shared Functions/Sub/Variables?

Jul 22, 2009

give me a good resource that explains the difference between a Private, Public, Shared Functions/Sub/Variables? I normally use Public for Subs/Functions inside of Modules I call from other parts of the program. But I'd like to get more of an understanding of how and when to use them. I want as little as impact to a system that is running my programs as possible, so i guess the key here is I'm trying to just get more proficient in my coding.

View 8 Replies

RSA: Generate RSA Public And Private Keys Based On A Passphrase (.net)?

Mar 24, 2011

I'm working in .net environment (all versions) and using vb.net. I want to generate RSA public and private keys based on a passphrase. RSA algorithm only limited by using a class provided by the .net ie System.Security.Cryptography.RSACryptoServiceProvider Class. I know how to generate random RSA public/private keys and perform encryption/decryption.But that .net class don't let us creating RSA public/private keys based on a passphrase.

View 4 Replies

VS 2008 - Comparing Variables In Private Sub With Public Class

Nov 11, 2009

I have these list of RS-232 strings declared in my public class
Public Class TouchInterface
Dim WatchTVbtnCmd As String = "rs232command1"
Dim VolUpbtnCmd As String = "rs232command2"
Dim VolDownbtnCmd As String = "rs232command3"
Dim SystemOffbtnCmd As String = "rs232command4"
Dim RadiobtnCmd As String = "rs232command5"
Dim MusicbtnCmd As String = "rs232command6"

I then have this private sub. For the sake of this thread, what I would like to do is get the name of the label that was clicked which in the code below is already done, convert it to string (not sure if this needs to be done), this is also done in the code below. Next I want to compare the labelnamestring to all the variables in the public class to find out which one it is equal to and then disply that variable which should be my rs232 string in the message box. I have also added "Cmd" to the variable names above so I also need to work out how to add the text "Cmd" to the string to properly compare.

Private Sub Musicbtn_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles WatchTvbtn.Click, VolUpbtn.Click, VolDownbtn.Click, SystemOffbtn.Click, Radiobtn.Click, Musicbtn.Click, GardenVolUpbtn.Click, GardenVolDownbtn.Click, GardenRadiobtn.Click, GardenOffbtn.Click, GardenMusicbtn.Click, GardenMediaCenterbtn.Click
Dim labelname As Label = DirectCast(sender, Label)
[Code] .....

View 6 Replies

Asp.net - Access A Module Or A Public Class With Public Shared Members From Inline Vb Code <% .. %>?

Feb 10, 2011

I can access a module from code behind but not from the aspx page in inline VB code <% ... %>.

View 2 Replies

VS 2008 - Difference Between Public, Private, Protected When Declaring Functions And Subs?

Jul 19, 2009

i have have a few questions about the syntax of the lan.:

1) What is the 'Get' statement and when do you use it?

2) Whats the difference between public, private, protected etc... when declaring functions and subs.

3) When would you use the overrides property?

View 4 Replies

DB/Reporting :: Calculate Rate For 3 Days In Different Rate Like Public Holiday,weekend And Normal For 1 Room?

Aug 19, 2009

how to calculate rate for 3 days in different rate like public holiday,weekend and normal for 1 room

View 2 Replies

VS 2005 Remove The Box (0x0A) Unix End Line Code; Then Replace It With CR+LF Normal ASCII Code?

Dec 13, 2009

I have this string just down loaded of a Unix server. I would like to remove the box (0x0A) Unix end line code; then replace it with CR+LF normal ASCII code. Also, I would like to do the replace before I save the data, while it in memory.

View 14 Replies

Xpath Coding For Different Sections Of The Xml Code?

Apr 10, 2009

I have an XML file (attached) that I need some help/advice xpath coding for different sections of the xml code.Below is a snippet (example) of the xml

<properties>
<list id="hnls">
<!-- START OF GUI HINTS AND TIPS -->
<record>

<string id="text" value="Selecting the national flag icon on any screen will take you to the senior national team screen.[COMMENT: Hints and Tips, GUI, Beginner Level, Note: tells the user how to use a shortcut to browse to national squad screens]" />

[Code]...

View 14 Replies

Locking Multiple Sections Of Code With Same Lock?

May 30, 2011

I have 3 web methods in a WCF, called 'DeleteGroup', 'AddGroup', 'ModifyGroup'.Each method has its own code. I want to place a lock on code within each method, so that only one method executes at a time. For example, if 'DeleteMethod' is being executed then no request for 'AddGroup' or 'ModifyGroup' can be executed. So may be I could use something like what is below, but not very sure ? Also, where in the WCF would I declare the locker object, and would it be private, public or static (i.e. shared)?

SyncLock locker
--Delete Method Body
End SyncLock

[code].....

View 3 Replies

Create Overview 'outline' Of Most Important Sections Of An App In Program?

May 1, 2009

I want to code in our VB.net to be a little easier to follow both to improve readability and also make it a lot easier to know the best place to put a new bit of code/feature.

Essentially, I'd like to have a 10,000 foot "outline" of the code" with hyperlinks from the outline to the code.

It needs to be portable, so BookMarks won't do the trick (I think). I'm thinking maybe TODO comments. I'd like to create our own Todo style comment like "Outline" or something but that keyword would need to be in the config file for VS as well (but then it's just one thing to keep sync'd).[code]...

View 4 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved