New topic: 

declare string variable size?

<http://forums.realsoftware.com/viewtopic.php?t=38708>

         Page 1 of 1
   [ 1 post ]                 Previous topic | Next topic          Author  
Message        luthepa1          Post subject: declare string variable 
size?Posted: Thu Apr 21, 2011 1:06 am                         
Joined: Tue Apr 12, 2011 4:33 am
Posts: 4                Hey all,

Did a quick search but did not find the answer I am after.  Could be because I 
dont really know how to sum up what I want to find as a search criteria.

Anyways, is it possible to specify the size of a string variable in terms of 
bytes/characters?  I thought I read some where you would do such a thing this 
way 
Code:Dim test1 As String*10

Another words create the string variable "test1" that can hold 10 characters 
only.  I know the limitation is basic how much RAM use have but I want a much 
lower limit.  Or is it that a string variable only uses as much RAM as the 
contents it holds?  I am creating an array of a class and am trying to find 
ways to reduce the amount of RAM it takes up.  Here is the class I am creating 
an array of.

Code:clsLogFileArray.Constructor:
Sub Constructor(Date As String, Time As String, tModule As String, Data As 
String, Extra As String, visible As Boolean, filterHit As Boolean)

f1Date = Date 
f2Time = Time 
f3Module = tModule 
f4Data = Data 
f5Extra = Extra 
f6Visible = visible 
f7Filterhit = filterHit
End Sub 

f1Date As String
f2Time As String 
f3Module As String 
f4Data As String 
f5Extra As String 
f6Visible As Boolean 
f7FilterHit As Boolean


End Class

P.S.  Not sure how you guys take a class in RealStudio to display in a nice 
neat format in posts where the code includes the function/procedure statement 
and all that.  I jsut perform print from right click of the class and copy n 
paste.   
                             Top            Display posts from previous: All 
posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost 
timeSubject AscendingDescending          Page 1 of 1
   [ 1 post ]      
-- 
Over 1500 classes with 29000 functions in one REALbasic plug-in collection. 
The Monkeybread Software Realbasic Plugin v9.3. 
http://www.monkeybreadsoftware.de/realbasic/plugins.shtml

[email protected]

Reply via email to