LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default VBA passing information between differnt User Forms

Hi u,

the task is as following :

When User Form1 (UF1) is called, it checks for a value in a Sheet. If
the value isn't set UF1 croaks and sets a flag to be passed to a
UserForm (UF2) where the value is to be set.

Searching 4 the solution I found Public Properties the most suitable
way solving my task. But i didn't got the string yet. In UF2 the
flagRogue keeps empty.

Due to what I found I tried following:

in: UF1
'---------------
private flagRogue as string
publicproperty get flagStatus() as String
flagStatus = flagCroak
end property
publicproperty let flagStatus(byval flagVal as String)
flagStatus = flagRogue
end property
'--------------
' Initialize:
dim wannaSthg as new UF2
...
if <no Value Then
<croak
flagRogue = 1
wannaSthg.flagRogue = Me.flagRogue
wannaSthg.Show
end if


in UF2
'-------------
private flagRogue as string
publicproperty get flagStatus() as String
flagStatus = flagCroak
end property
publicproperty let flagStatus(byval flagVal as String)
flagStatus = flagRogue
end property
'--------------
' Initialize:
dim wannaSthg as new UF2
...
if flagRogue Then
<do something
else
<do something else
end if

Question:
Where I'm wrong ???

thanx 4 helping
VBR

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Passing a Forms Control to Function Pflugs Excel Programming 5 August 24th 06 10:34 PM
passing variables between 2 forms burl_rfc Excel Programming 3 April 14th 06 05:49 AM
Passing variables between forms Sami82[_8_] Excel Programming 7 October 8th 05 12:12 AM
Why is the information on preview screen differnt than on normal . kaylaaj Excel Worksheet Functions 1 March 17th 05 06:03 PM
User Forms - passing data between them mickiedevries Excel Programming 3 June 21st 04 08:59 PM


All times are GMT +1. The time now is 04:20 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"