|
|
|
LPWSTR to LPSTR
|
|||
|---|---|---|---|
|
#18+
Подскажите как можно перевести LPWSTR в LPSTR Код: plaintext 1. 2. 3. 4. Заранее благодарен за ответ -=<TaReN>=- ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 25.04.2006, 09:54 |
|
||
|
LPWSTR to LPSTR
|
|||
|---|---|---|---|
|
#18+
Может надо: LPWSTR wstr= L "123456789"; Есть еще API-функция WideCharToMiltiByte... ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 25.04.2006, 10:17 |
|
||
|
LPWSTR to LPSTR
|
|||
|---|---|---|---|
|
#18+
Код: plaintext 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 25.04.2006, 10:24 |
|
||
|
LPWSTR to LPSTR
|
|||
|---|---|---|---|
|
#18+
Пасиб все работет Только вопросик маленький: Почему объявляешь строку длиной 1024 Код: plaintext Код: plaintext 1. 2. 3. 4. 5. 6. 7. 8. 9. -=<TaReN>=- ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 25.04.2006, 10:39 |
|
||
|
LPWSTR to LPSTR
|
|||
|---|---|---|---|
|
#18+
для строкового терминатора '\0' ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 25.04.2006, 10:46 |
|
||
|
LPWSTR to LPSTR
|
|||
|---|---|---|---|
|
#18+
Поскольку шестой параметр в этой ф-ции: MSDN cbMultiByte [in] Specifies the size, in bytes, of the buffer pointed to by the lpMultiByteStr parameter. If this value is zero, the function returns the number of bytes required for the buffer. (In this case, the lpMultiByteStr buffer is not used.) , то все-таки правильнее будет 1024 . ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 25.04.2006, 10:59 |
|
||
|
|

start [/forum/topic.php?fid=57&msg=33687799&tid=2031451]: |
0ms |
get settings: |
7ms |
get forum list: |
20ms |
check forum access: |
3ms |
check topic access: |
3ms |
track hit: |
193ms |
get topic data: |
10ms |
get forum data: |
2ms |
get page messages: |
58ms |
get tp. blocked users: |
2ms |
| others: | 216ms |
| total: | 514ms |

| 0 / 0 |
