Go Back   Flash Flash Revolution > General Discussion > Chit Chat
Register FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
Old 03-2-2006, 10:43 AM   #1
djreality14
Banned
 
Join Date: Aug 2005
Location: Cresent Isle
Age: 33
Posts: 177
Send a message via MSN to djreality14
Exclamation VB.net

I'm currently making an extremly large program, and I'd like to know if there's a way to pull a variable from one form and use it in another. I've tried the SHARED and FRIEND functions, but neither of them work.
djreality14 is offline   Reply With Quote
Old 03-3-2006, 09:02 PM   #2
chickendude
Away from Computer
FFR Simfile AuthorFFR Veteran
 
chickendude's Avatar
 
Join Date: Sep 2003
Location: Massachusetts
Age: 33
Posts: 1,901
Send a message via AIM to chickendude
Default Re: VB.net

I think you have to make it a global variable.
I haven't used VB in a long time, so I'm not sure how, but that might be somewhere to start looking.
__________________
chickendude is offline   Reply With Quote
Old 03-3-2006, 09:34 PM   #3
deposition
FFR Player
 
deposition's Avatar
 
Join Date: Feb 2004
Location: Indianapolis, IN
Posts: 1,115
Send a message via MSN to deposition
Default Re: VB.net

This is exactly what modules are for. Any variable and any function, that is in the module, can publically be accessed as if it were a local object, the way you normally would. Just go to project, add module, and dimension the variable as global or public ie. "Global foovariable" or "Public foovariable".


Most professionals put almost all of their functions and main variables for specific task related programs in here, so later, if they are working on a project in which they could use some of what they already wrote, they can easily import the module and call those functions.
__________________

Last edited by deposition; 03-3-2006 at 09:41 PM..
deposition is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT -5. The time now is 08:18 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright FlashFlashRevolution