Help - Search - Members - Calendar
Full Version: visualbasic question
InsanelyMac Forum > Discuss and Learn > Windows Discussion
Stuuuuuu
hey all, first post for me,

if i declare a variable intK as integer, and set that variable equal to 5.4*2, what will be in that variable?

actual code would be:
dim intK as integer
intk = 5.4 * 2

hopefully someone out there has some basic skills
hecker
QUOTE(Stuuuuuu @ Sep 30 2008, 06:01 AM) *
hey all, first post for me,

if i declare a variable intK as integer, and set that variable equal to 5.4*2, what will be in that variable?

actual code would be:
dim intK as integer
intk = 5.4 * 2

hopefully someone out there has some basic skills

Since the variable is of integer type, it will ignore everything after the comma, so the result will be 10 in the above example.

Remember that the Integer type in VBA is limited to values between -32,768 to 32,767.
For calculations outside of this scope, use the Long type, which is 4-byte integer variable type (so the usuable range is 2^32).

Good luck!
Stuuuuuu
Thanks,

I didn't have a copy of visualbasic on my computer because I have switched over to osx86, and there is no way I am keeping an entire partition just for visualBasic and XP.

is there anything comparable to visualBasic for the mac? I don't really need programs to run on mac, just a compiler (it's for a class). I have heard of REALbasic, but the things I have heard are bad.

tomazzzi
QUOTE
is there anything comparable to visualBasic for the mac? I don't really need programs to run on mac, just a compiler (it's for a class). I have heard of REALbasic, but the things I have heard are bad.


I m runniong VB on the MAC with vmware fusion & XP

works great !
urlugal
I need to run XP Pro within Fusion 1.1.3 for both VB and Visual C++ with Visual Studio 2005 for school, and it works fine. You do need a good amount of Ram though. With 1 GB of ram it got tight with XP and Visual Studio, so I went too 4GB and I have no problems with lag or anything now. I also used XP and Visual Studio with Virtual Box as well. Virtual Box is open source and runs pretty good but Fusion is the best I feel.
Virtual Box

This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.