Need help with this error

Status
Not open for further replies.
Joined
Nov 29, 2009
Messages
370
Reaction score
26
Hello,
I added the party finder system to my server so i added the source edits to the relevant places and it compiled and runs, but when ingame and trying to open the party window the client crashes and produces an error, i am unsure whats going wrong and have no idea what the nID=912 is (i did search it in the source for the error output info and i couldn't understand it)

Code:
2012/ 7/ 9   01:06:33   GetDlgItem : nID=912 not Found.


I added to my resdata.inc

Code:
	WTYPE_BUTTON WIDC_CHECK1 "ButtCheck.bmp" -842150451 190 76 308 70 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_102692
    }
    {
    // ToolTip
IDS_RESDATA_INC_102693
    }

and this to resdata.txt.txt
Code:
IDS_RESDATA_INC_102692	Refuse Join
IDS_RESDATA_INC_102693	Refuses join for people searching for a party to join.

An explanation of how to avoid this error in the future would be nice as well
 
GetDlgItem description on MSDN:
Retrieves a pointer to the specified control or child window in a dialog box or other window.

It looks to me as if it cannot find the party window. Could you share the place you got the party finder system from, so we can take a look at what possibly could've gone wrong?
 
The only thing I've found:
Simply use Daisy and add a checkBox in the party window.
Just give it the ID from the Source. (WIDC_CHECK_1)

I hope you'll be able so get some closer to the solution, good luck.
 
Ow thanks, i added the WIDC_CHECK1 this could be the problem then? (in their source it shows a check for WIDC_CHECK1 not WIDC_CHECK_1

I edited the WIDC_CHECK1 to WIDC_CHECK_1 and it made no difference, it still doesn't show up properly, i still get these errors

Code:
2012/ 7/12   21:09:30   CWndParty::CWndParty()

2012/ 7/12   21:09:30   CWndParty::Initialize() - IN

2012/ 7/12   21:09:30   CWndParty::OnInitialUpdate() - IN

2012/ 7/12   21:09:30   CWndParty::OnInitialUpdate() - OUT

2012/ 7/12   21:09:30   CWndParty::Initialize() - OUT

2012/ 7/12   21:09:30   GetDlgItem : nID=912 not Found.

MY FULL PARTY RES DATA - the check box is highlighted in red
Code:
APP_PARTY "WndTile07.tga" "" 1 448 336 0x2410000 26
{
// Title String
IDS_RESDATA_INC_002674
}
{
// Help Key
IDS_RESDATA_INC_002675
}
{
    WTYPE_STATIC WIDC_GROUPBOX1 "" 1 8 8 146 26 0x220001 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002676
    }
    {
    // ToolTip
IDS_RESDATA_INC_002677
    }
    WTYPE_STATIC WIDC_GROUPBOX3 "" 1 190 8 282 28 0x220001 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002678
    }
    {
    // ToolTip
IDS_RESDATA_INC_002679
    }
    WTYPE_STATIC WIDC_GROUPBOX4 "" 1 316 8 430 28 0x220001 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002680
    }
    {
    // ToolTip
IDS_RESDATA_INC_002681
    }
    WTYPE_BUTTON WIDC_ITEM_SHARE "ButtRadio.bmp" -842150451 316 34 430 50 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002682
    }
    {
    // ToolTip
IDS_RESDATA_INC_002683
    }
    WTYPE_BUTTON WIDC_RADIO2 "ButtRadio.bmp" -842150451 316 54 430 70 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002684
    }
    {
    // ToolTip
IDS_RESDATA_INC_002685
    }
    WTYPE_BUTTON WIDC_RADIO3 "ButtRadio.bmp" -842150451 316 74 430 90 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002686
    }
    {
    // ToolTip
IDS_RESDATA_INC_002687
    }
    WTYPE_BUTTON WIDC_RADIO4 "ButtRadio.bmp" -842150451 316 94 430 110 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002688
    }
    {
    // ToolTip
IDS_RESDATA_INC_002689
    }
    WTYPE_BUTTON WIDC_EXP_SHARE "ButtRadio.bmp" -842150451 190 32 308 48 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002690
    }
    {
    // ToolTip
IDS_RESDATA_INC_002691
    }
    WTYPE_BUTTON WIDC_RADIO6 "ButtRadio.bmp" -842150451 190 54 308 70 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002692
    }
    {
    // ToolTip
IDS_RESDATA_INC_002693
    }
[COLOR="#FF0000"]	[B]WTYPE_BUTTON WIDC_CHECK1 "ButtCheck.bmp" -842150451 190 76 308 70 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_012692
    }
    {
    // ToolTip
IDS_RESDATA_INC_012693
    }[/B][/COLOR]
    WTYPE_STATIC WIDC_STATIC1 "" -842150451 8 34 72 52 0x260000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002694
    }
    {
    // ToolTip
IDS_RESDATA_INC_002695
    }
    WTYPE_STATIC WIDC_STATIC2 "" -842150451 8 54 72 74 0x260000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002696
    }
    {
    // ToolTip
IDS_RESDATA_INC_002697
    }
    WTYPE_STATIC WIDC_STATIC3 "" -842150451 8 74 76 94 0x260000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002698
    }
    {
    // ToolTip
IDS_RESDATA_INC_002699
    }
    WTYPE_STATIC WIDC_STATIC4 "" -842150451 8 94 76 110 0x260000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002700
    }
    {
    // ToolTip
IDS_RESDATA_INC_002701
    }
    WTYPE_STATIC WIDC_NAME "" -842150451 78 34 150 50 0x260000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002702
    }
    {
    // ToolTip
IDS_RESDATA_INC_002703
    }
    WTYPE_STATIC WIDC_LEVEL "" -842150451 78 54 150 70 0x260000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002704
    }
    {
    // ToolTip
IDS_RESDATA_INC_002705
    }
    WTYPE_STATIC WIDC_EXP "" -842150451 78 74 142 90 0x260000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002706
    }
    {
    // ToolTip
IDS_RESDATA_INC_002707
    }
    WTYPE_STATIC WIDC_POINT "" -842150451 78 94 142 110 0x260000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002708
    }
    {
    // ToolTip
IDS_RESDATA_INC_002709
    }
    WTYPE_TABCTRL WIDC_TABCTRL1 "" -842150451 10 118 448 266 0x20260000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002710
    }
    {
    // ToolTip
IDS_RESDATA_INC_002711
    }
    WTYPE_BUTTON WIDC_LEAVE "ButtLeave.bmp" -842150451 184 276 256 296 0x220000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002712
    }
    {
    // ToolTip
IDS_RESDATA_INC_002713
    }
    WTYPE_BUTTON WIDC_CHANGE "ButtChange.bmp" -842150451 306 276 378 296 0x220000 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002714
    }
    {
    // ToolTip
IDS_RESDATA_INC_002715
    }
    WTYPE_BUTTON WIDC_BUTTON1 "ButtTransper.bmp" -842150451 54 276 126 296 0x220010 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_002716
    }
    {
    // ToolTip
IDS_RESDATA_INC_002717
    }
    WTYPE_BUTTON WIDC_BUTTON2 "" 0 418 286 428 296 0x220010 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_003852
    }
    {
    // ToolTip
IDS_RESDATA_INC_003853
    }

}
 
Last edited:
I'm not 100% sure about this, but I'm pretty sure. The positioning in that coding is wrong:
Code:
 WTYPE_BUTTON WIDC_CHECK1 "ButtCheck.bmp" -842150451 190 76 308 70 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_012692
    }
    {
    // ToolTip
IDS_RESDATA_INC_012693
    }

See the 190 76 308 70 part? Those are x and y positions (in the form of x1 y1 x2 y2), to define the area in which the control is displayed. I'm pretty sure x2/y2 should ALWAYS be greater than x1/y1... If you fix that, I'm sure it would work.
 
Well that could be the problem, but i don't see how it makes a difference, all that would do is not show the box itself if that was causing the issue?

I took your suggestion ShadowDragon42 and it doesn't actually make a difference

it is now
Code:
	WTYPE_BUTTON WIDC_CHECK1 "ButtCheck.bmp" -842150451 190 76 308 92 0x220004 0 0 0 0 46 112 169
    {
    // Title String
IDS_RESDATA_INC_012692
    }
    {
    // ToolTip
IDS_RESDATA_INC_012693
    }

As you will notice with every other x1 y1 and x2 y2 the x's on all the buttons/option are the same, but the y's are different by 16 points (on every button/option in the same line)
 
Last edited:
Okey tired of looking at you will tell you how I add items to window.
First I create the code of window:
Code:
APP_MAIN "WndTile00.tga" "" 1 288 214 0x610000 26
{
// Title String
IDS_RESDATA_INC_008792
}
{
// Help Key
IDS_RESDATA_INC_008793
}
{
    WTYPE_BUTTON WIDC_LOGIN_BUTTON "" 0 8 8 282 58 0x220010 0 0 0 0 255 255 255
    {
    // Title String
IDS_RESDATA_INC_008794
    }
    {
    // ToolTip
IDS_RESDATA_INC_008795
    }
    WTYPE_BUTTON WIDC_OPTION_BUTTON "" 0 8 58 282 108 0x220010 0 0 0 0 255 255 255
    {
    // Title String
IDS_RESDATA_INC_008796
    }
    {
    // ToolTip
IDS_RESDATA_INC_008797
    }
    WTYPE_BUTTON WIDC_REGISTER_BUTTON "" 0 8 108 282 158 0x220010 0 0 0 0 255 255 255
    {
    // Title String
IDS_RESDATA_INC_008798
    }
    {
    // ToolTip
IDS_RESDATA_INC_008799
    }
    WTYPE_BUTTON WIDC_EXIT_BUTTON "" 0 8 160 282 210 0x220010 0 0 0 0 255 255 255
    {
    // Title String
IDS_RESDATA_INC_008800
    }
    {
    // ToolTip
IDS_RESDATA_INC_008801
    }

}

Then To do something with It I go to prepared class that shows the window. I go to function OnInitialUpdate and I try to get the items that widnow has:
Code:
void CWndMain::OnInitialUpdate()
{
    CWndNeuz::OnInitialUpdate();
    pLogin    = (CWndButton*) GetDlgItem( WIDC_LOGIN_BUTTON );
    pOption   = (CWndButton*) GetDlgItem( WIDC_OPTION_BUTTON );
    pRegister = (CWndButton*) GetDlgItem( WIDC_REGISTER_BUTTON );
    pExit     = (CWndButton*) GetDlgItem( WIDC_EXIT_BUTTON );
}

It has never failed to me. try it before adding suck options.
 
Status
Not open for further replies.
Back