Filling a Structure Automatically

Filling a Structure Automatically

After a structure is defined witha “TYPE” declaration, do you know of a way to directly fillthe structure with data, rather than individually assigingthe elements, or reading from a file? I haven’t seen anyway in either the manuals, or in 4 different after marketreference books that I have.

Note: This answer came from the person who asked the question.

I used the code:

        TYPE StructType                ‘/* setup stucture of type char */                a AS STRING * 1                b AS STRING * 1                c AS STRING * 1                d AS STRING * 1        END TYPE        DIM Structure as StructType        ‘/* find the address of the first element */        ptrData& = VARPTR(Structure)        ‘/* then, if I know the structure elements size, */        ‘/*         I can POKE data into them */        Test$=”1234″        ‘/* place the ASCII representation of each char into structure */        for i% = 1 to len(Structure)                POKE i% + ptrStructure& – 1, ASC(MID$(Test$,i%,1))        NEXT        ‘/* display the elements */        PRINT CHR$(Structure.a)        PRINT CHR$(Structure.b)        PRINT CHR$(Structure.c)        PRINT CHR$(Structure.d)

Share the Post:
Heading photo, Metadata.

What is Metadata?

What is metadata? Well, It’s an odd concept to wrap your head around. Metadata is essentially the secondary layer of data that tracks details about the “regular” data. The regular

XDR solutions

The Benefits of Using XDR Solutions

Cybercriminals constantly adapt their strategies, developing newer, more powerful, and intelligent ways to attack your network. Since security professionals must innovate as well, more conventional endpoint detection solutions have evolved

AI is revolutionizing fraud detection

How AI is Revolutionizing Fraud Detection

Artificial intelligence – commonly known as AI – means a form of technology with multiple uses. As a result, it has become extremely valuable to a number of businesses across

AI innovation

Companies Leading AI Innovation in 2023

Artificial intelligence (AI) has been transforming industries and revolutionizing business operations. AI’s potential to enhance efficiency and productivity has become crucial to many businesses. As we move into 2023, several

data fivetran pricing

Fivetran Pricing Explained

One of the biggest trends of the 21st century is the massive surge in analytics. Analytics is the process of utilizing data to drive future decision-making. With so much of