﻿ LVectorDialog::IsValid | LVectorDialog Class Members | Vector C++ Class Library Help
In This Topic ▼

# LVectorDialog::IsValid

#include "ltwrappr.h"

L_BOOL LVectorDialog::IsValid(L_VOID)

Determines whether the LVectorDialog object is valid.

#### Returns

Value Meaning
TRUE There is a pointer to a valid bitmap object.
FALSE There is not a pointer to a valid bitmap object.

Call this function to check if the class object has been associated with a valid LVectorBase object.

Before you can use some of the LVectorDialog functions, a vector must be associated with the class object. Until you have associated a valid vector object with the LVectorDialog object, this function will return false.

In particular, you cannot perform auto-processing without a valid bitmap.

Required DLLs and Libraries

## Example

````L_INT LVectorDialog__IsValidExample(HWND hWnd) `
`{ `
`   L_INT          nRet; `
`   LVectorBase    Vector; `
`   LVectorDialog  VectorDlg; `
` `
`   //Dialog is invalid unless associated with a vector `
`   if (VectorDlg.IsValid ()) `
`      MessageBox(hWnd, TEXT("IsValid() returns TRUE"), TEXT(""), MB_OK); `
`   else `
`      MessageBox(hWnd, TEXT("IsValid() returns FALSE"), TEXT(""), MB_OK); `
` `
`   nRet = Vector.Load(MAKE_IMAGE_PATH(TEXT("random.dxf"))); `
`   if(nRet != SUCCESS) `
`      return nRet; `
` `
`   VectorDlg.SetVector(&Vector); `
` `
`   //Now dialog is valid `
`   if (VectorDlg.IsValid()) `
`      MessageBox(hWnd, TEXT("IsValid() returns TRUE"), TEXT(""), MB_OK); `
`   else `
`      MessageBox(hWnd, TEXT("IsValid() returns FALSE"), TEXT(""), MB_OK); `
` `
`   //destructor called when out of scope `
` `
`   return SUCCESS; `
`} ````
Help Version 21.0.2021.4.7
{"ft_lang_label":"__label__en","ft_lang_prob":0.5853601,"math_prob":0.8159585,"size":2270,"snap":"2021-21-2021-25","text_gpt3_token_len":540,"char_repetition_ratio":0.123565756,"word_repetition_ratio":0.1550152,"special_character_ratio":0.24052863,"punctuation_ratio":0.17317073,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.9605842,"pos_list":[0],"im_url_duplicate_count":[null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2021-05-17T19:52:25Z\",\"WARC-Record-ID\":\"<urn:uuid:59b19932-49c0-41fd-82c8-4049471353cf>\",\"Content-Length\":\"226848\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:67411028-718a-4cfd-b343-6ab6804825cf>\",\"WARC-Concurrent-To\":\"<urn:uuid:3022311b-1703-4b8e-9b2c-cb71c8dc1c31>\",\"WARC-IP-Address\":\"216.134.197.5\",\"WARC-Target-URI\":\"https://www.leadtools.com/help/sdk/v21/vector/clib/lvectordialog-isvalid.html\",\"WARC-Payload-Digest\":\"sha1:EJRQGMVESUQ5Z2HZFCVJENKRWUAFHENE\",\"WARC-Block-Digest\":\"sha1:ZW7ZOT2L3QETHFFIGCFCPBIVTWDLKSSI\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2021/CC-MAIN-2021-21/CC-MAIN-2021-21_segments_1620243992440.69_warc_CC-MAIN-20210517180757-20210517210757-00439.warc.gz\"}"}