how to crect the error
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums
Results 1 to 2 of 2

Thread: how to crect the error

  1. #1
    Join Date
    Aug 2011

    Wink how to crect the error

    Hi all .
    I want to ask a question. I wrote a program , but when compiling , it reminds there are something wrong with the following code:
                      if(err = WFS_init (instr.selected_id, &instr.handle))
    WFS_init () is one of the lib functions I used in the program and other lib functions are OK. What's more, the WFS_init() function also works well when I use it in other programs. the error is like this:
    error C2664: 'WFS_init' : cannot convert parameter 2 from 'int *' to 'unsigned long *'
            Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or   function-style cast
    Last edited by Angela2010; September 6th, 2011 at 03:17 AM.

  2. #2
    Join Date
    Sep 2004
    Holland (land of the dope)

    Re: how to crect the error

    The error message is quite clear. You are converting a int-pointer to a unsigned long-pointer without safely casting it.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Windows Mobile Development Center

Click Here to Expand Forum to Full Width

This is a survey!

HTML5 Development Center