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 


CreateWindowEx

 
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> Advanced Help for VDS 5 & Up
View previous topic :: View next topic  
Author Message
Skit3000
Admin Team


Joined: 11 May 2002
Posts: 2166
Location: The Netherlands

PostPosted: Sat Jan 03, 2004 2:53 pm    Post subject: CreateWindowEx Reply with quote

Hello,

With the new VDS update, we can finally use the CreateWindowEx function... Smile This is how far I came. Does anybody know how to get notified when a user presses a button?

Thanks

Code:
# http://yokohama.cool.ne.jp/chokuto/urawaza/api/CreateWindowEx.html

DIALOG CREATE,Nieuw Dialoog,-1,0,600,500
  DIALOG SHOW

%%win = @strdel(@winexists(@dlgtext()),1,1)

loadlib user32

%%hButton = @lib(user32,CreateWindowExA,INT:,0,"BUTTON","I'm a Button",@sum($10000000,$40000000,8388608),5,5,120,30,%%win,@sum(2024,1),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"EDIT","I'm a Button",@sum($10000000,$40000000,8388608,$4),130,5,120,30,%%win,@sum(2024,2),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"LISTBOX","I'm a Button",@sum($10000000,$40000000,8388608),5,40,120,250,%%win,@sum(2024,3),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"SCROLLBAR","I'm a Button",@sum($10000000,$40000000,8388608),130,50,120,20,%%win,@sum(2024,4),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"COMBOBOX","I'm a Button",@sum($10000000,$40000000,8388608),130,75,120,20,%%win,@sum(2024,5),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"MSCTLS_TRACKBAR32","I'm a Button",@sum($10000000,$40000000,8388608),130,100,120,30,%%win,@sum(2024,6),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"STATIC","I'm a Button",@sum($10000000,$40000000,8388608),130,135,120,20,%%win,@sum(2024,7),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"MSCTLS_UPDOWN32","I'm a Button",@sum($10000000,$40000000,8388608),255,5,120,200,%%win,@sum(2024,Cool,0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"SysTreeView32","Testje",@sum($10000000,$40000000,8388608),130,160,120,120,%%win,@sum(2024,9),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"BUTTON","Radiobutton!",@sum($10000000,$40000000,8388608,$4),280,5,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"BUTTON","CheckBox!",@sum($10000000,$40000000,8388608,$2),280,40,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"msctls_progress32","Test",@sum($10000000,$40000000,8388608),280,75,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"msctls_statusbar32","Statusbar",@sum($10000000,$40000000,8388608),280,110,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"ToolbarWindow32","Statusbar",@sum($10000000,$40000000,8388608),280,110,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"ComboBoxEx32","Statusbar",@sum($10000000,$40000000,8388608),280,110,120,80,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"SysHeader32","Statusbar",@sum($10000000,$40000000,8388608),280,195,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"SysDateTimePick32","Statusbar",@sum($10000000,$40000000,8388608),280,230,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"SysMonthCal32","Statusbar",@sum($10000000,$40000000,8388608),280,265,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"ReBarWindow32","BAR ABOVE",@sum($10000000,$40000000,8388608),280,300,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"SysIPAddress32","TEST",@sum($10000000,$40000000),280,300,120,30,%%win,@sum(2024,10),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"SysPager","TEST",@sum($10000000,$40000000,8388608),280,335,120,30,%%win,@sum(2024,10),0,0)


%%hButton = @lib(user32,CreateWindowExA,INT:,0,"EDIT","Numbers Only",@sum($10000000,$40000000,$2000),5,290,120,20,%%win,@sum(2024,2),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"EDIT","lowercase only",@sum($10000000,$40000000,$10),5,315,120,20,%%win,@sum(2024,2),0,0)
%%hButton = @lib(user32,CreateWindowExA,INT:,0,"EDIT","uppercase only",@sum($10000000,$40000000,$8,$1000,8388608),5,340,120,20,%%win,@sum(2024,2),0,0)


wait 50,event

freelib user32

_________________
[ Add autocomplete functionality to your VDS IDE windows! ]
Voor Nederlandse beginners met VDS: bekijk ook eens deze tutorial!


Last edited by Skit3000 on Sun Jan 04, 2004 11:28 am; edited 1 time in total
Back to top
View user's profile Send private message
CodeScript
Moderator Team


Joined: 08 Jun 2003
Posts: 1060
Location: India

PostPosted: Sat Jan 03, 2004 4:35 pm    Post subject: Reply with quote

Hi Skit
Thanks for listing all the options available.
I had worked with CreateWindowEx using VDSUG for quite sometime.

msdn wrote:
The BN_CLICKED notification code is sent when the user clicks a button.

The parent window of the button receives the BN_CLICKED notification code through the WM_COMMAND message.

LRESULT CALLBACK WindowProc(
HWND hwnd, // handle to window
UINT uMsg, // WM_COMMAND
WPARAM wParam, // identifier of button, BN_CLICKED
LPARAM lParam // handle to button (HWND)
);

I don't think it is possible in VDS as these type of API aren't supported
Further VDS dialog is subclassed and these messages are local to the
class. I may be wrong though.

_________________
Regards
- CodeScript
Arrow Give your application a professional look with the VDSGUI Extension
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> Advanced Help for VDS 5 & Up 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