Announcement

Collapse
No announcement yet.

microSDConst.inc not found

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • microSDConst.inc not found

    Hi all,
    beginning to write to disk but didnt find FILE_READ and so on constant, even if in the editor they seems to be recognized (they change color). I found in the AppNotes, in the example ViSi Read and Write to microSD, to include the file mentioned in the object, but the file is not present.
    Furthermore in the manual there is no reference that it must be included.
    Some help?
    Thanks
    Alessandro

  • #2
    File read is an internal function, the case must be correct as 4DGL is a case sensitive language.
    Mark

    Comment


    • #3
      Hi Mark
      sorry, but you missed the point (probably my English is not enough good).
      Both in the PDF and in the .4dg file there is a line sayng:
      "#inherit "microSDConst.inc"
      but this file does not exist (or I didn't found?).

      Furthermore, in the explanation for file_Open .pdf file, are mentioned 3 constant: FILE_READ, FILE_WRITE and FILE_APPEND, both in arguments and description sections. But non of them are defined, even if the first 2 are recognized (change colour) by the editor.

      At the end, it seems that the sample and the manual are not correct; or if they are correct, what I'm missing?

      Thanks
      Alessandro

      Comment


      • #4
        Sorry, I got confused by not being able to see what you were getting at and where.

        When you build a ViSi program a file called programnameconst.inc is created and this contains all the 'Visual' constants used by the program.

        Since the sample program is called microSD that is the const file for that program.

        The FILE_READ, etc 'names' are just used as 'labels' in the internal functions reference, they aren't actually defined anywhere. What the document is trying to say is to open a file for read (FILE_READ) use the character constant 'r', like in the example. It really doesn't seem to make much sense to define a 9 character constant for something that can be typed 'longhand' in 3 keystrokes.

        The sample still has "disk:= " in it in 2 places, this is no longer required and can simply be removed (see release notes for Workshop 4.2.0.7)
        Mark

        Comment


        • #5
          Oh yes, I was so concentrated on the constant problem that i didn't noticed the name of the program 8-)

          But please or add the constant or remove their names from the manual, because it is misleading.

          Thanks
          Alessandro

          Comment

          Working...
          X