forum.vdsworld.com Forum Index forum.vdsworld.com
Visit VDSWORLD.com
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Help with Table row Height and multiple tables

 
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help
View previous topic :: View next topic  
Author Message
marcelo
Contributor
Contributor


Joined: 10 May 2008
Posts: 93

PostPosted: Wed Apr 05, 2017 5:41 am    Post subject: Help with Table row Height and multiple tables Reply with quote

Hi. I´ve been using this code to set tables icons in any format for a long time but i have a problem right now.
If i try to use more than one table in a dialog, this affect to all tables and i cant control it... Crying or Very sad

I'm trying to set icons in 48x48 to Table2 but keep standard row heigh to Table1.
What i'm doing wrong or how can a solve it?

Code:

  DIALOG CREATE,New Dialog,-1,0,880,467
  DIALOG ADD,TABLE,TABLE1,27,40,800,181,Column 1[700]
  DIALOG ADD,TABLE,TABLE2,235,40,802,188,Column 1[700]
  DIALOG SHOW


# Full Row Select #
%x = @sendmsg(@winexists(~Table1),@sum($1000,54),0,$0020)
%x = @sendmsg(@winexists(~Table2),@sum($1000,54),0,$0020)

# Remove table title
LOADLIB USER32.DLL
%H = @STRDEL(@WINEXISTS(~Table2),1,1)
IF %H
   %O = @LIB(USER32,GetWindowLongA,INT:,%H,-16)
   %Z = @LIB(USER32,SetWindowLongA,INT:,%H,-16,@SUM(%O,-600000))
END

# 48x48 icons
%x = @SENDMSG(@WINEXISTS(~Table2),@SUM($1000,2),1,0)
Loadlib comctl32.dll
%x = @lib(comctl32.dll,ImageList_SetIconSize,BOOL:,%x,48,48)
Freelib comctl32.dll

list clear,Table1
list put,Table1,"    Item1"
list put,Table1,"    Item2"
list put,Table1,"    Item3"

list clear,Table2
list put,Table2,"    Item1"|Icon1.bmp
list put,Table2,"    Item2"|Icon1.bmp
list put,Table2,"    Item3"|Icon1.bmp
 
wait event



icon1.bmp
 Description:
 Filesize:  6.8 KB
 Viewed:  1939 Time(s)

icon1.bmp


Back to top
View user's profile Send private message
cnodnarb
Valued Contributor
Valued Contributor


Joined: 11 Sep 2002
Posts: 641
Location: Evansville, IN

PostPosted: Sun Apr 09, 2017 10:38 pm    Post subject: Reply with quote

I understand the problem... the only solution I can think of is to host the controls in separate windows. Then you would glue the window onto the parent.

Code:

LOADLIB user32.dll
 if @ok()
 %%k = @strdel(@winexists(@dlgtext()),1,1)
  %%knockout = @lib(user32,SetWindowLongA,INT:,%%k,-16,$40000000)
 %%controlsampledummy = @lib(user32.dll,SetParent,NIL,%%k,@strdel(@winexists(@dlgtext(browserparent)),1,1))
 end
 FREELIB user32.dll
Back to top
View user's profile Send private message AIM Address
marcelo
Contributor
Contributor


Joined: 10 May 2008
Posts: 93

PostPosted: Mon Apr 24, 2017 2:14 am    Post subject: Reply with quote

Thanks a lot! I will test that code...
Back to top
View user's profile Send private message
marcelo
Contributor
Contributor


Joined: 10 May 2008
Posts: 93

PostPosted: Mon Apr 24, 2017 10:27 am    Post subject: Reply with quote

Ups. I think i don't understand how it works... Crying or Very sad
Back to top
View user's profile Send private message
marcelo
Contributor
Contributor


Joined: 10 May 2008
Posts: 93

PostPosted: Fri Apr 28, 2017 1:43 pm    Post subject: Reply with quote

No. Definitively don't understand what Cnodnarb proposed...
Any help with this?
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum




Twitter@vdsworld       RSS

Powered by phpBB © 2001, 2005 phpBB Group