Error exception - include(assets/grocery_crud/languages/english.php): failed to open stream: No such file or directory - codeigniter-4

File and directory are there as per the grocery crud instructions. But its returning the above error exception in the following line
include ($this->default_language_path.'/'.($this->language).'.php');
path is already declared
protected $default_language_path = 'assets/grocery_crud/languages';
CodeIgniter 4 and grocery crud supporting codeigniter4
Any help much appreciated
Thanks

solved..
the asset folder which comes along with the grocery-crud download should be placed in the root, not inside public folder

Related

Im am getting FileNotFoundError when trying to create a for in loop

I am making an image classifier. I have successfully created the folders and I manually placed the .txt files which has links to images from google inside each folder.
I am now trying to download the images from each .txt file either into a folder inside each folder category, or into each category folder that also has the .txt file, however i keep getting errors. please help.
I manually placed the .txt files in each of the folders as they was in the parent folder name as PLANTS but this has not made a difference.
I expected to get all the images downloaded in their respective folders from the .txt files with google image links but it is not working, whether the .txt is inside the main PLANTS FOLDER or inside each category folder which is inside the PLANTS folder
instead i get the below errors
FileNotFoundError
please see attached screen shot
&
Long filenames or paths with spaces are supported by NTFS in Windows NT. However, these filenames or directory names require quotation marks around them when they are specified in a command prompt operation. Failure to use the quotation marks results in the error message.
for i in range(len(folders)):
path = "content/gdrive/My Drive/Colab Notebooks/Flowers/PLANTS"
#for creating directory we need path class object so below this:
dest_for_creating_directory = path/folders[i]
#for searchi directory which have spaces we need doubleQuotations that
#why user below one in download image function instead of dest.
dest_for_searching_directory = path+"/"+folders[i]
Note: its better practice to write folder/file name without space more info

Line 2 ERROR The file NuxeoCSV-USERDOC.pdf does not exist

When i want to add an attachement(csv) to a file using the addon nuxeo csv import. I got this issue:
Line 2 ERROR The file NuxeoCSV-USERDOC.pdf does not exist
This is the csv file :
name,"type","dc:title","dc:description","file:content","dc:nature","dc:source"
nuxeo-csv-userdoc,"File","Nuxeo CSV User documentation","This is the user guide for Nuxeo CSV","NuxeoCSV-USERDOC.pdf","procedure","http://doc.nuxeo.com"
Nuxeo-csv-sample-3,"File","Nuxeo CSV Sample","This a second file imported with Nuxeo CSV","Nuxeo-csv-sample-3.odt","article","http://doc.nuxeo.com"
It's demanded to make some changes in the file conf but I don't get the last line. How I'm supposed to add the path and how can I add nuxeo.csv.blobs.folder, just by pasting it?
Configuration :
The Nuxeo CSV addon enables users to create file documents and upload their
main attachment at the same time. This requires to configure where the
server will take the attachments. This is done adding the parameter
nuxeo.csv.blobs.folder in the server nuxeo.conf and giving it a value that
is a local path to a folder that can be accessed by the server.
Thanks in advance.

Unable to Load Resource Using getResource

I am trying to simply load a file from a packages resource folder. I have the following project structure:
And have tried the following in an attempt to load each of the txt files to the Populator.groovy script:
File file = new File(Populator.class.getResource("/names/first-names.txt").getFile())
The above results in a FileNotFoundException if any methods are called from the file instance. The path returned is correct, and the file is indeed where the path specifies. I am also using very similar methods of extracting resources in above modules and no errors are occurring. Whats going on here?
Why not
File file = new File(Populator.class.getResource("/names/first-names.txt").toURI())
Not sure why you want it as a file though? Wouldn't an input stream do?

WPF C# Unable to find subfolder image resource

I have several images in an assembly that I have all marked as resource in their property setting.
For testing I put an image at the root of my project.
Img.Source = new BitmapImage(new Uri("pack://application:,,,/MyAssembly;component/image.png", UriKind.Absolute));
and it finds and loads the image just fine.
If I place the image in a subfolder no matter what folder or what level, it returns back that it is unable to find the resource.
The folder structure is Resources/Base/Weather/image.png
Img.Source = new BitmapImage(new Uri("pack://application:,,,/MyAssembly;component/Resources/Base/Weather/image.png", UriKind.Absolute));
When I run the application and try to load that image I get this error
Cannot locate resource 'resources/base/weather/image.png'.
Notice the lowercase on the folder names. I am at a loss as to what to try next. I have tried many variations including using the # but that doesn't help. I really do not want to load up the root directory with images.
Thoughts Anyone???

Excel Object in asp.net

I have a serious issue.
I am using excel object for opening the excel file
it works fine i my PC.
when i make application as a website and running the page and uploading it gives the error "'C:\Documents and Settings\Administrator\Desktop\Work\SABRE MSO Mapping Request Template.xlsx' could not be found. Check the spelling of the file name, and verify that the file location is correct. If you are trying to open the file from your list of most recently used files, make sure that the file has not been renamed, moved, or deleted. ".
I think it taking server path...but i want to open client excel file before saving the file to the server.
Plz help.
have you tried server.mappath() method ?? Do you have proper permissions setup to access the folder??
Are you passing complete file path to the excel for opening the file? Please try this:
if (fileUpload.HasFile)
{
string fileName = "PATH_RELATIVE_TO_YOUR_SITE" + "FILE_NAME";
fileUpload.PostedFile.SaveAs(fileName);
//NOW open excel using fileName;
}
also you need write permissions to the path (folder) you are writing file to.

Resources